This document guides the AI agent in developing the odoo-data-flow project.
This is an Odoo module. All code, dependencies, and architectural decisions must be compatible with the Odoo version specified in the Git branch.
- Odoo Version Detection: Before starting, determine the Odoo version by inspecting the Git branch name. Use this command to extract it:
git rev-parse --abbrev-ref HEAD | sed -n 's/^\([0-9]\{1,2\}\.0\).*/\1/p'
- Strategic Goal: All implemented functionality must align with the ODF strategic blueprint.
Jules must set up its environment using Nox.
- Ensure
noxis installed:pip install nox. - Run the initial setup session to create the virtual environment and install all dependencies:
nox -s setup.
For every task, you MUST adhere to the following rules without exception.
All code execution, testing, and checks must be performed within the Nox-managed environment.
- Primary Command:
nox(runs the full suite) - Quick Checks: For faster iteration, run a subset:
nox -s pre-commit mypy tests
All generated Python code must be 100% compliant with the project's pre-commit configuration.
- Linter/Formatter:
ruff - Import Sorting:
isort - Line Length: Maximum 88 characters.
Code must be fully type-hinted and pass mypy static analysis with zero errors.
- Typing Style: Use lowercase standard types (e.g.,
list,dict).
All functions, methods, and classes require Google-style docstrings.
- Format: Start with a one-line summary ending in a period, followed by a blank line.
- Content: Clearly document
Args:andReturns:.