Lombiq / NodeJs-Extensions

Utilities and extensions for Node.js, used in ASP.NET (Core) MVC and Orchard (Core) CMS development.
BSD 3-Clause "New" or "Revised" License
8 stars 2 forks source link

MSB3073: The command "node scripts/run-pnpm-script "<ProjectName>" build" exited with code -1. (OSOE-593) #39

Closed 0liver closed 1 year ago

0liver commented 1 year ago

Here's an example of the error:

https://github.com/Lombiq/Open-Source-Orchard-Core-Extensions/actions/runs/4388557195/jobs/7685183926#step:6:114

The cause of the error seems to be a missing script in the .bin folder of the Node.js Extensions NPM package installation, which in case of OSOCE is e.g. _C:\Projects\Lombiq\Osoce\node_modules\.nx\nodemodules\.bin.

The specific missing script varies. In the above build, postcss was missing, but there have been builds where sass was missing instead.

What to do

We need to investigate why pnpm install does not create these scripts properly at the given location. And then, we'll have to fix it.

Ideas

Jira issue

Piedone commented 1 year ago

Is this another random error that breaks the build?

0liver commented 1 year ago

Unfortunately, yes.

Piedone commented 1 year ago

Isn't this a bug introduced by https://github.com/Lombiq/Orchard-Training-Demo-Module/issues/108?

0liver commented 1 year ago

Yes. We've fixed a similar bug there, though, and the original one still persists.

0liver commented 1 year ago

The same high-level error has just now appeared in this build: https://github.com/Lombiq/Lombiq-Tenants-Core/actions/runs/4542803172

But the root cause is a different one: pnpm@8 was released last night with some breaking changes.

Let's restrict the version to v7 for now, and in a next step, update to v8.

0liver commented 1 year ago

This was just a drive-by fix for a similar error - reopening.