eclipse-theia / theia

Eclipse Theia is a cloud & desktop IDE framework implemented in TypeScript.
http://theia-ide.org
Eclipse Public License 2.0
20.06k stars 2.5k forks source link

yarn theia start doesn't recieve message to confirm #7259

Closed kharazit closed 4 years ago

kharazit commented 4 years ago

Description

I have a working build of theia on my machine, but I can't seem to get the webpage to load. ### Reproduction Steps

I am running theia on an Ubuntu 18.04 node via ssh. When I run yarn theia start I see the following:

cades@kharazi-cades-dev:~/theia$ yarn theia start
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia start
root INFO Configuring to accept webviews on '.+.webview..+' hostname.
root INFO Deploy plugins list took: 5.5 ms
root INFO Theia app listening on http://localhost:3000.

Where it will stay like the above indefinitely. When I attempt to open that in my browser @IPADDRESS:3000, I get a "unable to connect" error in firefox with all proxy settings set to "off". What is strange is that at one point in time I do recall it working properly and I was able to interact with the web gui. However, when I came back and tried the command again it wouldn't work.
OS and Theia version: OS: Ubuntu 18.04 Theia: 0.17-next.6d0abe58

Diagnostics:

cades@kharazi-cades-dev:~/theia$ nvm --version
0.33.5
cades@kharazi-cades-dev:~/theia$ node -v
v8.17.0
cades@kharazi-cades-dev:~/theia$ yarn -v
1.22.0
cades@kharazi-cades-dev:~/theia$ npm -v
6.13.4
cades@kharazi-cades-dev:~/theia$ yarn theia check:hoisted
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia check:hoisted
🔍  Analyzing hoisted dependencies in the Theia extensions...
{ Error: ENOENT: no such file or directory, scandir '/home/cades/theia/packages'
    at Object.fs.readdirSync (fs.js:904:18)
    at collectIssues (/home/cades/theia/node_modules/@theia/cli/lib/check-hoisting.js:58:35)
    at Object.assert [as default] (/home/cades/theia/node_modules/@theia/cli/lib/check-hoisting.js:139:18)
    at Object.handler (/home/cades/theia/node_modules/@theia/cli/lib/theia.js:188:41)
    at Object.runCommand (/home/cades/theia/node_modules/yargs/lib/command.js:235:44)
    at Object.parseArgs [as _parseArgs] (/home/cades/theia/node_modules/yargs/yargs.js:1022:30)
    at Object.get [as argv] (/home/cades/theia/node_modules/yargs/yargs.js:965:21)
    at /home/cades/theia/node_modules/@theia/cli/lib/theia.js:304:38
    at Object.<anonymous> (/home/cades/theia/node_modules/@theia/cli/lib/theia.js:314:3)
    at Module._compile (module.js:653:30)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/cades/theia/packages' }
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Any help would be greatly appreciated.

vince-fugnitto commented 4 years ago

@kharazit do you mind sharing your package.json?

kharazit commented 4 years ago
{
  "private": true,
  "dependencies": {
    "@theia/callhierarchy": "next",
    "@theia/file-search": "next",
    "@theia/git": "^0.17.0-next.e48b9b5f",
    "@theia/json": "next",
    "@theia/markers": "next",
    "@theia/messages": "next",
    "@theia/mini-browser": "next",
    "@theia/navigator": "next",
    "@theia/outline-view": "next",
    "@theia/plugin-ext-vscode": "next",
    "@theia/preferences": "next",
    "@theia/preview": "next",
    "@theia/search-in-workspace": "next",
    "@theia/terminal": "next"
  },
  "devDependencies": {
    "@theia/cli": "next"
  }
}
vince-fugnitto commented 4 years ago

@kharazit is there a specific reason you're using that version of @theia/git? I suspect that if you open your devtools you will notice an error similar to https://github.com/eclipse-theia/theia/issues/7248.

Generally, it is not possible to use different versions of Theia extensions as they will pull different transitive dependencies. For instance, you will pull two versions of @theia/core which will cause issues (as the application will not know which to successfully use). Using a next version of @theia/git should resolve the problem.

kittaakos commented 4 years ago

@kharazit, please use Node.js 10.x.

cades@kharazi-cades-dev:~/theia$ node -v v8.17.0

From Prerequisites

Node.js >= 10.11.0 AND < 12.x.

kharazit commented 4 years ago

Okay I did the above:

  "private": true,
  "dependencies": {
    "@theia/callhierarchy": "next",
    "@theia/file-search": "next",
    "@theia/git": "next",
    "@theia/json": "next",
    "@theia/markers": "next",
    "@theia/messages": "next",
    "@theia/mini-browser": "next",
    "@theia/navigator": "next",
    "@theia/outline-view": "next",
    "@theia/plugin-ext-vscode": "next",
    "@theia/preferences": "next",
    "@theia/preview": "next",
    "@theia/search-in-workspace": "next",
    "@theia/terminal": "next"
  },
  "devDependencies": {
    "@theia/cli": "next"
  }
}
cades@kharazi-cades-dev:~/theia$ node --version
v10.19.0

However, when I run yarn theia build, I get:

yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia clean
Done in 0.48s.
cades@kharazi-cades-dev:~/theia$ yarn theia build
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia build
(node:35153) DeprecationWarning: Tapable.apply is deprecated. Call apply on the plugin directly instead

<--- Last few GCs --->

[35153:0x27b4f30]    50769 ms: Mark-sweep 1329.0 (1444.2) -> 1322.2 (1447.2) MB, 899.3 / 0.0 ms  (average mu = 0.113, current mu = 0.035) allocation failure scavenge might not succeed
[35153:0x27b4f30]    51471 ms: Mark-sweep 1333.6 (1447.2) -> 1325.5 (1448.7) MB, 638.5 / 0.0 ms  (average mu = 0.103, current mu = 0.091) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x1fd5fc0dbe1d]
    1: StubFrame [pc: 0x1fd5fc0934b0]
Security context: 0x3c193ae9e6e9 <JSObject>
    2: /* anonymous */(aka /* anonymous */) [0x1ae124402289] [/home/cades/theia/node_modules/webpack-sources/lib/applySourceMap.js:~58] [pc=0x1fd5fd1c995c](this=0x0ac0284026f1 <undefined>,chunk=0x35a40a2a2221 <String[1]: {>,middleMapping=0x0b4f3fc2cb01 <Object map = 0x3b8c5ea799f1>)
    3: SourceNode_walk [0x2c7b6b977f29...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x1fd5fc0dbe1d

Error: webpack exited with an unexpected signal: SIGABRT.
    at ChildProcess.<anonymous> (/home/cades/theia/node_modules/@theia/application-manager/lib/application-process.js:59:28)
    at ChildProcess.emit (events.js:198:13)
    at maybeClose (internal/child_process.js:982:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

And if I try yarn theia start I get:

cades@kharazi-cades-dev:~/theia$ yarn theia start
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia start
internal/modules/cjs/loader.js:807
  return process.dlopen(module, path.toNamespacedPath(filename));
                 ^

Error: The module '/home/cades/theia/node_modules/nsfw/build/Release/nsfw.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 57. This version of Node.js requires
NODE_MODULE_VERSION 64. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:807:18)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at Object.<anonymous> (/home/cades/theia/node_modules/nsfw/lib/src/index.js:3:16)
    at Module._compile (internal/modules/cjs/loader.js:778:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
Done in 0.84s.
kittaakos commented 4 years ago

However, when I run yarn theia build, I get:

Try to increase the heap size for the build. Set the NODE_OPTIONS env variable to --max_old_space_size=4096.

And if I try yarn theia start I get:

The build has failed, do not expect you can run. Let us know if the issue still persists after increasing the heap size.

kharazit commented 4 years ago

Yes I did so. Still failing.

cades@kharazi-cades-dev:~/theia$ set NODE_OPTIONS=--max_old_space_size=4096
cades@kharazi-cades-dev:~/theia$ yarn theia build
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia build
(node:37538) DeprecationWarning: Tapable.apply is deprecated. Call apply on the plugin directly instead

<--- Last few GCs --->

[37550:0x3c96080]    96308 ms: Mark-sweep 1322.7 (1450.4) -> 1314.5 (1453.9) MB, 718.3 / 0.0 ms  (average mu = 0.097, current mu = 0.033) allocation failure scavenge might not succeed
[37550:0x3c96080]    97444 ms: Mark-sweep 1326.4 (1453.9) -> 1318.3 (1455.9) MB, 1116.7 / 0.0 ms  (average mu = 0.050, current mu = 0.017) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x725dc8dbe1d]
    1: StubFrame [pc: 0x725dc8dd1df]
Security context: 0x222ccca1e6e9 <JSObject>
    2: SourceMapGenerator_serializeMappings [0x2354396dadd1] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~312] [pc=0x725dd32d835](this=0x3cc943193009 <SourceMapGenerator map = 0x3b2c37b5a571>)
    3: SourceMapGenerator_toJSON [0x2354396dae51] [/home/cades/theia/node_modules/source-map/lib/source-...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x725dc8dbe1d

<--- Last few GCs --->

[37682:0x38f0080]    91123 ms: Scavenge 1305.2 (1418.4) -> 1304.7 (1418.9) MB, 3.6 / 0.0 ms  (average mu = 0.131, current mu = 0.016) allocation failure
[37682:0x38f0080]    91855 ms: Mark-sweep 1305.4 (1418.9) -> 1304.9 (1419.4) MB, 730.6 / 0.0 ms  (average mu = 0.076, current mu = 0.010) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x3b7ad415be1d]
    1: StubFrame [pc: 0x3b7ad415d3a6]
Security context: 0x1fcd40f1e6e9 <JSObject>
    2: SourceMapGenerator_serializeMappings [0x2bd277adac81] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~312] [pc=0x3b7ad4fcae5c](this=0x214282b05a11 <SourceMapGenerator map = 0x17b6124067c9>)
    3: SourceMapGenerator_toJSON [0x2bd277adad01] [/home/cades/theia/node_modules/source-map/lib/sour...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory

 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x3b7ad415be1d

^[[1;2D

<--- Last few GCs --->

[37697:0x4296080]    89335 ms: Mark-sweep 1320.9 (1449.9) -> 1312.8 (1453.4) MB, 731.8 / 0.0 ms  (average mu = 0.103, current mu = 0.027) allocation failure scavenge might not succeed
[37697:0x4296080]    90446 ms: Mark-sweep 1324.6 (1453.4) -> 1316.6 (1455.9) MB, 1092.6 / 0.0 ms  (average mu = 0.054, current mu = 0.017) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x1dab0615be1d]
    1: StubFrame [pc: 0x1dab0615d3a6]
Security context: 0x21c1d6a9e6e9 <JSObject>
    2: SourceMapGenerator_serializeMappings [0x217dff15ad91] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~312] [pc=0x1dab06dbc03c](this=0x2abea480d341 <SourceMapGenerator map = 0x3bac4376e681>)
    3: SourceMapGenerator_toJSON [0x217dff15ae11] [/home/cades/theia/node_modules/source-map/lib/sour...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory

 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x1dab0615be1d

<--- Last few GCs --->

[37709:0x3ef3080]    80259 ms: Mark-sweep 1318.8 (1447.4) -> 1310.8 (1451.9) MB, 737.2 / 0.0 ms  (average mu = 0.119, current mu = 0.025) allocation failure scavenge might not succeed
[37709:0x3ef3080]    81360 ms: Mark-sweep 1322.7 (1451.9) -> 1314.6 (1454.4) MB, 1081.9 / 0.0 ms  (average mu = 0.060, current mu = 0.017) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x216bda05be1d]
    1: StubFrame [pc: 0x216bda05d3a6]
Security context: 0x16810e11e6e9 <JSObject>
    2: base64VLQ_encode [0x3c8209c577d1] [/home/cades/theia/node_modules/source-map/lib/base64-vlq.js:~92] [pc=0x216bda8396b9](this=0x3824f8a10221 <Object map = 0x356f383f7c1>,aValue=6519)
    3: SourceMapGenerator_serializeMappings [0x3c8209c5ae31] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory

 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x216bda05be1d

<--- Last few GCs --->

[37788:0x3a8c080]    91388 ms: Mark-sweep 1319.0 (1451.4) -> 1311.0 (1454.4) MB, 1252.2 / 0.0 ms  (average mu = 0.062, current mu = 0.014) allocation failure scavenge might not succeed
[37788:0x3a8c080]    92299 ms: Mark-sweep 1322.9 (1454.4) -> 1314.9 (1455.9) MB, 893.8 / 0.0 ms  (average mu = 0.044, current mu = 0.020) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x283190ddbe1d]
    1: StubFrame [pc: 0x283190ddd3a6]
Security context: 0x1b51a941e6e9 <JSObject>
    2: SourceMapGenerator_serializeMappings [0x31dc1dbdacd9] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~312] [pc=0x2831918ec843](this=0x0c5f46954b69 <SourceMapGenerator map = 0x28e615f975f9>)
    3: SourceMapGenerator_toJSON [0x31dc1dbdad59] [/home/cades/theia/node_modules/source-map/lib/sour...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory

 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x283190ddbe1d

<--- Last few GCs --->

[37834:0x2862080]    84843 ms: Mark-sweep 1316.9 (1446.9) -> 1308.9 (1450.9) MB, 660.3 / 0.0 ms  (average mu = 0.154, current mu = 0.028) allocation failure scavenge might not succeed
[37834:0x2862080]    85566 ms: Mark-sweep 1320.8 (1450.9) -> 1312.7 (1454.4) MB, 704.2 / 0.0 ms  (average mu = 0.091, current mu = 0.026) allocation failure scavenge might not succeed

<--- JS stacktrace --->

==== JS stack trace =========================================

    0: ExitFrame [pc: 0x35dd54dbe1d]
    1: StubFrame [pc: 0x35dd54dd3a6]
Security context: 0x0516d0f9e6e9 <JSObject>
    2: SourceMapGenerator_serializeMappings [0x2fff6be5ad19] [/home/cades/theia/node_modules/source-map/lib/source-map-generator.js:~312] [pc=0x35dd5eeb07c](this=0x21dfe4103f51 <SourceMapGenerator map = 0xa423760e6a1>)
    3: SourceMapGenerator_toJSON [0x2fff6be5ad99] [/home/cades/theia/node_modules/source-map/lib/source-m...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory

 1: 0x8fa090 node::Abort() [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 2: 0x8fa0dc  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 3: 0xb0052e v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 4: 0xb00764 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 5: 0xef4c72  [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 6: 0xef4d78 v8::internal::Heap::CheckIneffectiveMarkCompact(unsigned long, double) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 7: 0xf00e52 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 8: 0xf01784 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

 9: 0xf043f1 v8::internal::Heap::AllocateRawWithRetryOrFail(int, v8::internal::AllocationSpace, v8::internal::AllocationAlignment) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

10: 0xecd874 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]

11: 0x116d9fe v8::internal::Runtime_AllocateInNewSpace(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cades/.nvm/versions/node/v10.19.0/bin/node]
12: 0x35dd54dbe1d
kittaakos commented 4 years ago

I think you have to use export as you need to pass the variables not just to the current shell but all processes spawned by the shell. Please try:

export NODE_OPTIONS="--max_old_space_size=4096"
yarn
kharazit commented 4 years ago
cades@kharazi-cades-dev:~/theia$ export NODE_OPTIONS="--max_old_space_size=4096"
cades@kharazi-cades-dev:~/theia$ yarn
yarn install v1.22.0
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/4] Resolving packages...
success Already up-to-date.
Done in 0.91s.

Also, it seemed the build worked this time, however the issue about the system still sitting there without opening up a browser still persists.

cades@kharazi-cades-dev:~/theia$ yarn theia build
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia build
(node:38001) DeprecationWarning: Tapable.apply is deprecated. Call apply on the plugin directly instead

Hash: 6fbc8dc6583dd9659ded
Version: webpack 4.42.0
Time: 124109ms
Built at: 03/03/2020 11:20:12 AM
                                     Asset       Size  Chunks                                Chunk Names
    0a32a80243e05284a5d741c5dc093f31.woff2   23.8 KiB          [emitted]
    11d1a2390613abf202bfd2ebbd5c4500.woff2   88.6 KiB          [emitted]
      674f50d287a8c48dc19ba404d20fe713.eot    162 KiB          [emitted]
   674f50d287a8c48dc19ba404d20fe713.eot.gz   95.9 KiB          [emitted]
      912ec66d7572ff821749319396470bde.svg    434 KiB          [emitted]              [big]
   912ec66d7572ff821749319396470bde.svg.gz    131 KiB          [emitted]
    af7ae505a9eed503f8b8e6982036873e.woff2   75.4 KiB          [emitted]
      b06871f281fee6b241d60582ae9369b9.ttf    162 KiB          [emitted]
   b06871f281fee6b241d60582ae9369b9.ttf.gz   95.8 KiB          [emitted]
                                 bundle.js   9.62 MiB       0  [emitted]              [big]  main
                              bundle.js.gz   2.02 MiB          [emitted]              [big]
                             bundle.js.map   21.8 MiB       0  [emitted] [dev]               main
                          bundle.js.map.gz   4.96 MiB          [emitted]              [big]
      cf2aabacdc2b3a5768b03545cb1d8330.svg     21 KiB          [emitted]
   cf2aabacdc2b3a5768b03545cb1d8330.svg.gz   5.18 KiB          [emitted]
    de59a97248b44599e6747a27a943f738.woff2   19.8 KiB          [emitted]
    e19892df121e7f85c61754c54bbb7951.woff2   48.6 KiB          [emitted]
      e817279537a0417d042f62fbb1b99eea.gif   43.1 KiB          [emitted]
     f8f821a66b20e5801e35df5ec4565b30.wasm    583 KiB          [emitted]              [big]
  f8f821a66b20e5801e35df5ec4565b30.wasm.gz    157 KiB          [emitted]
     fee66e712a8a08eef5805a46892932ad.woff   95.7 KiB          [emitted]
              vs/base/worker/workerMain.js    143 KiB          [emitted]
           vs/base/worker/workerMain.js.gz   40.5 KiB          [emitted]
                 vs/editor/editor.main.css    289 KiB          [emitted]              [big]
              vs/editor/editor.main.css.gz   72.5 KiB          [emitted]
                  vs/editor/editor.main.js   2.23 MiB          [emitted]              [big]
               vs/editor/editor.main.js.gz    525 KiB          [emitted]              [big]
           vs/editor/editor.main.nls.de.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.de.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.es.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.es.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.fr.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.fr.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.it.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.it.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.ja.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.ja.js.gz   10.1 KiB          [emitted]
              vs/editor/editor.main.nls.js   40.4 KiB          [emitted]
           vs/editor/editor.main.nls.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.ko.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.ko.js.gz   10.1 KiB          [emitted]
           vs/editor/editor.main.nls.ru.js   40.4 KiB          [emitted]
        vs/editor/editor.main.nls.ru.js.gz   10.1 KiB          [emitted]
        vs/editor/editor.main.nls.zh-cn.js   40.4 KiB          [emitted]
     vs/editor/editor.main.nls.zh-cn.js.gz   10.1 KiB          [emitted]
        vs/editor/editor.main.nls.zh-tw.js   40.4 KiB          [emitted]
     vs/editor/editor.main.nls.zh-tw.js.gz   10.1 KiB          [emitted]
                vs/language/css/cssMode.js    727 KiB          [emitted]              [big]
             vs/language/css/cssMode.js.gz    141 KiB          [emitted]
              vs/language/css/cssWorker.js    718 KiB          [emitted]              [big]
           vs/language/css/cssWorker.js.gz    138 KiB          [emitted]
    vs/language/css/monaco.contribution.js   2.59 KiB          [emitted]
 vs/language/css/monaco.contribution.js.gz  987 bytes          [emitted]
              vs/language/html/htmlMode.js    436 KiB          [emitted]              [big]
           vs/language/html/htmlMode.js.gz     99 KiB          [emitted]
            vs/language/html/htmlWorker.js    425 KiB          [emitted]              [big]
         vs/language/html/htmlWorker.js.gz   96.7 KiB          [emitted]
   vs/language/html/monaco.contribution.js   2.72 KiB          [emitted]
vs/language/html/monaco.contribution.js.gz   1.08 KiB          [emitted]
                              vs/loader.js   29.5 KiB          [emitted]
                           vs/loader.js.gz    8.7 KiB          [emitted]
        worker-ext.7156bc31776746887d21.js    540 KiB          [emitted] [immutable]  [big]
     worker-ext.7156bc31776746887d21.js.gz    119 KiB          [emitted]
    worker-ext.7156bc31776746887d21.js.map   1.83 MiB          [emitted] [dev]
 worker-ext.7156bc31776746887d21.js.map.gz    419 KiB          [emitted]              [big]
Entrypoint main [big] = bundle.js bundle.js.map
 [115] (webpack)/buildin/global.js 472 bytes {0} [built]
 [142] ./node_modules/jsonc-parser/lib/esm/main.js + 4 modules 57.2 KiB {0} [built]
       |    5 modules
 [369] ./node_modules/react-virtualized/dist/es/index.js + 69 modules 327 KiB {0} [built]
       |    70 modules
 [854] (webpack)/buildin/module.js 497 bytes {0} [built]
[1352] ./src-gen/frontend/index.js 5.72 KiB {0} [built]
[1532] ./node_modules/@theia/core/src/common/keyboard/layouts sync ^\.\/.*\.json$ 1.39 KiB {0} [built]
[1734] ./node_modules/moment/locale sync ^\.\/.*$ 3 KiB {0} [optional] [built]
[1830] ./node_modules/vscode-textmate/release sync 160 bytes {0} [built]
[1943] ./node_modules/@theia/scm/node_modules/@theia/core/src/common/keyboard/layouts sync ^\.\/.*\.json$ 1.39 KiB {0} [built]
[2149] ./node_modules/@theia/scm-extra/node_modules/@theia/core/src/common/keyboard/layouts sync ^\.\/.*\.json$ 1.39 KiB {0} [built]
[2340] ./node_modules/@theia/git/node_modules/@theia/core/src/common/keyboard/layouts sync ^\.\/.*\.json$ 1.39 KiB {0} [built]
[2968] ./node_modules/idb/build/esm/index.js + 1 modules 10.1 KiB {0} [built]
       |    2 modules
    + 2957 hidden modules

WARNING in ./node_modules/vscode-textmate/release/main.js 23:15-27
Critical dependency: the request of a dependency is an expression
 @ ./node_modules/@theia/monaco/lib/browser/textmate/monaco-textmate-service.js
 @ ./node_modules/@theia/monaco/lib/browser/textmate/index.js
 @ ./node_modules/@theia/plugin-ext/lib/main/browser/plugin-contribution-handler.js
 @ ./node_modules/@theia/plugin-ext/lib/main/browser/plugin-ext-frontend-module.js
 @ ./node_modules/@theia/plugin-ext/lib/plugin-ext-frontend-module.js
 @ ./src-gen/frontend/index.js

WARNING in ./node_modules/vscode-textmate/release/main.js
Module Warning (from ./node_modules/source-map-loader/index.js):
(Emitted value instead of an instance of Error) Cannot find SourceMap 'main.js.map': Error: Can't resolve './main.js.map' in '/home/cades/theia/node_modules/vscode-textmate/release'
 @ ./node_modules/@theia/monaco/lib/browser/textmate/monaco-textmate-service.js 73:24-50
 @ ./node_modules/@theia/monaco/lib/browser/textmate/index.js
 @ ./node_modules/@theia/plugin-ext/lib/main/browser/plugin-contribution-handler.js
 @ ./node_modules/@theia/plugin-ext/lib/main/browser/plugin-ext-frontend-module.js
 @ ./node_modules/@theia/plugin-ext/lib/plugin-ext-frontend-module.js
 @ ./src-gen/frontend/index.js

WARNING in asset size limit: The following asset(s) exceed the recommended size limit (244 KiB).
This can impact web performance.
Assets:
  worker-ext.7156bc31776746887d21.js (540 KiB)
  912ec66d7572ff821749319396470bde.svg (434 KiB)
  f8f821a66b20e5801e35df5ec4565b30.wasm (583 KiB)
  bundle.js (9.62 MiB)
  vs/editor/editor.main.css (289 KiB)
  vs/language/html/htmlMode.js (436 KiB)
  vs/language/html/htmlWorker.js (425 KiB)
  vs/language/css/cssMode.js (727 KiB)
  vs/language/css/cssWorker.js (718 KiB)
  vs/editor/editor.main.js (2.23 MiB)
  vs/editor/editor.main.js.gz (525 KiB)
  worker-ext.7156bc31776746887d21.js.map.gz (419 KiB)
  bundle.js.gz (2.02 MiB)
  bundle.js.map.gz (4.96 MiB)

WARNING in entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance.
Entrypoints:
  main (9.62 MiB)
      bundle.js

WARNING in webpack performance recommendations:
You can limit the size of your bundles by using import() or require.ensure to lazy load some parts of your application.
For more info visit https://webpack.js.org/guides/code-splitting/
Child worker:
                                     Asset      Size  Chunks                                Chunk Names
        worker-ext.7156bc31776746887d21.js   540 KiB       0  [emitted] [immutable]  [big]  main
    worker-ext.7156bc31776746887d21.js.map  1.83 MiB       0  [emitted] [dev]               main
    Entrypoint main = worker-ext.7156bc31776746887d21.js worker-ext.7156bc31776746887d21.js.map
     [18] (webpack)/buildin/global.js 472 bytes {0} [built]
    [176] (webpack)/buildin/module.js 497 bytes {0} [built]
        + 192 hidden modules

Done in 125.60s.
cades@kharazi-cades-dev:~/theia$ yarn theia start
yarn run v1.22.0
$ /home/cades/theia/node_modules/.bin/theia start
root INFO Configuring to accept webviews on '.+.webview..+' hostname.
root INFO Deploy plugins list took: 2.0 ms
root INFO Theia app listening on http://localhost:3000.
kittaakos commented 4 years ago

Nice, so you could build it 💪

still sitting there without opening up a browser still persists.

I am not sure if I understood it, but you have to open up the browser. 😊

If you open up localhost:3000 in the browser, what do you see? Do you see the spinning animation only? What is in the browser's console? Do you see an error there? If so, please share it with us. Thanks!

kharazit commented 4 years ago

From original post:

it will stay like the above indefinitely. When I attempt to open that in my browser @IPAddress:3000, I get a "unable to connect" error in firefox with all proxy settings set to "off". What is strange is that at one point in time I do recall it working properly and I was able to interact with the web gui. However, when I came back and tried the command again it wouldn't work.

However, you'll note that the output I showed you doesn't follow the same pattern as from the documentation. I don't see any:

starting server worker or server worker has been started etc... messages.

https://theia-ide.org/docs/composing_applications

kittaakos commented 4 years ago

I get a "unable to connect" error in firefox with all proxy settings set to "off".

Oh, I see. I am not sure if I can help with the proxy settings. You can try to run the backend with --hostname 0.0.0.0. Or ask on the Theia chat: https://spectrum.chat/theia

kharazit commented 4 years ago

I am accessing through ssh. I think having it connect to localhost would be preferred so I can connect to http://SSHIPADDRESS:3000

kittaakos commented 4 years ago

However, you'll note that the output I showed you doesn't follow the same pattern as from the documentation. I don't see any:

Yeah, it happens. Documentation gets outdated sooner than we expect: PRs are welcome ;)

kharazit commented 4 years ago

So is it working properly? I could make a PR if I knew what the correct output should be.

I was able to connect through the above address earlier (before the issue was ever opened), and I recall it having a different output before it signed in. However, I had to do a rebuild because the terminal wasn't working properly. Now I'm stuck with no ide.... The initial point of the post was to fix that issue

kittaakos commented 4 years ago

Did you set the ssl, cert, and certkey flags?

kharazit commented 4 years ago

No. I have no idea what those are. How do I do that? Is it in the documentation?

vince-fugnitto commented 4 years ago

No. I have no idea what those are. How do I do that? Is it in the documentation?

https://github.com/eclipse-theia/theia/blob/master/doc/Developing.md#run-the-browser-example-with-ssl

Additional Info

kharazit commented 4 years ago

No experience with ssl at all, what is cert, how do I generate cert key? Do I already have certkey, if so, where is it?

kittaakos commented 4 years ago

I cannot follow you.

What is strange is that at one point in time I do recall it working properly

I am accessing through ssh.

I can connect to https

Now I'm stuck with no ide.... The initial point of the post was to fix that issue

Please share what you have, so one can look into it maybe.

vince-fugnitto commented 4 years ago

No experience with ssl at all, what is cert, how do I generate cert key? Do I already have certkey, if so, where is it?

The question is not necessarily theia specific, so you might find better documentation regarding ssl, cert, certkey from additional sources for your given operating system. For example, I've used the following document (openSSL) in the past for my own https tests: https://www.digitalocean.com/community/tutorials/openssl-essentials-working-with-ssl-certificates-private-keys-and-csrs.

kharazit commented 4 years ago

That https should just be http, that was a typo, will fix above.

Okay. Here is the whole rundown of my experience trying to install your software:

First, I tried installing from source, but I couldn't get it to work, so I deleted everything and I built from a docker image. That worked decently, (I could access the IDE) however the terminal didn't work properly (it wouldn't update the current path, so I couldn't tell where I was without a pwd, and I couldn't access the entire directory). Furthermore, I was unable to save any files within the ide. I would hit cmd-s and it would do nothing. I would go through the file->save directory and that also did nothing making the install basically useless. So I thought I would try another build from source.

I was able to get it to work one time. I followed the instructions very closely and was able to get a viable working build. However, when I closed out of the window and tried to open it up again, I get the error I am currently sharing with you. After researching various issues, [https://github.com/eclipse-theia/theia/issues/5184, https://github.com/eclipse-theia/theia/issues/900] and another one which I can't seem to find. I tried various methods to get this to work, including decrementing to Node 8 and trying various versions of npm, nvm, and node.

Although I think Theia could be a very nice ide to use, it is frustrating to have to follow down what feels like infinite rabbit trails to get the ide to load, and work, consistently. As someone with zero javascript experience I have found the build process and documentation to be lacking. Now I am being asked to follow a rabbit trail down ssl, which from where I sit didn't seem like a necessary part of the build procedure.

vince-fugnitto commented 4 years ago

@kharazit to best help you we are trying to gather additional information.

First, I tried installing from source, but I couldn't get it to work.

Why didn't it work correctly for you?

I built from a docker image

We have example applications built using Docker if you require references/examples: https://github.com/theia-ide/theia-apps

Now I am being asked to follow a rabbit trail down ssl, which from where I sit didn't seem like a necessary part of the build procedure.

You mentioned attempting to run with https which requires the certificates so they were mentioned.

kharazit commented 4 years ago

I think I will just use VS code. I just installed it and it is working, thank you.