Fix node_modules validation when building extensions.
Review Request #11608 — Created May 20, 2021 and submitted
When building extension packages against a production install of a
consuming application, it was likely that abuild_pipeline_settings()
call in the app'ssettings.pywould have path validation enabled,
looking fornode_modules, and that the validation would fail.In reality, we didn't care much about the presence of this path at this
stage, since the packaging process would be managing its own
node_modules. Rather than make the consuming app jump through hoops,
we now have a special environment variable that can be set to force
validation to be turned off. This mirrors the behavior of applications
using Djblets pre-2.0.On top of this, we also explicitly define
NODE_PATHto point to the
managed copy, ensuring it will be used instead of another, and avoiding
other lookup issues that could occur.
Tested building extensions against both a Review Board development server
and a production server.Tested both initial builds (without a pre-populated
node_modulesdirectory)
and with a repeated build.
| Summary | ID |
|---|---|
| 06d24cf09ff0d9bf9271bf68124f43deaff23bd9 |