Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation fails, due to missing commander@^11.0.0 #1197

Open
navid-zamani opened this issue Sep 24, 2024 · 2 comments
Open

Installation fails, due to missing commander@^11.0.0 #1197

navid-zamani opened this issue Sep 24, 2024 · 2 comments

Comments

@navid-zamani
Copy link

navid-zamani commented Sep 24, 2024

Code editor

Kate

Platform

Linux/SystemD/Mint 22 (=…/Ubuntu 24)

Version

(impossible)

What steps will reproduce the bug?

npm i -g bash-language-server

How often does it reproduce? Is there a required condition?

Always

What is the expected behavior?

Installation of bash-language-server, according to the README.md.

What do you see instead?

npm ERR! code ETARGET
npm ERR! notarget No matching version found for commander@^11.0.0.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/[private]/.npm/_logs/2024-09-24T10_37_57_975Z-debug-0.log

Additional information

Hi, I cannot tell from this, if commander is supposed to be a npm package or something expected from my OS package manager. (I’m not into JS.)

I presumed that it’s an npm package and npm is expected to find, download and install it if required, but this package here has a dependency for a version that does not exist (anymore?).
(I’m surprised that a package with a missing dependency can even enter the package repository though, so above presumption may be wrong(?).)

A deb package named node-commander is installed here, but in version 9.4.1-1. I don’t know if that’s what is meant…

@navid-zamani
Copy link
Author

Here’s the complete log file /home/[private]/.npm/_logs/2024-09-24T10_37_57_975Z-debug-0.log:

0 verbose cli /usr/bin/node /usr/bin/npm
1 info using npm@9.2.0
2 info using node@v18.19.1
3 timing npm:load:whichnode Completed in 0ms
4 timing config:load:defaults Completed in 2ms
5 timing config:load:file:/usr/share/nodejs/npm/npmrc Completed in 3ms
6 timing config:load:builtin Completed in 3ms
7 timing config:load:cli Completed in 2ms
8 timing config:load:env Completed in 1ms
9 timing config:load:project Completed in 1ms
10 timing config:load:file:/home/[private]/.npmrc Completed in 0ms
11 timing config:load:user Completed in 0ms
12 timing config:load:file:/etc/npmrc Completed in 0ms
13 timing config:load:global Completed in 0ms
14 timing config:load:setEnvs Completed in 2ms
15 timing config:load Completed in 12ms
16 timing npm:load:configload Completed in 12ms
17 timing npm:load:mkdirpcache Completed in 0ms
18 timing npm:load:mkdirplogs Completed in 0ms
19 verbose title npm i bash-language-server
20 verbose argv "i" "--global" "bash-language-server"
21 timing npm:load:setTitle Completed in 2ms
22 timing config:load:flatten Completed in 3ms
23 timing npm:load:display Completed in 4ms
24 verbose logfile logs-max:10 dir:/home/[private]/.npm/_logs/2024-09-24T10_36_09_734Z-
25 verbose logfile /home/[private]/.npm/_logs/2024-09-24T10_36_09_734Z-debug-0.log
26 timing npm:load:logFile Completed in 10ms
27 timing npm:load:timers Completed in 0ms
28 timing npm:load:configScope Completed in 0ms
29 timing npm:load Completed in 29ms
30 timing config:load:flatten Completed in 0ms
31 timing arborist:ctor Completed in 1ms
32 silly logfile start cleaning logs, removing 1 files
33 silly logfile done cleaning log files
34 timing idealTree:init Completed in 9ms
35 timing idealTree:userRequests Completed in 5ms
36 silly idealTree buildDeps
37 silly fetch manifest bash-language-server@*
38 http fetch GET 200 https://registry.npmjs.org/bash-language-server 195ms (cache miss)
39 silly placeDep ROOT bash-language-server@5.4.0 OK for:  want: *
40 silly fetch manifest editorconfig@2.0.0
41 silly fetch manifest fast-glob@3.3.2
42 silly fetch manifest fuzzy-search@3.2.1
43 silly fetch manifest node-fetch@2.7.0
44 silly fetch manifest turndown@7.1.3
45 silly fetch manifest vscode-languageserver@8.0.2
46 silly fetch manifest vscode-languageserver-textdocument@1.0.11
47 silly fetch manifest web-tree-sitter@0.22.5
48 silly fetch manifest zod@3.22.4
49 http fetch GET 200 https://registry.npmjs.org/editorconfig 51ms (cache miss)
50 http fetch GET 200 https://registry.npmjs.org/turndown 86ms (cache miss)
51 http fetch GET 200 https://registry.npmjs.org/fast-glob 92ms (cache miss)
52 http fetch GET 200 https://registry.npmjs.org/vscode-languageserver-textdocument 96ms (cache miss)
53 http fetch GET 200 https://registry.npmjs.org/node-fetch 109ms (cache miss)
54 http fetch GET 200 https://registry.npmjs.org/web-tree-sitter 138ms (cache miss)
55 http fetch GET 200 https://registry.npmjs.org/vscode-languageserver 146ms (cache miss)
56 http fetch GET 200 https://registry.npmjs.org/zod 164ms (cache miss)
57 http fetch GET 200 https://registry.npmjs.org/fuzzy-search 580ms (cache miss)
58 timing idealTree:#root Completed in 796ms
59 silly fetch manifest encoding@^0.1.0
60 http fetch GET 200 https://registry.npmjs.org/encoding 47ms (cache miss)
61 silly placeDep node_modules/bash-language-server editorconfig@2.0.0 OK for: bash-language-server@5.4.0 want: 2.0.0
62 silly placeDep node_modules/bash-language-server fast-glob@3.3.2 OK for: bash-language-server@5.4.0 want: 3.3.2
63 silly placeDep node_modules/bash-language-server fuzzy-search@3.2.1 OK for: bash-language-server@5.4.0 want: 3.2.1
64 silly placeDep node_modules/bash-language-server node-fetch@2.7.0 OK for: bash-language-server@5.4.0 want: 2.7.0
65 silly placeDep node_modules/bash-language-server turndown@7.1.3 OK for: bash-language-server@5.4.0 want: 7.1.3
66 silly placeDep node_modules/bash-language-server vscode-languageserver@8.0.2 OK for: bash-language-server@5.4.0 want: 8.0.2
67 silly placeDep node_modules/bash-language-server vscode-languageserver-textdocument@1.0.11 OK for: bash-language-server@5.4.0 want: 1.0.11
68 silly placeDep node_modules/bash-language-server web-tree-sitter@0.22.5 OK for: bash-language-server@5.4.0 want: 0.22.5
69 silly placeDep node_modules/bash-language-server zod@3.22.4 OK for: bash-language-server@5.4.0 want: 3.22.4
70 silly fetch manifest @one-ini/wasm@0.1.1
71 silly fetch manifest commander@^11.0.0
72 silly fetch manifest minimatch@9.0.2
73 silly fetch manifest semver@^7.5.3
74 silly fetch manifest @nodelib/fs.stat@^2.0.2
75 silly fetch manifest @nodelib/fs.walk@^1.2.3
76 silly fetch manifest glob-parent@^5.1.2
77 silly fetch manifest merge2@^1.3.0
78 silly fetch manifest micromatch@^4.0.4
79 silly fetch manifest whatwg-url@^5.0.0
80 silly fetch manifest domino@^2.1.6
81 silly fetch manifest vscode-languageserver-protocol@3.17.2
82 http fetch GET 200 https://registry.npmjs.org/minimatch 37ms (cache stale)
83 http fetch GET 200 https://registry.npmjs.org/commander 38ms (cache stale)
84 http fetch GET 200 https://registry.npmjs.org/glob-parent 57ms (cache miss)
85 http fetch GET 200 https://registry.npmjs.org/semver 67ms (cache miss)
86 http fetch GET 200 https://registry.npmjs.org/domino 65ms (cache miss)
87 http fetch GET 200 https://registry.npmjs.org/micromatch 72ms (cache miss)
88 http fetch GET 200 https://registry.npmjs.org/@nodelib%2ffs.walk 78ms (cache miss)
89 http fetch GET 200 https://registry.npmjs.org/@nodelib%2ffs.stat 81ms (cache miss)
90 http fetch GET 200 https://registry.npmjs.org/merge2 82ms (cache miss)
91 http fetch GET 200 https://registry.npmjs.org/vscode-languageserver-protocol 84ms (cache miss)
92 http fetch GET 200 https://registry.npmjs.org/whatwg-url 86ms (cache miss)
93 http fetch GET 200 https://registry.npmjs.org/@one-ini%2fwasm 130ms (cache miss)
94 timing idealTree:node_modules/bash-language-server Completed in 209ms
95 silly placeDep node_modules/bash-language-server @one-ini/wasm@0.1.1 OK for: editorconfig@2.0.0 want: 0.1.1
96 silly placeDep node_modules/bash-language-server/node_modules/editorconfig commander@ OK for: editorconfig@2.0.0 want: ^11.0.0
97 silly placeDep node_modules/bash-language-server/node_modules/editorconfig minimatch@ OK for: editorconfig@2.0.0 want: 9.0.2
98 silly placeDep node_modules/bash-language-server semver@7.6.3 OK for: editorconfig@2.0.0 want: ^7.5.3
99 timing idealTree:node_modules/bash-language-server/node_modules/editorconfig Completed in 6ms
100 timing idealTree:node_modules/bash-language-server/node_modules/@one-ini/wasm Completed in 0ms
101 silly placeDep node_modules/bash-language-server @nodelib/fs.stat@2.0.5 OK for: fast-glob@3.3.2 want: ^2.0.2
102 silly placeDep node_modules/bash-language-server @nodelib/fs.walk@1.2.8 OK for: fast-glob@3.3.2 want: ^1.2.3
103 silly placeDep node_modules/bash-language-server glob-parent@5.1.2 OK for: fast-glob@3.3.2 want: ^5.1.2
104 silly placeDep node_modules/bash-language-server merge2@1.4.1 OK for: fast-glob@3.3.2 want: ^1.3.0
105 silly placeDep node_modules/bash-language-server micromatch@4.0.8 OK for: fast-glob@3.3.2 want: ^4.0.4
106 silly fetch manifest @nodelib/fs.scandir@2.1.5
107 silly fetch manifest fastq@^1.6.0
108 silly fetch manifest is-glob@^4.0.1
109 silly fetch manifest braces@^3.0.3
110 silly fetch manifest picomatch@^2.3.1
111 http fetch GET 200 https://registry.npmjs.org/is-glob 44ms (cache miss)
112 http fetch GET 200 https://registry.npmjs.org/braces 45ms (cache miss)
113 http fetch GET 200 https://registry.npmjs.org/fastq 49ms (cache miss)
114 http fetch GET 200 https://registry.npmjs.org/picomatch 48ms (cache miss)
115 http fetch GET 200 https://registry.npmjs.org/@nodelib%2ffs.scandir 69ms (cache miss)
116 timing idealTree:node_modules/bash-language-server/node_modules/fast-glob Completed in 77ms
117 timing idealTree:node_modules/bash-language-server/node_modules/@nodelib/fs.stat Completed in 0ms
118 silly placeDep node_modules/bash-language-server @nodelib/fs.scandir@2.1.5 OK for: @nodelib/fs.walk@1.2.8 want: 2.1.5
119 silly placeDep node_modules/bash-language-server fastq@1.17.1 OK for: @nodelib/fs.walk@1.2.8 want: ^1.6.0
120 silly fetch manifest run-parallel@^1.1.9
121 silly fetch manifest reusify@^1.0.4
122 http fetch GET 200 https://registry.npmjs.org/run-parallel 35ms (cache miss)
123 http fetch GET 200 https://registry.npmjs.org/reusify 44ms (cache miss)
124 timing idealTree:node_modules/bash-language-server/node_modules/@nodelib/fs.walk Completed in 51ms
125 silly placeDep node_modules/bash-language-server run-parallel@1.2.0 OK for: @nodelib/fs.scandir@2.1.5 want: ^1.1.9
126 silly fetch manifest queue-microtask@^1.2.2
127 http fetch GET 200 https://registry.npmjs.org/queue-microtask 38ms (cache miss)
128 timing idealTree:node_modules/bash-language-server/node_modules/@nodelib/fs.scandir Completed in 41ms
129 silly placeDep node_modules/bash-language-server reusify@1.0.4 OK for: fastq@1.17.1 want: ^1.0.4
130 timing idealTree:node_modules/bash-language-server/node_modules/fastq Completed in 2ms
131 timing idealTree:node_modules/bash-language-server/node_modules/fuzzy-search Completed in 0ms
132 silly placeDep node_modules/bash-language-server is-glob@4.0.3 OK for: glob-parent@5.1.2 want: ^4.0.1
133 silly fetch manifest is-extglob@^2.1.1
134 http fetch GET 200 https://registry.npmjs.org/is-extglob 42ms (cache miss)
135 timing idealTree:node_modules/bash-language-server/node_modules/glob-parent Completed in 45ms
136 silly placeDep node_modules/bash-language-server is-extglob@2.1.1 OK for: is-glob@4.0.3 want: ^2.1.1
137 timing idealTree:node_modules/bash-language-server/node_modules/is-glob Completed in 3ms
138 timing idealTree:node_modules/bash-language-server/node_modules/is-extglob Completed in 0ms
139 timing idealTree:node_modules/bash-language-server/node_modules/merge2 Completed in 0ms
140 silly placeDep node_modules/bash-language-server braces@3.0.3 OK for: micromatch@4.0.8 want: ^3.0.3
141 silly placeDep node_modules/bash-language-server picomatch@2.3.1 OK for: micromatch@4.0.8 want: ^2.3.1
142 silly fetch manifest fill-range@^7.1.1
143 http fetch GET 200 https://registry.npmjs.org/fill-range 43ms (cache miss)
144 timing idealTree:node_modules/bash-language-server/node_modules/micromatch Completed in 51ms
145 silly placeDep node_modules/bash-language-server fill-range@7.1.1 OK for: braces@3.0.3 want: ^7.1.1
146 silly fetch manifest to-regex-range@^5.0.1
147 http fetch GET 200 https://registry.npmjs.org/to-regex-range 36ms (cache miss)
148 timing idealTree:node_modules/bash-language-server/node_modules/braces Completed in 40ms
149 silly placeDep node_modules/bash-language-server to-regex-range@5.0.1 OK for: fill-range@7.1.1 want: ^5.0.1
150 silly fetch manifest is-number@^7.0.0
151 http fetch GET 200 https://registry.npmjs.org/is-number 41ms (cache miss)
152 timing idealTree:node_modules/bash-language-server/node_modules/fill-range Completed in 47ms
153 silly placeDep node_modules/bash-language-server whatwg-url@5.0.0 OK for: node-fetch@2.7.0 want: ^5.0.0
154 silly fetch manifest tr46@~0.0.3
155 silly fetch manifest webidl-conversions@^3.0.0
156 http fetch GET 200 https://registry.npmjs.org/tr46 39ms (cache miss)
157 http fetch GET 200 https://registry.npmjs.org/webidl-conversions 40ms (cache miss)
158 timing idealTree:node_modules/bash-language-server/node_modules/node-fetch Completed in 48ms
159 timing idealTree:node_modules/bash-language-server/node_modules/picomatch Completed in 0ms
160 timing idealTree:node_modules/bash-language-server/node_modules/reusify Completed in 0ms
161 silly placeDep node_modules/bash-language-server queue-microtask@1.2.3 OK for: run-parallel@1.2.0 want: ^1.2.2
162 timing idealTree:node_modules/bash-language-server/node_modules/run-parallel Completed in 3ms
163 timing idealTree:node_modules/bash-language-server/node_modules/queue-microtask Completed in 0ms
164 timing idealTree:node_modules/bash-language-server/node_modules/semver Completed in 0ms
165 silly placeDep node_modules/bash-language-server is-number@7.0.0 OK for: to-regex-range@5.0.1 want: ^7.0.0
166 timing idealTree:node_modules/bash-language-server/node_modules/to-regex-range Completed in 3ms
167 timing idealTree:node_modules/bash-language-server/node_modules/is-number Completed in 0ms
168 silly placeDep node_modules/bash-language-server domino@2.1.6 OK for: turndown@7.1.3 want: ^2.1.6
169 timing idealTree:node_modules/bash-language-server/node_modules/turndown Completed in 3ms
170 timing idealTree:node_modules/bash-language-server/node_modules/domino Completed in 0ms
171 silly placeDep node_modules/bash-language-server vscode-languageserver-protocol@3.17.2 OK for: vscode-languageserver@8.0.2 want: 3.17.2
172 silly fetch manifest vscode-jsonrpc@8.0.2
173 silly fetch manifest vscode-languageserver-types@3.17.2
174 http fetch GET 200 https://registry.npmjs.org/vscode-languageserver-types 36ms (cache miss)
175 http fetch GET 200 https://registry.npmjs.org/vscode-jsonrpc 65ms (cache miss)
176 timing idealTree:node_modules/bash-language-server/node_modules/vscode-languageserver Completed in 69ms
177 silly placeDep node_modules/bash-language-server vscode-jsonrpc@8.0.2 OK for: vscode-languageserver-protocol@3.17.2 want: 8.0.2
178 silly placeDep node_modules/bash-language-server vscode-languageserver-types@3.17.2 OK for: vscode-languageserver-protocol@3.17.2 want: 3.17.2
179 timing idealTree:node_modules/bash-language-server/node_modules/vscode-languageserver-protocol Completed in 3ms
180 timing idealTree:node_modules/bash-language-server/node_modules/vscode-jsonrpc Completed in 0ms
181 timing idealTree:node_modules/bash-language-server/node_modules/vscode-languageserver-textdocument Completed in 0ms
182 timing idealTree:node_modules/bash-language-server/node_modules/vscode-languageserver-types Completed in 0ms
183 timing idealTree:node_modules/bash-language-server/node_modules/web-tree-sitter Completed in 0ms
184 silly placeDep node_modules/bash-language-server tr46@0.0.3 OK for: whatwg-url@5.0.0 want: ~0.0.3
185 silly placeDep node_modules/bash-language-server webidl-conversions@3.0.1 OK for: whatwg-url@5.0.0 want: ^3.0.0
186 timing idealTree:node_modules/bash-language-server/node_modules/whatwg-url Completed in 2ms
187 timing idealTree:node_modules/bash-language-server/node_modules/tr46 Completed in 0ms
188 timing idealTree:node_modules/bash-language-server/node_modules/webidl-conversions Completed in 0ms
189 timing idealTree:node_modules/bash-language-server/node_modules/zod Completed in 0ms
190 timing idealTree:node_modules/bash-language-server/node_modules/editorconfig/node_modules/commander Completed in 0ms
191 timing idealTree:node_modules/bash-language-server/node_modules/editorconfig/node_modules/minimatch Completed in 0ms
192 timing idealTree:buildDeps Completed in 1506ms
193 timing idealTree:fixDepFlags Completed in 1ms
194 timing idealTree Completed in 1522ms
195 timing command:i Completed in 1534ms
196 verbose type range
197 verbose stack commander: No matching version found for commander@^11.0.0.
197 verbose stack     at module.exports (/usr/share/nodejs/npm/node_modules/npm-pick-manifest/lib/index.js:209:23)
197 verbose stack     at RegistryFetcher.manifest (/usr/share/nodejs/pacote/lib/registry.js:117:22)
197 verbose stack     at async Promise.all (index 1)
197 verbose stack     at async [buildDepStep] (/usr/share/nodejs/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1043:5)
197 verbose stack     at async Arborist.buildIdealTree (/usr/share/nodejs/@npmcli/arborist/lib/arborist/build-ideal-tree.js:206:7)
197 verbose stack     at async Arborist.reify (/usr/share/nodejs/@npmcli/arborist/lib/arborist/reify.js:156:5)
197 verbose stack     at async Install.exec (/usr/share/nodejs/npm/lib/commands/install.js:146:5)
197 verbose stack     at async module.exports (/usr/share/nodejs/npm/lib/cli.js:133:5)
198 verbose cwd /home/[private]
199 verbose Linux 6.8.0-45-generic
200 verbose node v18.19.1
201 verbose npm  v9.2.0
202 error code ETARGET
203 error notarget No matching version found for commander@^11.0.0.
204 error notarget In most cases you or one of your dependencies are requesting
204 error notarget a package version that doesn't exist.
205 verbose exit 1
206 timing npm Completed in 1588ms
207 verbose unfinished npm timer reify 1727174169787
208 verbose unfinished npm timer reify:loadTrees 1727174169793
209 verbose code 1
210 error A complete log of this run can be found in:
210 error     /home/[private]/.npm/_logs/2024-09-24T10_36_09_734Z-debug-0.log

@navid-zamani
Copy link
Author

Hmm, by running …

sudo npm i -g commander
sudo npm i -g bash-language-server

… I could install version 5.4.0. Without sudo it said:

npm ERR! code EACCES
npm ERR! syscall mkdir
npm ERR! path /usr/local/lib/node_modules
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules'
npm ERR!  [Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules'] {
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'mkdir',
npm ERR!   path: '/usr/local/lib/node_modules'
npm ERR! }
npm ERR! 
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR! 
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/navid/.npm/_logs/2024-09-24T10_53_00_498Z-debug-0.log

I would have preferred not circumventing my OS’s package manager when installing packages, so this is only a temporary workaround,
and a solution is still needed…

(I know, this is Mint, which always is based on the LTS version of Ubuntu, and so packages are generally a bit outdated. But Mint is quite popular, so… I don’t know if you want to handle this, or not bother. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant