microsoft / rushstack

Monorepo for tools developed by the Rush Stack community
https://rushstack.io/
Other
5.92k stars 595 forks source link

[rush] Deployment with linkCreation as "script" fails - "Error: File does not exist: scripts/create-links.js" #3889

Closed hudsonmm closed 1 year ago

hudsonmm commented 1 year ago

Summary

In Rush 5.88.0, when running rush deploy for a deployment where "linkCreation" is set to "script", the command fails with the error "Error: File does not exist: scripts/create-links.js"

Repro steps

1) Create a deployment via rush init-deploy for a project 2) Update deploy.json to set "linkCreation" to "script" 3) Run rush deploy

Expected result: Command completes successfully, create-links.js file is found under common/deploy

Actual result: Command fails, folders are copied but create-links.js is not present

Details

Unsure exactly where the problem is, but from I've tried to uncover:

DeployManager.ts line changed from this:

https://github.com/microsoft/rushstack/blob/cb5e7749edf4b15b11dc809bedefed9666297810/apps/rush-lib/src/logic/deploy/DeployManager.ts#L667

to this:

https://github.com/microsoft/rushstack/blob/8387963bb4ab479395018de705d8d98987549236/libraries/rush-lib/src/logic/deploy/DeployManager.ts#L668

If I understand the expectation correctly, the create-links.js file should exist in rush-lib/dist/scripts, but it does not.

Standard questions

Please answer these questions to help us investigate your issue more quickly:

Question Answer
@microsoft/rush globally installed version? 5.88.0
rushVersion from rush.json? 5.88.0
useWorkspaces from rush.json? No
Operating system? Linux/Ubuntu
Would you consider contributing a PR? Yes
Node.js version (node -v)? 16.18.0
joelrbrandt commented 1 year ago

For me, this bug also reproduces in 5.87.0. It does not reproduce in 5.86.0.

Thanks for filing, @hudsonmm !

iclanton commented 1 year ago

This is fixed in Rush 5.88.1.

joelrbrandt commented 1 year ago

@iclanton thank you for fixing this so quickly! However, 5.88.1 seems to have introduced this regression for me: #3905