nx: Nx Cloud Error (it seems) during the GH Actions Workflow
Current Behavior
When running our CD workflow on the GH Actions with enabled Nx Cloud Caching (Nx Replay) we see the following in the logs:
... more logs ...
[NX CLOUD] Verifying current cloud bundle
[NX CLOUD] A local bundle currently exists: {
version: '2402.08.4',
fullPath: '/home/runner/work/<redacted>/<redacted>/.nx/cache/cloud/2402.08.4'
}
[NX CLOUD] Last verification was within the past 30 minutes, will not verify this time
[NX CLOUD] Done: /home/runner/work/<redacted>/<redacted>/.nx/cache/cloud/2402.08.4
ERROR failed to read input source map: failed to parse inline source map url
",u=a.length,l=(0,pr.basename)(e),f=(0,pr.extname)(e),p=n(e),g=l.slice(0,-f.length)+p+".map",E=u+g.length;if(t.substr(-E,u)===a)return t.slice(0,-E)+o;let y=u+encodeURI(g).length;return t.substr(-y,u)===a?t.slice(0,-y)+o:`${t}
Caused by:
relative URL without a base
at /usr/local/cargo/registry/src/index.crates.io-6f17d22bba15001f/swc-0.273.0/src/lib.rs:[38](https://github.com/<redacted>/<redacted>/actions/runs/7984859333/job/21802360408#step:10:39)5
> NX Trying to create heartbeat background process for run group: 798[48](https://github.com/<redacted>/<redacted>/actions/runs/7984859333/job/21802360408#step:10:49)59333-1
> NX Heartbeat process started successfully with PID 2070
> NX Running target cdk-deploy-needs for 3 projects and 5 tasks they depend on:
... more logs ...
We are not sure what that is.
The workflow is able to continue and complete what it is supposed to do, despite the error in the logs.
Expected Behavior
I’m not sure, but I guess there are no errors in the logs.
GitHub Repo
private
Steps to Reproduce
- Create the integrated nx repo
- Connect to nx cloud
- Setup the GitHub actions workflow
- Run the workflow
- See the logs with debug mode in gh actions
Nx Report
This is from local machine:
Node : 20.11.0
OS : darwin-x64
pnpm : 8.15.1
nx : 17.2.8
@nx/js : 17.2.8
@nx/jest : 17.2.8
@nx/eslint : 17.2.8
@nx/workspace : 17.2.8
@nx/devkit : 17.2.8
@nx/esbuild : 17.2.8
@nx/eslint-plugin : 17.2.8
@nx/next : 17.2.8
@nx/node : 17.2.8
@nx/playwright : 17.2.8
@nx/plugin : 17.2.8
@nx/react : 17.2.8
typescript : 5.3.3
---------------------------------------
Community plugins:
@nx-tools/nx-container : 5.2.0
---------------------------------------
Local workspace plugins:
@app/docker
@app/next
@app/aws
@app/cdk
Failure Logs
...
[NX CLOUD] Verifying current cloud bundle
[NX CLOUD] A local bundle currently exists: {
version: '2402.08.4',
fullPath: '/home/runner/work/<redacted>/<redacted>/.nx/cache/cloud/2402.08.4'
}
[NX CLOUD] Last verification was within the past 30 minutes, will not verify this time
[NX CLOUD] Done: /home/runner/work/<redacted>/<redacted>/.nx/cache/cloud/2402.08.4
ERROR failed to read input source map: failed to parse inline source map url
",u=a.length,l=(0,pr.basename)(e),f=(0,pr.extname)(e),p=n(e),g=l.slice(0,-f.length)+p+".map",E=u+g.length;if(t.substr(-E,u)===a)return t.slice(0,-E)+o;let y=u+encodeURI(g).length;return t.substr(-y,u)===a?t.slice(0,-y)+o:`${t}
Caused by:
relative URL without a base
at /usr/local/cargo/registry/src/index.crates.io-6f17d22bba15001f/swc-0.273.0/src/lib.rs:385
> NX Trying to create heartbeat background process for run group: 7984859333-1
> NX Heartbeat process started successfully with PID 6299
> NX Running target cdk-deploy for 3 projects and 5 tasks they depend on:
...
Package Manager Version
pnpm@8.15.1
Operating System
- macOS
- Linux
- Windows
- Other (Please specify)
Additional Information
Sorry for no reproduction repo. I might find a minute to create one later.
About this issue
- Original URL
- State: open
- Created 4 months ago
- Reactions: 8
- Comments: 15 (2 by maintainers)
I manage to fix this error
ERROR failed to read input source map: failed to parse inline source map urlBy simply installing
nx-cloudas a dependency.I’ve tested it on Windows 11 and WSL via devcontainers and the problem seems to be fixed.
Here is a link to a basic working repository using a local plugin & executor: https://github.com/JacobGardos/nx-swc-fix (See README.md for instructions)
Let me know if this helps.
For a more detailed explanation in regards to the cause of the error check out this comment from a similar issue.
https://github.com/nrwl/nx/issues/22146#issuecomment-2028904256
Nx Report For Windows 11 & WSL
THANK YOU!
I’m hitting something similar, even locally, but only with the build command