Thank you for your interest in contributing to netcheck! This document provides guidelines and instructions for contributing.
-
Clone the repository:
git clone https://github.com/jonathancaruso/netcheck.git cd netcheck -
Create a virtual environment:
python -m venv .venv source .venv/bin/activate # Linux/macOS # or .venv\Scripts\activate on Windows
-
Install in development mode:
make dev
make testmake lint # flake8
make typecheck # mypy
make all # lint + typecheck + test- Fork the repository and create a feature branch from
main. - Write tests for any new functionality.
- Ensure all tests pass and linting is clean.
- Update documentation if you're adding or changing features.
- Submit a pull request with a clear description of your changes.
- Follow PEP 8 with a max line length of 120 characters.
- Use type hints on all function signatures.
- Write docstrings for all public functions and classes.
- Keep functions focused and small.
- Never use
shell=Truein subprocess calls. - Always validate user input before processing.
- Never log or expose sensitive information.
- See SECURITY.md for the security policy.
- Create a new module in
src/netcheck/checks/. - Implement a
run_<check_name>()function that returns a dictionary. - Register the check in
src/netcheck/runner.py. - Add output formatting in
src/netcheck/output.py. - Write tests in
tests/test_<check_name>.py. - Update the README with documentation.