Skip to content

[20.0][OU-ADD] stock: migration scripts - #141

Draft
dnplkndll wants to merge 1 commit into
20.0from
20.0-mig-stock
Draft

dnplkndll wants to merge 1 commit into
20.0from
20.0-mig-stock

Conversation

@dnplkndll

Copy link
Copy Markdown

post-migration.py

19.0 spelled "track by quantity" as a selection key; 20.0 spells it False.

19.0 declared product.template.tracking as serial / lot / none, required,
defaulting to 'none'. 20.0 declares only lot and serial and says what the
empty value means: "False on a storable product means it's tracked by
quantity only."

The column keeps whatever it held, so every product that was tracked by
quantity comes out carrying 'none' -- a key the selection no longer
declares. 184 of the seed's 197 products. It reads as an invalid value in
the interface and matches neither branch of a domain over the field.


CI: red until #118 lands

The test job fails on duplicate key value violates unique constraint "res_country_state_name_code_uniq" (Ladakh / Odisha). Not this branch:
base's pre-migration, which renames those two external ids, lives in #118 and
is not on 20.0 yet, so every branch cut from 20.0 alone hits it. Per the
fork's model the per-PR check is the lean one; the real migration gate is the
integration branch (#120), where all of this runs green over the full
585-module seed.

AI-assisted (Claude Code); every change reviewed, tested, and owned by the author.

### post-migration.py

19.0 spelled "track by quantity" as a selection key; 20.0 spells it False.

19.0 declared product.template.tracking as serial / lot / none, required,
defaulting to 'none'. 20.0 declares only lot and serial and says what the
empty value means: "False on a storable product means it's tracked by
quantity only."

The column keeps whatever it held, so every product that was tracked by
quantity comes out carrying 'none' -- a key the selection no longer
declares. 184 of the seed's 197 products. It reads as an invalid value in
the interface and matches neither branch of a domain over the field.

Assisted-by: Claude Opus 5
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