This guide provides technical guidelines for contributors to the Google SecOps Wrapper SDK.
The SecOps SDK follows a src-layout structure:
secops-wrapper/
├── src/
│ └── secops/ # Main package
│ ├── chronicle/ # Chronicle-specific modules
│ ├── cli.py # Command-line interface
│ ├── client.py # SecOps client
│ ├── auth.py # Authentication module
│ └── ... # Other modules
├── tests/ # Test files
└── examples/ # Example scripts
- Python 3.10 or higher
# Clone repository and setup development environment
git clone https://github.com/google/secops-wrapper.git
cd secops-wrapper
# Create virtual environment
python -m venv venv
source venv/bin/activate
# Install package dependencies
pip install -r requirements.txt- Follow the Google Python Style Guide
- Maximum line length is 80 characters
- Use pylint for linting (pylintrc is available in the repository)
pylint --rcfile=pylintrc src/
- black is the preferred formatter
black --line-length=80 src/
- Include Google-style docstrings for all functions, classes, and methods
- Use type hints for all function parameters and return values
- Implement proper error handling with specific exception types
- Add appropriate tests for all new code
- Follow guidelines in TESTING.md
- Ensure all existing tests pass with your changes
- Update documentation to reflect new changes
- Update/Add applicable sections in README.md and CLI.md
- Add example usage scripts in the
examples/directory - Examples should demonstrate real-world use cases of the change