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 failed with LTS Node version12.16.1 #7349

Closed
vkuehn opened this issue Mar 16, 2020 · 16 comments · Fixed by #7968
Closed

Installation failed with LTS Node version12.16.1 #7349

vkuehn opened this issue Mar 16, 2020 · 16 comments · Fixed by #7968
Assignees
Labels
dependencies pull requests that update a dependency file enhancement issues that are enhancements to current functionality - nice to haves help wanted issues meant to be picked up, require help

Comments

@vkuehn
Copy link

vkuehn commented Mar 16, 2020

Description

Reproduction Steps

following the https://github.com/eclipse-theia/theia/blob/master/doc/Developing.md#quick-start guid fails with

error @theia/monorepo@0.0.0: The engine "node" is incompatible with this module. Expected version ">=10.11.0 <12". Got "12.16.1"

OS and Theia version:
OS is Ubuntu 18.04
Node Version is 12.16.1 (LTS)
Git cloned latest theia version

Diagnostics:
no further analytics requiered thought you want see the problem with old docker images

@akosyakov
Copy link
Member

akosyakov commented Mar 16, 2020

error @theia/monorepo@0.0.0: The engine "node" is incompatible with this module. Expected version ">=10.11.0 <12". Got "12.16.1"

Yeah, an error says that it is not supported. Please use Node 10 instead.

@akosyakov akosyakov added the question user / developer questions label Mar 16, 2020
@vkuehn
Copy link
Author

vkuehn commented Mar 16, 2020

ok will do in a docker Image, actually I would hope for a release soon for the latest Node JS version...No ?

@akosyakov
Copy link
Member

akosyakov commented Mar 16, 2020

We align with Node.js version of currently used Electron as minimum. Till we don't upgrade to new version of Electron I don't think active committers will invest into supporting latest Node.js. Someone from the community could invest time and look how to include Node.js 12 in supported range without breaking the minimal version if it is critical for them.

@akosyakov akosyakov added help wanted issues meant to be picked up, require help dependencies pull requests that update a dependency file enhancement issues that are enhancements to current functionality - nice to haves and removed question user / developer questions labels Mar 16, 2020
@akosyakov
Copy link
Member

VS Code extensions are allowed to use Node.js 12 API. It can become a problem if some will do.

@a1994846931931
Copy link
Contributor

We should support Node.js 12.

@kittaakos kittaakos self-assigned this Jun 4, 2020
kittaakos pushed a commit that referenced this issue Jun 4, 2020
Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jun 4, 2020
Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jun 6, 2020
Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jun 8, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.
 - Added a `preinstall` script to warn about Node.js version.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jun 8, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.
 - Added a `preinstall` script to warn about Node.js version.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
@vkuehn
Copy link
Author

vkuehn commented Jun 26, 2020

@kittaakos so that issue can be closed ?

@kittaakos
Copy link
Contributor

so that issue can be closed ?

No, not yet. Here is the PR: #7968

kittaakos pushed a commit that referenced this issue Jul 14, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jul 15, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.
 - Use Node.js 12.14.1 for Gitpod.

Closes #7349

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
akosyakov added a commit that referenced this issue Jul 15, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.
 - Use Node.js 12.14.1 for Gitpod.

Closes #7349

Co-authored-by: Anton Kosyakov <anton.kosyakov@typefox.io>
Signed-off-by: Akos Kitta <kittaakos@typefox.io>
kittaakos pushed a commit that referenced this issue Jul 16, 2020
 - Updated the `@babel` dependencies to fix babel/babel#11216#issuecomment-634460665.
 - Pinned the `node-abi` version in the `resolutions` to support latest `electron`.
 - Use Node.js 12.14.1 for Gitpod.

Closes #7349

Co-authored-by: Anton Kosyakov <anton.kosyakov@typefox.io>
Signed-off-by: Akos Kitta <kittaakos@typefox.io>
@adamretter
Copy link
Contributor

This is great, thank you!

Any chance of a release so that we can test it?

@kittaakos
Copy link
Contributor

Any chance of a release so that we can test it?

I think we have a release scheduled this Thursday, or you can use the next version.

@adamretter
Copy link
Contributor

@kittaakos We did some experimentation with the last release version on Node 10 and Node 12. We found that it would build already for Node12 on Linux, but not on Mac.

However, regardless of the Node version we found that to get it building with Python3 (as opposed to Python 2) we had to force it to use the latest npm-gyp. This was especially relevant for macOS Catalina, see - https://github.com/nodejs/node-gyp/blob/master/macOS_Catalina.md

To do that we had to add a resolutions section to our package.json for yarn:

"resolutions": {
   "node-gyp": "^3.8.0",
   "node-gyp": "^7.0.0"
},

Before you do the next release, I think it might make sense for @theia/electron to also move to the latest node-gyp dependency. What do you think?

You can see our various Linux/macOS Node10/12 Python2/3 builds here: https://travis-ci.com/github/evolvedbinary/fusion-studio-extension/builds/176406238

@kittaakos
Copy link
Contributor

but not on Mac.

I haven't had a build issue on macOS. What's the error? Also, please share a repo, or at least a package.json + yarn.lock combo.

get it building with Python3

We still need Python2 as far as I know.

he latest node-gyp dependency. What do you think?

Sounds good to me, but I won't have the time to change anything wrt the node-gyp version. Are you willing to contribute?


I think we have a release scheduled this Thursday, or you can use the next version.

We have the next release on 30.7, next week.

adamretter added a commit to evolvedbinary/fusion-studio-extension that referenced this issue Jul 21, 2020
@kittaakos
Copy link
Contributor

Here is another issue related to the current node-gyp version: #8065 (comment)

@adamretter
Copy link
Contributor

adamretter commented Jul 21, 2020

@kittaakos Further info:

please share a repo, or at least a package.json + yarn.lock combo.

Sure, it was linked vai Travis, but you can find it directly here: https://github.com/evolvedbinary/fusion-studio-extension/tree/ci-test-adam

I haven't had a build issue on macOS. What's the error? Also, please share a repo, or at least a package.json + yarn.lock combo.

It is as in the Travis CI results page I linked to. This is the error when trying to build against Node12 on macOS (both 10.13 and 10.15):

error /Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/native-keymap: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments: 
Directory: /Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/native-keymap
Output:
gyp info it worked if it ends with ok
gyp info using node-gyp@7.0.0
gyp info using node@12.18.2 | darwin | x64
gyp info find Python using Python version 2.7.10 found at "/usr/bin/python"
gyp info spawn /usr/bin/python
gyp info spawn args [
gyp info spawn args   '/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/native-keymap/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/Users/travis/Library/Caches/node-gyp/12.18.2',
gyp info spawn args   '-Dnode_gyp_dir=/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/Users/travis/Library/Caches/node-gyp/12.18.2/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/native-keymap',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  CXX(target) Release/obj.target/keymapping/src/string_conversion.o
  CXX(target) Release/obj.target/keymapping/src/keymapping.o
  CXX(target) Release/obj.target/keymapping/src/keyboard_mac.o
../src/keyboard_mac.mm:93:34: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _value = String::NewFromUtf8(isolate, "value");
                                 ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:94:38: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withShift = String::NewFromUtf8(isolate, "withShift");
                                     ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:95:38: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withAltGr = String::NewFromUtf8(isolate, "withAltGr");
                                     ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:96:43: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withShiftAltGr = String::NewFromUtf8(isolate, "withShiftAltGr");
                                          ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:98:43: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _valueIsDeadKey = String::NewFromUtf8(isolate, "valueIsDeadKey");
                                          ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:99:47: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withShiftIsDeadKey = String::NewFromUtf8(isolate, "withShiftIsDeadKey");
                                              ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:100:47: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withAltGrIsDeadKey = String::NewFromUtf8(isolate, "withAltGrIsDeadKey");
                                              ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:101:52: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
  Local<String> _withShiftAltGrIsDeadKey = String::NewFromUtf8(isolate, "withShiftAltGrIsDeadKey");
                                                   ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:135:32: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_value, String::NewFromUtf8(isolate, value.second.c_str()));
                               ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:135:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_value, String::NewFromUtf8(isolate, value.second.c_str()));
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:136:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_valueIsDeadKey, value.first ? _true : _false);
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:139:36: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShift, String::NewFromUtf8(isolate, withShift.second.c_str()));
                                   ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:139:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShift, String::NewFromUtf8(isolate, withShift.second.c_str()));
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:140:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShiftIsDeadKey, withShift.first ? _true : _false);
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:143:36: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withAltGr, String::NewFromUtf8(isolate, withAltGr.second.c_str()));
                                   ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:143:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withAltGr, String::NewFromUtf8(isolate, withAltGr.second.c_str()));
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:144:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withAltGrIsDeadKey, withAltGr.first ? _true : _false);
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:147:41: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShiftAltGr, String::NewFromUtf8(isolate, withShiftAltGr.second.c_str()));
                                        ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:147:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShiftAltGr, String::NewFromUtf8(isolate, withShiftAltGr.second.c_str()));
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:148:12: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    entry->Set(_withShiftAltGrIsDeadKey, withShiftAltGr.first ? _true : _false);
           ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:150:25: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, code), entry);
                        ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:150:13: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, code), entry);
            ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:162:25: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "id"), String::NewFromUtf8(isolate, std::string([(NSString *)sourceId UTF8String]).c_str()));
                        ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:162:61: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "id"), String::NewFromUtf8(isolate, std::string([(NSString *)sourceId UTF8String]).c_str()));
                                                            ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:162:13: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "id"), String::NewFromUtf8(isolate, std::string([(NSString *)sourceId UTF8String]).c_str()));
            ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:168:25: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "localizedName"), String::NewFromUtf8(isolate, std::string([(NSString *)localizedName UTF8String]).c_str()));
                        ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:168:72: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "localizedName"), String::NewFromUtf8(isolate, std::string([(NSString *)localizedName UTF8String]).c_str()));
                                                                       ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:168:13: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
    result->Set(String::NewFromUtf8(isolate, "localizedName"), String::NewFromUtf8(isolate, std::string([(NSString *)localizedName UTF8String]).c_str()));
            ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:175:27: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
      result->Set(String::NewFromUtf8(isolate, "lang"), String::NewFromUtf8(isolate, std::string([lang UTF8String]).c_str()));
                          ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:175:65: warning: 'NewFromUtf8' is deprecated: Use maybe version [-Wdeprecated-declarations]
      result->Set(String::NewFromUtf8(isolate, "lang"), String::NewFromUtf8(isolate, std::string([lang UTF8String]).c_str()));
                                                                ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3030:10: note: 'NewFromUtf8' has been explicitly marked deprecated here
  static V8_DEPRECATED(
         ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:175:15: warning: 'Set' is deprecated: Use maybe version [-Wdeprecated-declarations]
      result->Set(String::NewFromUtf8(isolate, "lang"), String::NewFromUtf8(isolate, std::string([lang UTF8String]).c_str()));
              ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8.h:3498:3: note: 'Set' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/travis/Library/Caches/node-gyp/12.18.2/include/node/v8config.h:328:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
../src/keyboard_mac.mm:198:7: error: no template named 'Handle' in namespace 'v8'
  v8::Handle<v8::Value> argv[argc];
  ~~~~^
../src/keyboard_mac.mm:209:7: error: no template named 'Handle' in namespace 'v8'
  v8::Handle<v8::Function> arg0 = v8::Handle<v8::Function>::Cast(args[0]);
  ~~~~^
../src/keyboard_mac.mm:209:58: error: expected '(' for function-style cast or type construction
  v8::Handle<v8::Function> arg0 = v8::Handle<v8::Function>::Cast(args[0]);
                                             ~~~~~~~~~~~~^
../src/keyboard_mac.mm:209:39: error: no member named 'Handle' in namespace 'v8'
  v8::Handle<v8::Function> arg0 = v8::Handle<v8::Function>::Cast(args[0]);
                                  ~~~~^
../src/keyboard_mac.mm:209:61: error: no member named 'Cast' in the global namespace
  v8::Handle<v8::Function> arg0 = v8::Handle<v8::Function>::Cast(args[0]);
                                                          ~~^
31 warnings and 5 errors generated.
make: *** [Release/obj.target/keymapping/src/keyboard_mac.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Darwin 17.4.0
gyp ERR! command "/Users/travis/.nvm/versions/node/v12.18.2/bin/node" "/Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /Users/travis/build/evolvedbinary/fusion-studio-extension/node_modules/native-keymap
gyp ERR! node -v v12.18.2
gyp ERR! node-gyp -v v7.0.0
gyp ERR! not ok
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

We still need Python2 as far as I know.

As per my Travis CI results - it builds fine with Python 3, but ONLY if you update to the latest node-gyp.

Are you willing to contribute?

Absolutely. What's the process? Just send a PR? do you have automated CI etc to check it for me?

@kittaakos
Copy link
Contributor

@adamretter, I have started a macOS build with Node.js: https://travis-ci.com/github/eclipse-theia/theia/jobs/363327516
We can build the project on macOS with Node.js 12.x.

To do that we had to add a resolutions section to our package.json for yarn:

"resolutions": {

Adding resolutions is the preferred way. Please do not consider it as a hack. We do this in downstream projects, in the theia-apps repo, we even do it for theia.

As per my Travis CI results - it builds fine with Python 3, but ONLY if you update to the latest node-gyp.

So if I understood you correctly; your goal is to be able to build with Python3 on macOS. For that, we need to increase the node-gyp version. Please keep in mind, we cannot drop Python2 even if can build Python3 after your change.

Absolutely.

Great.

What's the process?

https://github.com/eclipse-theia/theia#contributing

Just send a PR?

Yes.

do you have automated CI etc to check it for me?

Yes.

@adamretter
Copy link
Contributor

adamretter commented Jul 21, 2020

So if I understood you correctly; your goal is to be able to build with Python3 on macOS. For that, we need to increase the node-gyp version. Please keep in mind, we cannot drop Python2 even if can build Python3 after your change.

I want to build with Python 2 and 3 on all platforms. We have that working here by updating the node-gyp version.
I will try and send a PR to do that in Theia itself.

I also want to be able to build for NodeJS 12 as well as NodeJS 10. Using the latest release, i.e. before the PR #7968, my experience is that NodeJS 12 fails on macOS, I will now test with the latest HEAD code.

I will send a separate PR to increase the number of your Travis CI jobs to cover that platform too.

@kittaakos
Copy link
Contributor

Python 2 and 3 on all platforms.

Sounds great!

build for NodeJS 12 as well as NodeJS 10

OK. Note, we will drop Node.js 10.x soon. #8184

I will send a separate PR to increase the number of your Travis CI jobs

Watch out, that might get rejected as we do not want to unnecessarily increase the build time.

westbury pushed a commit to ARMmbed/theia that referenced this issue Nov 9, 2020
westbury pushed a commit to ARMmbed/theia that referenced this issue Nov 10, 2020
westbury pushed a commit to ARMmbed/theia that referenced this issue Nov 10, 2020
arekzaluski added a commit to ARMmbed/theia that referenced this issue Nov 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies pull requests that update a dependency file enhancement issues that are enhancements to current functionality - nice to haves help wanted issues meant to be picked up, require help
Projects
None yet
5 participants