Name:
[FIX] viin_brand_common, web_responsive, viin_brand_mail, to_backend_theme: keep brand CSS out of core test bundles
State:
Killed
finished in 114m
PR State:
merged
PR Author:
David Tran
PR Author Email:
PR:
#673
Committer:
David Tran
Committer Email:
david.tran@tvtmarine.com
Commit:
966ce881811f3e7d4691ceabe29d94e2915315f6
Description:
[FIX] web_responsive: pin primary-variables bundle order
CPython randomizes string hashing per process (PYTHONHASHSEED), so a
Python set literal used as an assets bundle value iterates in a
different order every time the Odoo server process starts. The
"web._assets_primary_variables" bundle was declared as a set of two
SCSS paths, making its file load order nondeterministic across
deployments and restarts.
Switch the bundle from a set literal to a list literal, keeping the
exact same two files in the exact same order they were already
written in: form_variable.scss first, then primary_variable.scss.
Verified safe to keep this order: form_variable.scss defines only
$o-form-renderer-max-width and $o-form-view-sheet-max-width, while
primary_variable.scss defines only $app-menu-text-color,
$app-menu-background-color, $app-menu-item-highlight,
$app-menu-box-shadow and $app-menu-box-shadow-highlight, all with
!default. The two files' variable namespaces are fully disjoint in
both directions, so there was no dependency-driven "correct" order to
choose - this order is now a deliberate, deterministic choice rather
than an accident of hash seeding.
Protected by the repo-wide regression guard added in the immediately
preceding commit
(viin_brand/tests/test_manifest_assets_no_set_literals.py), which was
measured RED against exactly this bundle before this fix, and is now
confirmed GREEN together with this fix on a real Odoo 18.0 instance
(db odoo_18_0_standard_viindoo_18_t_cbeabf2d): odoo.tests.result: 0
failed, 0 error(s) of 6 tests.
Signed-off-by: David Tran <david.tran@tvtmarine.com>
Branch:
18.0
Age:
Up-time: