Make WordPress Core

Opened 7 months ago

Closed 4 months ago

#48956 closed defect (bug) (fixed)

Error trying to install node-sass@4.12.0 on MacOS Catalina

Reported by: afragen Owned by:
Milestone: 5.4 Priority: high
Severity: normal Version:
Component: Build/Test Tools Keywords: has-patch needs-testing
Focuses: Cc:


In the package.json of develop.svn.wordpress.org lists "node-sass": "~4.12.0" in devDependencies.

After git clone git://develop.git.wordpress.org/ /public and then running npm install on my Mac from the proper directory I get the following error. I'm running Mac OS Catalina FWIW.

Cannot download "https://github.com/sass/node-sass/releases/download/v4.12.0/darwin-x64-79_binding.node":
HTTP error 404 Not Found

I don't no why it's looking for this particular package darwin-x64-79_binding.node but it doesn't exist on GitHub.

Updating the package.json to use "node-sass": "~4.13.0" seems to work.

Attachments (1)

48956.diff (2.3 KB) - added by desrosj 6 months ago.

Download all attachments as: .zip

Change History (7)

#1 @SergeyBiryukov
7 months ago

  • Milestone changed from Awaiting Review to 5.4

6 months ago

#2 @desrosj
6 months ago

  • Keywords has-patch needs-testing added; dev-feedback removed

@afragen which version of Node are you running? My hunch is that you are running Node 13, which does not seem to be supported in 4.12.0.

The darwin-x64-79_binding.node is the packaged asset for the release corresponding to the environment you are running. Looks like this specific one is not present for 4.12.0, but is for 4.13.0, so that's likely the issue.

Looking at the release notes for v4.13.0, it seems that the only changes made not related to Node 13 support are for documentation and Travis configuration. I think bumping the version for this should be fine, but it should also be updated in the Gutenberg repository.

Until this is deemed OK and updated in trunk/Gutenberg, you can use NVM to switch versions based on .nvmrc files in directories for the best experience. Running nvm use will switch to the version recommended there.

#3 @afragen
6 months ago

@desrosj I am running node v12.13.1

Which version are you suggesting I switch to?

This ticket was mentioned in Slack in #core by mike. View the logs.

4 months ago

#5 @UmeshSingla
4 months ago

@desrosj Tested the build with node v12.16.1, npm install worked fine for me with the following message.

"Binary found at /Users/umeshkumar/Documents/umesh/tests/wordpress/node_modules/node-sass/vendor/darwin-x64-72/binding.node
Testing binary
Binary is fine"

#6 @SergeyBiryukov
4 months ago

  • Resolution set to fixed
  • Status changed from new to closed

Updating the package.json to use "node-sass": "~4.13.0" seems to work.

node-sass was updated to ~4.13.1 in [47404] / #49547.

Closing as fixed, feel free to reopen and move to a future release if there's still an issue.

Note: See TracTickets for help on using tickets.