odooindex_connector: split into core, CLI and Odoo UI #7
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.43) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.43 · 357 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.352
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #7"
general
weight: 0.35
dreispt
Summary
This PR reorganizes
odooindex_connectorinto three layers and exposes a single, pipx-installable command-line tool calledclox:1.
odooindex_connector/core/– pure-Python HTTP client, inventory builder, chunked upload, download and pairing helpers (no Odoo imports).2.
odooindex_connector/clox.py+__main__.pyand the rootpyproject.toml– a standalonecloxentry point that does not require theodooPython package. It parses the Odoo configuration file and connects directly to PostgreSQL withpsycopg/psycopg2, readsir.config_parameterandir.module.moduleover SQL, and writes the pairing token back with an UPSERT.3.
odooindex_connector/models/ir_module_module.pyandwizards/odooindex_connector_pair_wizard.py– thin Odoo wrappers around the same core service classes.cloxhas no subcommands. It detects the required work automatically:-c/ODOO_RC) and DB name (-d/ODOO_DATABASE);odooindex_connector.api_tokenexists (pair with OdooIndex when missing, prompting for the PIN);Install with pipx and run:
Supported environment variables:
ODOO_RC– Odoo configuration fileODOO_DATABASE– Odoo database nameODOOINDEX_API_TOKEN– existing OdooIndex API tokenODOOINDEX_TARGET_VERSION– target Odoo versionODOOINDEX_INSTANCE_NAME– display name for this instanceODOOINDEX_BASE_URL– OdooIndex API base URLNotes
ruff check .,pylint --rcfile=.pylintrc-mandatory odooindex_connector, andpylint --rcfile=.pylintrc odooindex_connectorall pass..pre-commit-config.yamlpinsdefault_language_version: python3.12, while the environment provides Python 3.11.stderrso--jsonoutput onstdoutremains valid JSON.pyproject.tomlcontains theclox = odooindex_connector.clox:mainconsole script.Sync Nowbutton in Settings now force-reloadsir.config_parameter(viaself.env.registry.clear_cache("default")) before syncing, so values written outside the ORM (e.g., by thecloxCLI) are picked up immediately.Assisted-by: Devin
Link to Devin session: https://app.devin.ai/sessions/4cb03762550148e88bacf9ee4bf4e849
Open in Devin Desktop: https://app.devin.ai/desktop/session/4cb03762550148e88bacf9ee4bf4e849?variant=devin
Requested by: @dreispt