npm v2 plugin: always include $SNAPCRAFT_PART_INSTALL/bin in $PATH
Metadata
Current evaluation
Merged PR #3161 (71cebabd8) always adds ${SNAPCRAFT_PART_INSTALL}/bin to PATH, preventing npm v2 builds from failing when node is already present there.
Resolution: closed resolved
Reason: PR #3161 was merged as commit 71cebabd8, ensuring the npm plugin's Node bin directory is included even when node already exists there.
Evaluated by: mr-cal-bot
No scores available.
Issue body
That's where we are unpacking node to anyways, always include it.
If node is already in ${SNAPCRAFT_PART_INSTALL}/bin, then the PATH
never gets updated, breaking the build.
Signed-off-by: Chris Patterson <chris.patterson@canonical.com>
- [ ] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)?
- [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)?
- [ ] Have you successfully run `./runtests.sh static`?
- [ ] Have you successfully run `./runtests.sh tests/unit`?
-----
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #3161 (71cebabd8) always adds ${SNAPCRAFT_PART_INSTALL}/bin to PATH, preventing npm v2 builds from failing when node is already present there. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #3161 (71cebabd8) made the npm v2 plugin always add $SNAPCRAFT_PART_INSTALL/bin to PATH, preventing builds from failing when Node is already present there. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #3161 (71cebabd8) makes the npm v2 plugin always add ${SNAPCRAFT_PART_INSTALL}/bin to PATH, fixing builds when that directory already contains node. | |
| qwen/qwen3.6-35b-a3b | — | — | Merged. Resolves npm v2 plugin build failures by always including $SNAPCRAFT_PART_INSTALL/bin in $PATH. Approved by reviewer, passed CI, and merged with a minimal 5-line change across two files. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged fix for npm v2 plugin to always include $SNAPCRAFT_PART_INSTALL/bin in $PATH. This resolves build failures when node is already in that directory by ensuring the PATH is correctly updated. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #2957 go plugin: do not remove install /bin directory before build | snapcraft | merged | Merged PR #2957 (commit 1fee618c0) stopped the Go plugin from purging $SNAPCRAFT_PART_INSTALL/bin before build, preserving stage-package files; added a spread test for coverage. | |
| #200 plugins: npm | craft-parts | merged | Merged PR #200 as b9881154 (feature commit 343d5c6b), porting Snapcraft’s npm plugin and adding npm-include-node with a false default. |