Contributing¶
Guidelines for contributing code, reporting bugs, and submitting pull requests.
Contributing to Suspicious¶
We welcome contributions to improve Suspicious, whether through new features, bug fixes, documentation, or optimizations. This guide explains how to set up your development environment and submit changes via Pull Requests (PRs).
Development Setup¶
Before contributing, ensure you have:
- Git installed
- A GitHub account
- A fork of the official Suspicious repository Clone your fork locally:
git clone <your_forked_repository.git>
cd suspicious
Switch to a feature branch:
git checkout -b feature/<short_feature_name>
Wire the repo's git hooks (Conventional Commits validator):
git config core.hooksPath .githooks
# or, from deployment/:
make install-hooks
The commit-msg hook rejects any subject that does not match
<type>(scope)?!?: <subject> (max 72 chars). Allowed types: feat,
fix, chore, docs, refactor, perf, test, ci, build,
style, revert. Merge / revert / fixup / squash auto-subjects are
allowed through.
Contribution Workflow¶
-
Make changes to the code or documentation.
-
Stage files:
git add .
- Commit with a clear message:
git commit -m "feat: short title" -m "Optional longer description"
-
Use conventional commit style when possible:
feat:for a new featurefix:for a bug fixdocs:for documentation changesrefactor:for code improvements without changing behavior
-
Run tests and lint before pushing:
# Backend
cd Suspicious && python manage.py test
# Frontend
cd suspicious-ui && pnpm lint && pnpm test
- Push your branch:
git push origin feature/<short_feature_name>
-
Open a Pull Request (PR) from your fork on GitHub:
-
Navigate to your repository
- Click Contribute > Open Pull Request
- Fill in the PR template (title, description, related issues)
- Submit for review
Code Review Process¶
- All PRs are reviewed by project maintainers.
- Reviews may request changes for consistency, security, or clarity.
- Once approved, your PR will be merged into the
devbranch, then later intomain.
Best Practices¶
- Keep commits small and focused.
- Write clear commit messages.
- Ensure code is formatted and linted.
- Add/update tests where relevant.
- Update documentation when introducing changes.
✅ Following these steps helps us keep Suspicious reliable, maintainable, and secure.