jupyter / atom-notebook

[Deprecated] Jupyter Notebook, but inside Atom.
MIT License
306 stars 48 forks source link

"Failed to load the jupyter-notebook package" on Atom 1.18 #67

Closed mkals closed 6 years ago

mkals commented 7 years ago

Hello,

I get this same error message, both when installing directly through GitHub as described here and when going through the plugin manager.

Is there a trick I could do to make it work? Any help would be greatly appreciated!

Atom: 1.18.0 x64 Electron: 1.3.15 OS: Mac OS X 10.12.6 Thrown From: jupyter-notebook package 0.0.10

Stack Trace

Failed to load the jupyter-notebook package

At /Users/mKals/.atom/packages/jupyter-notebook/lib/main.js: Unexpected token (36:4)

SyntaxError: /Users/mKals/.atom/packages/jupyter-notebook/lib/main.js: Unexpected token (36:4)
        return el;
      }
    });
  },

  deactivate() {
    at Parser.pp.raise (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/location.js:24:13)
    at Parser.pp.unexpected (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/util.js:82:8)
    at Parser.pp.expect (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/util.js:76:33)
    at Parser.pp.parseExprList (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:785:12)
    at Parser.pp.parseSubscripts (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:270:29)
    at Parser.pp.parseExprSubscripts (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:240:17)
    at Parser.pp.parseMaybeUnary (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:217:19)
    at Parser.pp.parseExprOps (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:163:19)
    at Parser.pp.parseMaybeConditional (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:145:19)
    at Parser.pp.parseMaybeAssign (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:112:19)
    at Parser.pp.parseExpression (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:79:19)
    at Parser.pp.parseStatement (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/statement.js:137:23)
    at Parser.parseStatement (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/flow.js:655:22)
    at Parser.pp.parseBlock (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/statement.js:442:21)
    at Parser.pp.parseFunctionBody (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:747:22)
    at Parser.parseFunctionBody (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/flow.js:643:20)
    at Parser.pp.parseMethod (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:717:8)
    at Parser.pp.parseObjPropValue (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:658:23)
    at Parser.parseObjPropValue (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/flow.js:891:13)
    at Parser.pp.parseObj (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:640:10)
    at Parser.pp.parseExprAtom (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:392:19)
    at Parser.parseExprAtom (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/jsx/index.js:412:22)
    at Parser.pp.parseExprSubscripts (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:236:19)
    at Parser.pp.parseMaybeUnary (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:217:19)
    at Parser.pp.parseExprOps (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:163:19)
    at Parser.pp.parseMaybeConditional (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:145:19)
    at Parser.pp.parseMaybeAssign (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/expression.js:112:19)
    at Parser.pp.parseExport (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/statement.js:682:21)
    at Parser.parseExport (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/flow.js:713:20)
    at Parser.pp.parseStatement (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/statement.js:115:90)
    at Parser.parseStatement (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/plugins/flow.js:655:22)
    at Parser.pp.parseTopLevel (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/statement.js:30:21)
    at Parser.parse (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/parser/index.js:70:17)
    at Object.parse (/Applications/Atom.app/Contents/Resources/app/node_modules/babylon/lib/index.js:45:50)
    at Object.exports.default (/Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/helpers/parse.js:36:18)
    at File.parse (/Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/transformation/file/index.js:574:40)
    at File.parseCode (/Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/transformation/file/index.js:691:20)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/transformation/pipeline.js:167:12
    at File.wrap (/Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/transformation/file/index.js:639:16)
    at Pipeline.transform (/Applications/Atom.app/Contents/Resources/app/node_modules/babel-core/lib/transformation/pipeline.js:165:17)
    at Object.exports.compile (/Applications/Atom.app/Contents/Resources/app/src/babel.js:70:22)
    at Object.compile (/Applications/Atom.app/Contents/Resources/app/src/package-transpilation-registry.js:79:33)
    at compileFileAtPath (/Applications/Atom.app/Contents/Resources/app/src/compile-cache.js:97:37)
    at Object.value [as .js] (/Applications/Atom.app/Contents/Resources/app/src/compile-cache.js:238:26)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.require (Applications/Atom.app/Contents/Resources/app/static/index.js:47:45)
    at require (internal/module.js:20:19)
    at customRequire (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:96:26)
    at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app/src/package.js:887:35)
    at /Applications/Atom.app/Contents/Resources/app/src/package.js:158:34
    at Package.module.exports.Package.measure (/Applications/Atom.app/Contents/Resources/app/src/package.js:99:21)
    at Package.module.exports.Package.load (/Applications/Atom.app/Contents/Resources/app/src/package.js:144:18)
    at PackageManager.module.exports.PackageManager.loadAvailablePackage (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:565:22)
    at PackageManager.module.exports.PackageManager.loadPackage (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:495:27)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/settings-view/lib/package-manager.js:521:35
    at exit (/Applications/Atom.app/Contents/Resources/app/node_modules/settings-view/lib/package-manager.js:128:22)
    at triggerExitCallback (/Applications/Atom.app/Contents/Resources/app/src/buffered-process.js:338:17)
    at /Applications/Atom.app/Contents/Resources/app/src/buffered-process.js:351:17
    at Socket.<anonymous> (/Applications/Atom.app/Contents/Resources/app/src/buffered-process.js:220:15)
    at emitOne (events.js:101:20)
    at Socket.emit (events.js:188:7)
    at Pipe._handle.close [as _onclose] (net.js:493:12)

Commands

     -2:04.7.0 settings-view:check-for-package-updates (atom-workspace.workspace.scrollbars-visible-when-scrolling.theme-xcode-theme.theme-atom-light-ui)
     -1:40.2.0 core:confirm (input.hidden-input)

Non-Core Packages

atom-beautify 0.30.3 
autocomplete-clang 0.11.3 
busy-signal 1.4.3 
cpp-generator 0.1.0 
ex-mode 0.15.0 
Hydrogen 1.18.0 
intentions 1.1.2 
jupyter-notebook 0.0.10 
linter 2.2.0 
linter-clang 4.1.1 
linter-ui-default 1.6.2 
markdown-preview-plus 2.4.9 
vim-mode-plus 0.93.0 
xcode-theme 1.4.0 
gautam1858 commented 7 years ago

Me too

nsalerni commented 7 years ago

Same here.

DostalJ commented 7 years ago

Me too

xingfanxia commented 7 years ago

same

nasyxx commented 7 years ago

same

louismartin commented 7 years ago

Up, same, me too

maricar-m commented 7 years ago

same

vlaskinvlad commented 7 years ago

+1

richtrf commented 7 years ago

+1

nicholasbutlin commented 7 years ago

+1

rafa2000 commented 7 years ago

+1

wikp commented 7 years ago

Bump

ghost commented 7 years ago

+1

alonsomoya commented 7 years ago

+1

DataUrbanEconGeek commented 7 years ago

+1

dalegebit commented 7 years ago

+2

dalegebit commented 7 years ago

Oh, simply remove the '}' at that line can get rid of the exception, but after doing so the layout gets really ugly

salehmoe commented 7 years ago

How to remove the '}'

maxhodak commented 6 years ago

Any update?

tdrobbin commented 6 years ago

+1

mallen5311 commented 6 years ago

+1

alisianoi commented 6 years ago

bumpy bump

valmormn commented 6 years ago

wtf?!?

rlbc commented 6 years ago

+1

adkinsty commented 6 years ago

+1

marskar commented 6 years ago

+1

moonbury commented 6 years ago

+1

anandharidass commented 6 years ago

+1

kibernick commented 6 years ago

+1

naveensr89 commented 6 years ago

+1

SumNeuron commented 6 years ago

When do they want to address this?

kingwyf87 commented 6 years ago

Please try to delete { in the main.js file as mentioned #68 You should be able to find this file here: /Users/USERNAME/.atom/packages/jupyter-notebook/lib This will fix this issue.

valmormn commented 6 years ago

Line 34 inside main.js at /home/$USER/.atom/packages/jupyter-notebook/lib

activate(state) {
    // console.log('Activated');
    fixPath();
    this.openerDisposable = atom.workspace.addOpener(openURI);
    this.commands = atom.commands.add('.notebook-cell atom-text-editor', 'jupyter-notebook-atom:run', this.run);
    atom.views.addViewProvider(NotebookEditor,
      model => {
        let el = document.createElement('div');
        el.classList.add('notebook-wrapper');
        let viewComponent = ReactDOM.render(<NotebookEditorView store={model} />, el);
        return el;
      }
    }); //  *** delete the right side curly brace at the beginning of line ***
  },

Check here: https://github.com/cloutiertyler/atom-notebook/commit/cf2ab0e66a8e7b470b7d88a03191bcaed477bf2a

Nic-Nic commented 6 years ago

+1

me1er commented 6 years ago

+1

alexBeuth commented 6 years ago

+1

AdrienMereghetti commented 6 years ago

+1

smoge commented 6 years ago

+1

rukmal commented 6 years ago

+1

dogaker commented 6 years ago

+1

benjavides commented 6 years ago

+1

RossKen commented 6 years ago

+1

KevinHu2014 commented 6 years ago

+1

matthewswallace commented 6 years ago

++1 ... that was such an easy fix. someone needs to issue a PR for this and get it merged already.

Lijia-Li commented 6 years ago

++

erdemalpkaya commented 6 years ago

The ugliest thing I saw after removing "}" from main.js. Sorry this is not a solution!

tandriamil commented 6 years ago

Now the error message is gone and so did the design of the notebook ... rip :cry:

wadekun commented 6 years ago

++

yoonoh930 commented 6 years ago

+1

burkesquires commented 6 years ago

+1