Comments (11)
Looks like atom detects bash as shell script, which is not how the kernel is named.
I think in cases like these the kernel should be selectable, but for some we should have a mapping structure lang->kernel_name.
from hydrogen.
Nope, he's got it covered with the mapping he specifies. The bash kernel
doesn't put its kernelspec in the normal location, so I'm trying to figure
out where it is.
On Thu, May 21, 2015 at 7:07 PM Kyle Kelley [email protected]
wrote:
Looks like atom detects bash as shell script, which is not how the kernel
is named.I think in cases like these the kernel should be selectable, but for some
we should have a mapping structure lang->kernel_name.—
Reply to this email directly or view it on GitHub
#17 (comment)
.
from hydrogen.
@fcrespo82 What platform are you on?
from hydrogen.
Oh, sorry, forgot to mention
OS X Yosemite 10.10.3 (14D136)
from hydrogen.
This is working for me on the same OS — does the Bash kernel work for you in ipython notebook
, and can you check in these directories to see if there's a bash/kernel.json
in any of them?
/usr/share/jupyter/kernels
/usr/local/share/jupyter/kernels
~/.ipython/kernels
from hydrogen.
Yes, it works on ipython notebook
And Yes, there is a bash/kernel.json
in /usr/local/share/jupyter/kernels
here is the kernel.json file.
from hydrogen.
Mine looks exactly the same, and I've just copy-pasted your mapping into my settings and it works fine.
Can you pop open the dev tools (View -> Developer -> Toggle developer tools) and then try running some Bash again? It should log out "Available kernels:" and then a list of kernels that it's found.
Also try running JSON.parse(atom.config.get('hydrogen.languageMappings'))
in the developer console and see that it gets the language mapping properly.
from hydrogen.
When I tried option+command+Return it shows:
Window load time: 1409ms
/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:92 SyntaxError: Unexpected token u {stack: (...), message: "Unexpected token u"}message: "Unexpected token u"stack: (...)get stack: function () { [native code] }set stack: function () { [native code] }__proto__: Error/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:92 module.exports.KernelManager.getLanguageMappings/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:76 module.exports.KernelManager.getTrueLanguage/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:34 (anonymous function)/Applications/Atom.app/Contents/Resources/app.asar/node_modules/babel-core/node_modules/lodash/inde…:1413 arrayMap/Applications/Atom.app/Contents/Resources/app.asar/node_modules/babel-core/node_modules/lodash/inde…:6662 map/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:32 module.exports.KernelManager.getAvailableKernels/Users/fernando/.atom/packages/Hydrogen/lib/autocomplete-provider.coffee:10 (anonymous function)/Users/fernando/.atom/packages/Hydrogen/lib/autocomplete-provider.coffee:57 (anonymous function)/Users/fernando/.atom/packages/Hydrogen/lib/autocomplete-provider.coffee:59 (anonymous function)module.js:452 Module._compile/Applications/Atom.app/Contents/Resources/app.asar/node_modules/coffee-cash/lib/coffee-cash.js:85 requireCoffeeScriptmodule.js:347 Module.loadmodule.js:302 Module._loadmodule.js:357 Module.requiremodule.js:376 require/Users/fernando/.atom/packages/Hydrogen/lib/main.coffee:20 (anonymous function)/Users/fernando/.atom/packages/Hydrogen/lib/main.coffee:337 (anonymous function)module.js:452 Module._compile/Applications/Atom.app/Contents/Resources/app.asar/node_modules/coffee-cash/lib/coffee-cash.js:85 requireCoffeeScriptmodule.js:347 Module.loadmodule.js:302 Module._loadmodule.js:357 Module.requiremodule.js:376 require/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:709 module.exports.Package.requireMainModule/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:255 module.exports.Package.activateConfig/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:234 module.exports.Package.activateNow/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:772 (anonymous function)/Applications/Atom.app/Contents/Resources/app.asar/node_modules/event-kit/lib/emitter.js:82 module.exports.Emitter.emit/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:219 module.exports.CommandRegistry.handleCommandEvent/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:3 (anonymous function)/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-keymap/lib/keymap-manager.js:519 module.exports.KeymapManager.dispatchCommandEvent/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-keymap/lib/keymap-manager.js:354 module.exports.KeymapManager.handleKeyboardEvent/Applications/Atom.app/Contents/Resources/app.asar/src/window-event-handler.js:178 module.exports.WindowEventHandler.onKeydown
/Users/fernando/.atom/packages/Hydrogen/lib/main.coffee:87 Updating current editor to: Object {softTabs: true, displayBuffer: Object, mini: undefined, placeholderText: undefined, handleMarkerCreated: function…}
/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:92 SyntaxError: Unexpected token u {stack: (...), message: "Unexpected token u"}
/Users/fernando/.atom/packages/Hydrogen/lib/main.coffee:66 making status bar
/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:92 SyntaxError: Unexpected token u {stack: (...), message: "Unexpected token u"}
/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:99 Available kernels: [Object, Object, unique: function]
/Users/fernando/.atom/packages/Hydrogen/lib/kernel-manager.coffee:92 SyntaxError: Unexpected token u {stack: (...), message: "Unexpected token u"}
And when I run JSON.parse(atom.config.get('hydrogen.languageMappings'))
I get:
(program):1 Uncaught SyntaxError: Unexpected token umessage: "Unexpected token u"stack: (...)get stack: function () { [native code] }set stack: function () { [native code] }arguments: nullcaller: nulllength: 1name: ""prototype: StackTraceSetter__proto__: function Empty() {}<function scope>__proto__: ErrorVM508:2 (anonymous function)VM450:847 InjectedScript._evaluateOnVM450:780 InjectedScript._evaluateAndWrapVM450:646 InjectedScript.evaluate
BUT, I think I got it (And it worked when I changed in the coffee file), when I run JSON.parse(atom.config.get('Hydrogen.languageMappings'))
with capital H, I get the expected output:
Object {Shell Script: "bash"}
from hydrogen.
Awesome, thanks for your debugging help. I had it installed via symlink (with a lowercase name) to my working directory, so I didn't see this.
Should be fixed now!
from hydrogen.
Thank you! Yes, its working now!
from hydrogen.
Awesome! Thanks for the help debugging!
from hydrogen.
Related Issues (20)
- hydrogen fails to install on Atom HOT 2
- fialedto activate
- npm WARN deprecated [email protected] HOT 2
- Failed to activate the Hydrogen package HOT 18
- [email protected] failed
- Interactive input in output area
- VSCode: port or alternative HOT 12
- Uncaught Error: Cannot find module 'lodash/debounce'Require stack:- $ATOM_HOME/packages\Hydroge... HOT 3
- Uncaught error: no native build was found for platforms HOT 4
- Please port to Vs Code or any other IDE HOT 1
- Uncaught Error: No native build was found for platform=darwin arch=x64 runtime=electron abi=85 uv... HOT 2
- TypeError when using hydrogen with pulsar HOT 4
- Hi, If the notebook in "not trusted" mode. Just click on it and make it trusted then save the file. It will work fine.
- SCRIPT WONT EXECUTE. HOT 1
- can't rebuild zeromq for pulsar
- Newly installed python modules cannot be found by hydrogen in pulsar
- [18:30] r p npm WARN deprecated [email protected]: this library is no longer supported [18:31] r p npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic [18:31] r p npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic
- deleted
- Is this going to be maintained? HOT 5
- Publish Hydrogen to Pulsar Package Repository HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hydrogen.