Page MenuHomeSolus

Mailspring Error
Closed, ResolvedPublic

Description

After updating today getting this error

rjg@solus ~ $ mailspring
Streaming log data to /tmp/Mailspring-1350.log
{ Error: Cannot find module 'babel-preset-electron'

at Module._resolveFilename (module.js:470:15)
at Function.Module._resolveFilename (/usr/share/mailspring/resources/electron.asar/common/reset-search-paths.js:35:12)
at Function.resolve (internal/module.js:27:19)
at defaultOptions.presets.map.modulename (/usr/share/mailspring/resources/app.asar/src/compile-support/babel.js:21:11)
at Array.map (native)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/compile-support/babel.js:20:57)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/compile-support/babel.js:73:3)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/compile-cache.js:6:23)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/compile-cache.js:197:3)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at setupCompileCache (/usr/share/mailspring/resources/app.asar/src/browser/main.js:42:24)
at start (/usr/share/mailspring/resources/app.asar/src/browser/main.js:250:3)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/browser/main.js:280:1)
at Object.<anonymous> (/usr/share/mailspring/resources/app.asar/src/browser/main.js:282:3)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Object.<anonymous> (/usr/share/mailspring/resources/electron.asar/browser/init.js:171:8)
at Object.<anonymous> (/usr/share/mailspring/resources/electron.asar/browser/init.js:173:3)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.runMain (module.js:605:10)
at run (bootstrap_node.js:431:7)
at startup (bootstrap_node.js:155:9)
at bootstrap_node.js:551:3 code: 'MODULE_NOT_FOUND' } {}

TypeError: Cannot read property 'user' of undefined

at Raven.process (/usr/share/mailspring/resources/app.asar/node_modules/raven/lib/client.js:203:49)
at /usr/share/mailspring/resources/app.asar/node_modules/raven/lib/client.js:317:12
at /usr/share/mailspring/resources/app.asar/node_modules/raven/lib/parsers.js:52:5
at /usr/share/mailspring/resources/app.asar/node_modules/raven/lib/utils.js:245:5
at /usr/share/mailspring/resources/app.asar/node_modules/raven/lib/utils.js:160:35
at ELECTRON_ASAR.js:497:9
at FSReqWrap.wrapper [as oncomplete] (fs.js:629:17) {}

Raven: 429 - Creation of this event was denied due to rate limiting

Related Objects

Event Timeline

Unknown Object (User) created this task.Jan 14 2018, 12:11 AM
rodrum added a subscriber: rodrum.Jan 14 2018, 1:30 AM

I can confirm the same Cannot find module 'babel-preset-electron' error after the update.

JoshStrobl edited projects, added Software; removed Lacks Project.
JoshStrobl moved this task from Backlog to Package Fixes on the Software board.

You can install the old version via:

sudo eopkg install https://packages.solus-project.com/shannon/m/mailspring/mailspring-1.10.11-4-1-x86_64.eopkg

alecbcs changed the task status from Open to In Progress.Jan 14 2018, 6:47 AM

Hi everyone, it appears that the latest version of nodejs (8.9.4) fails to download some of the required assets for mailspring when running npm.

npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning EINTEGRITY: sha1-QFUCsAfzGcP0cXXER0UnMA8qta0= integrity checksum failed when using sha1: wanted sha1-QFUCsAfzGcP0cXXER0UnMA8qta0= but got sha512-zr6QQnzLt3Ja0t0XI8gws2kn7zV2p0l/D3kreNvS6hFZhVU5g+uY/30l42jbgt0XGcNBEmBDGJR71J692V92tA==. (260 bytes)
npm WARN registry Using stale package data from https://registry.npmjs.org/ due to a request error during revalidation.

I just rebuilt mailspring locally against nodejs (8.9.3) and the app opens without any problems. Is there anyway that for a short term fix mailspring can be built against 8.9.3 instead of 8.9.4? How would I specify that in the package.yml file? For a long term fix, I'll make sure to publish this issue upstream. Also has anybody else reported errors with nodejs and npm? (Is this affecting other builds?)

@alecbcs I'd suggest filing the issue with Mailspring then, since they're the upstream for the software itself (and I don't plan reverting nodejs).

You can install the old version via:
sudo eopkg install https://packages.solus-project.com/shannon/m/mailspring/mailspring-1.10.11-4-1-x86_64.eopkg

Hey! That works really well! How can I do this if something similar happens next time?

JoshStrobl triaged this task as High priority.Jan 20 2018, 6:59 AM
JoshStrobl added a project: Upstream Issue.
mclang added a subscriber: mclang.Jan 26 2018, 7:43 AM

Installing older version worked for me also.

I noticed though that there is mailspring 1.1.0 snap available. What are the drawbacks using snap package instead of native eopg package? Can both be installed at the same time and do they use same settings and email accounts?

There aren't necessarily any functionality drawbacks of using the snap. Currently, snaps don't yet support system themes which makes them often look very out of place. It's really just a personal decision. You are able to install both at the same time however, they won't use the same settings/accounts because a snap runs in a sandbox environment.

Any news on this front?

BTW, the 1.1.12 Snap exhibits the same symptoms.

The issue appears to occur because npm is unable to install a specific dependency (babel-preset-electron) from the author's git repository. I'm currently following the reported bug on github. Sorry for the long wait and thanks for your patience.

There are still errors when trying to build this application from source. However, I have submitted an update (D2334) using the pre-compiled .deb so that people can continue using mailspring while these upstream issues are worked out. Thanks everyone for your patience!

joebonrichie closed this task as Resolved.Feb 21 2018, 4:43 PM
joebonrichie added a subscriber: joebonrichie.

Resolved by D2334

when will version 1.1.14 be in the repo?

Unstable gets synced to stable every friday, so friday :D