-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
TypeError: '>=' not supported between instances of 'tuple' and 'str' #1917
Comments
This was fixed in the last few weeks... Can you please try with a more current release? |
That comparison is still in the master branch. So I don’t understand how it could have been fixed. |
Yes but the line that you changed is line 1494 but the traceback above is complaining about line 1529 which does not contain the code in question: https://github.com/nodejs/node-gyp/blob/master/gyp/pylib/gyp/xcode_emulation.py#L1529 @sam-github My sense is that this relates to gyp roundtrip but it is not yet clear. |
In the traceback node-gyp v5.0.5 is being used but the line number still looks off (although much closer to the code in question): https://github.com/nodejs/node-gyp/blob/v5.0.5/gyp/pylib/gyp/xcode_emulation.py#L1529 |
Got the same error, but with the correct line number:
|
https://github.com/nodejs/node-gyp/blob/master/gyp/pylib/gyp/xcode_emulation.py#L1527 throws because https://github.com/nodejs/node-gyp/blob/v5.0.5/gyp/pylib/gyp/xcode_emulation.py#L1294-L1295 sets |
Hi. I have the same error after I updated xCode to the newest version(if it helps). |
@MusicalEcho What does your traceback say for the following lines?
|
Another package, but yep everything else is the same |
$ |
|
Resolve with updating node and : |
I updated node to 12.13.1 and have the latest packages - nothing changed |
I'm also seeing this error today.
MacBook-Pro:node jesse$ python --version
Python 3.6.8
MacBook-Pro:node jesse$ npm -v
6.12.0
MacBook-Pro:node jesse$ node -v
v12.13.0 What is the recommended fix since this issue is closed? |
I'm also seeing this error. What is the recommended fix?
|
node-gyp v6.0.1 68319a2 |
Anyone know when this will get integrated into NPM? It seems like NPM is still using v5.0.5 of node-gyp, and I don't seem to be able to find any pull requests for updating node-gyp. I'm unable to install a package right now because NPM is using a broken node-gyp. |
Not to detract from the I think In my case, on a mac, I resolved this issue locally by adding the following to my "optionalDependencies": {
"fsevents": "^1.2.9"
}, This allowed the binary package for Again, this shouldn't detract from the |
My issue is actually with Note that when I was implementing the tool changes, I used yarn, but I use NPM for installing packages globally. It worked without any issues in yarn, so I was rather surprised when the global NPM installs failed. |
The last three comments do not pertain to this issue. Perhaps find the right repo to open a new issue on.
Wrong repo. Check out npm/cli#276 (comment) |
Sorry about that. I wasn't finding anything on NPM and wasn't sure where to post since they don't have an issues tab and I wasn't too sure about joining the forum just to ask a single question, so I ended up posting here since it was related to the error I was getting. Thanks for bringing the topic up on the NPM repo for me. |
A workaround that worked for me was running:
Found out about this here: |
work like a charm |
It worked for me as well! 👍 |
The corresponding issue to get the version bundled with npm updated seems to be this: npm/cli#287 |
Addressing the contention that this is because npm is shipping node-gyp 6 rather than 5: node-gyp v6 should be almost the same as node-gyp v5, if someone still experiencing this issue can demonstrate a difference between v5 and v6 that's causing it then we'll fix v5 and ship it. On
The diff between the two consists primarily of switching the preference order between Python 2 and 3 such that node-gyp 6 prefers the latter and 5 the former, we consider that "breaking" change. In fact, a diff between the two branches, excluding tests and docs, reveals mainly Python version checking changes and #1978 which is an unrelated feature yet to be included in a 5.x. Perhaps there's a Python 3 problem here and you're experiencing it because your system has both and it's opting for 2 with node-gyp 5 but is fixed when it opts for 3. You could test that by switching to Python 3 using node-gyp 5 (current npm version): https://github.com/nodejs/node-gyp#configuring-python-dependency If this is still broken, help us fix it, we are still maintaining v5.x but none of us are getting this problem on our own systems. |
@rvagg Here is something. On my MacOS system we use With this python as my default python version, I get what's described here: ranisalt/node-argon2#230 and what's described in this issue (>= tuple str...) If I temporarily disable this and use the MacOS system 2.7 python - the build succeeds. I was not expecting this. I am surprised by this. v3 should work with v5.0.5 since it's a supported version, shouldn't it? In our situation, this is a breaker- we can't simply downgrade to python 2 for this one build nor do we want to mandate to the consumers of our source code that they have to manually configure node-gyp to use python2. I'd say this is a bug with v5.0.5 with python3... |
Thanks for mentioning the release numnber @cclauss . Too bad upstream npm is still using 5.0.5 which is what everyone has. Is there any coordination with the NPM CLI team on bumping minor revs? They've even had a release since 5.0.6 came out. :( |
Nice workaround... #2031 (comment) |
see with the following issue #278 |
node-gyp v6.0.1 68319a2 |
node v10.15.3
npm 6.4.1
Darwin AdamsVoBookPro3 19.0.0 Darwin Kernel Version 19.0.0: Wed Sep 25 20:18:50 PDT 2019; root:xnu-6153.11.26~2/RELEASE_X86_64 x86_64
electron-rebuild
Verbose output (from npm or node-gyp):
If I update the comparison on the line here to the following, it works:
However, I'm not sure if it's supposed to work like that or not.
The text was updated successfully, but these errors were encountered: