我有一个RangeProject7.1,它以前工作得很好,但是在升级到ubuntu19.10之后,当我安装npm时,我得到了以下错误:
> node-sass@4.11.0 install /home/gabb/dev/homepage/node_modules/node-sass
> node scripts/install.js
Downloading binary from https://github.com/sass/node-sass/releases/download/v4.11.0/linux-x64-79_binding.node
Cannot download "https://github.com/sass/node-sass/releases/download/v4.11.0/linux-x64-79_binding.node":
HTTP error 404 Not Found
Hint: If github.com is not accessible in your location
try setting a proxy via HTTP_PROXY, e.g.
export HTTP_PROXY=http://example.com:1234
or configure npm proxy via
npm config set proxy http://example.com:8080
node[1617]: ../src/signal_wrap.cc:159:void node::DecreaseSignalHandlerCount(int): Assertion `(new_handler_count) >= (0)' failed.
1: 0x9f0390 node::Abort() [node]
2: 0x9f0417 [node]
3: 0xa91bdc node::DecreaseSignalHandlerCount(int) [node]
4: 0xa91cb4 [node]
5: 0x98fbd5 node::Environment::CleanupHandles() [node]
6: 0x98fe6b node::Environment::RunCleanup() [node]
7: 0xa2d2f0 node::NodeMainInstance::Run() [node]
8: 0x9c1311 node::Start(int, char**) [node]
9: 0x7fbff275e1e3 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
10: 0x95ed25 [node]
Aborted (core dumped)这个链接binding.node确实返回404。如果我转到package.json文件,就没有节点-sass条目。如果不是在package.json中,任何人都可以解释为什么要安装not @4.11.0。这是角质的依赖吗?如果是这样的话,我需要升级到一个新版本才能获得最新的节点-sass版本吗?
这似乎有点复杂,只是升级到最新的ubuntu版本,特别是因为它很难升级到另一个版本。
package.json:https://pastebin.com/w51Kna2g
为了澄清这一点,我想知道对此的解释,而不仅仅是一些“修复”它的命令。
编辑:似乎它依赖@角-devkit/构建-角,而我的版本是0.13.6。
当我将其更新到最新版本时,我会得到其他错误。
发布于 2020-01-21 13:22:46
跟进你的答覆:
因此,答案是,我的角-devkit/建角版本依赖于节点sass v4.11.0,但not v4.11.0不支持我的linux版本。
更正确的说法是,您的特定平台版本没有预编译的二进制文件。在安装过程中,它试图找到一个不存在导致错误的错误。你能做的,就是自己试着从源头上构建一个。
节点自述中有一节通过以下步骤讨论如何自己创建二进制:
Check out the project:
git clone --recursive https://github.com/sass/node-sass.git
cd node-sass
npm install
node scripts/build -f # use -d switch for debug release
# if succeeded, it will generate and move
# the binary in vendor directory.一旦有了二进制文件,就可以使用一些env变量来引用它了。
上周,我偶然发现了自述的这一部分,试图在工作中建立一个项目。我无法获得节点-sass二进制文件,但我的问题更多地与公司代理的工作有关。最后,我下载了一个节点二进制文件(而不是自己创建它),并简单地将vendor文件夹复制到该项目的node _node/ not (我知道,这并不是非常理想的)。
发布于 2020-01-21 10:56:04
因此,答案是,我的角-devkit/构建-角版本依赖于节点-sass v4.11.0,而节点-sass v4.11.0不支持我的NodeJS版本。所以我必须更新一个有节点sass 4.13.0的版本。
这显然没有,0.13.9是最后一个支持角7的,它有4.12.0作为节点sass版本。
这意味着要在ubuntu19.10上编码,我需要有角8+?这对我来说是不可能的,因为我使用的一些软件包不支持这一点。整个项目建于2019年,它已经是一个需要更新的皮塔。必须使用对接者来模拟一个angular 19.04才能编码角度7。
https://stackoverflow.com/questions/59838816
复制相似问题