Skip to content

odoo: skip --dev injection for Odoo subcommands - #73

Merged
dreispt merged 1 commit into
masterfrom
feature/odoo-subcommand-dev
Oct 29, 2026
Merged

dreispt merged 1 commit into
masterfrom
feature/odoo-subcommand-dev

Conversation

@dreispt

@dreispt dreispt commented Oct 29, 2026

Copy link
Copy Markdown
Owner

Summary

  • osh odoo appended the default --dev=all unconditionally, so Odoo subcommands whose parsers reject server options failed with unrecognized arguments: --dev=all (e.g. osh odoo i18n export, osh odoo scaffold).
  • The dev default is now injected only for server runs — the same exemption subcommands already get for dbfilter, the HTTP port check and the demo-data default.
  • An explicit --dev still passes through untouched, and --no-dev / osh config odoo dev off are unchanged.
  • Updated the osh odoo docstring and added a changelog entry.

Test plan

  • pytest tests/test_odoo.py — 26 passed, including the two new cases: i18n export gets no --dev, shell --dev=xml keeps the explicit value
  • Verified live: osh odoo i18n export -d <db> -o mod.pot mod and -l pt exports now run and write the .pot/.po files

Assisted-by: Devin:SWE-2 High

Odoo subcommand parsers (shell, i18n, scaffold, neutralize, ...) reject
server options, so `osh odoo i18n export` failed with
"unrecognized arguments: --dev=all". The dev default is now appended
only for server runs — the same exemption subcommands already have for
dbfilter, the HTTP port check and the demo-data default. An explicit
--dev still passes through untouched.

Assisted-by: Devin:SWE-2 High
@dreispt
dreispt force-pushed the feature/odoo-subcommand-dev branch from 326242b to 2f469c3 Compare October 29, 2026 08:14
@dreispt
dreispt merged commit a634335 into master Oct 29, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant