[20.0][MIG] stock_move_valuation_usage: Migration to 20.0 #2578
All Vouch review confidence checks passed
Residual risk 0.30 = Change Risk (0.56) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.56 · 151 lines diff across 1 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 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
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.301
Sensitive Paths
sensitive_paths
0.056
Real PR Conversation Timeline
1 comments
"Review active on #2578"
general
weight: 0.35
AaronHForgeFlow
Standard Migration
Changes for Odoo 20.0:
_action_done()and replays the FIFO valuation (_run_fifo(correction=True)) when an earlier move changes (date, quantity, cost) or a receipt fills stock that was already delivered. The usage records are now rebuilt on every valuation of an outgoing FIFO move and on every replay (through the new_run_fifo_correction_reset()hook ofstock_account_product_run_fifo_hook), so they follow the move value and are never duplicated._handle_negative_fifo_revaluation(): it linked every delivery without usage records to the next receipt, for the full delivered quantity. The replay now links the receipt to the deliveries it fills, for the filled quantity only._set_value()override:stock_account_product_run_fifo_hooknow sets thevalued_movecontext.tools.create_index()replaced bymodels.Index(same index name).security/ir.access.csv.TestStockValuationCommon(the category valuation fields were removed in 20.0): negative stock fill, FIFO replay (cost update, backdating), batch validation and no duplicated records.@ForgeFlow