News for hackers. Stuff that matters.
Re:Show HN: Hydrogen Brings Light Table to Atom by ibdknox on Wednesday May 20, 2015 @03:20PM (#9578552)
This is very cool work. :) Great job Will!

When Atom was first launched I mentioned that it might make sense to port the interesting parts of LT over to it since the core editor isn't what's important (and it's also a ton of work to get right). LT has found its way into lots of projects, from the Chrome Dev Tools to XCode and IntelliJ, which is a tremendous honor for us - it's great to see it coming to Atom as well.

Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @03:58PM (#9578860)
Thanks for the support!

I've been thinking a lot about what makes for a good development experience, and how to properly "factorize" an IDE to provide a consistent experience across different languages. The monolithic IDE experience can be great (once you get it set up) if all your work is in a single language. But for people like me, having a confusingly different development environment for each project is a nightmare.

This is a tiny step toward the dream of having a consistent core editor but with powerful tools for each language that allow introspection into the state of the running machine.

Re:Show HN: Hydrogen Brings Light Table to Atom by wferrell on Wednesday May 20, 2015 @05:00PM (#9579274)
Will -- Nice work! Been hoping for something like this and an excuse to use Atom
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @05:14PM (#9579353)
Thanks Bill!

Atom has been improving really fast - it's my editor of choice now.

Re:Show HN: Hydrogen Brings Light Table to Atom by azeirah on Wednesday May 20, 2015 @06:45PM (#9579859)
"Nice work Will", "Thanks Bill"!
Re:Show HN: Hydrogen Brings Light Table to Atom by stuaxo on Thursday May 21, 2015 @02:57AM (#9581309)
This is great, I've been thinking in a similar about something like this for 'visual debugging', for a livecoding tool.

It would be great if this could recognise some common image formats in memory (cairo surfaces, PIL) and visualise those on mouseover.

Possibly similar for arrays - be able to visualise it as a wave or even playback as audio.

Is there any chance of factoring out the support for the popouts? - It would be great if this could appear in other editors.

Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Thursday May 21, 2015 @09:16AM (#9582473)
I'd love to do live variable inspection (like the Chrome Dev Tools) — it's something I'm thinking about for the future.

There's a (nascent) project called `jmp` (for Jupyter Messaging Protocol) that implements kernel communication in JS: https://github.com/n-riesco/jmp. I'll probably contribute to that and factor out my kernel communication.

Re:Show HN: Hydrogen Brings Light Table to Atom by lambdaops on Thursday May 21, 2015 @02:40PM (#9584584)
I'm starting up a way to do this with an Electron app (the base of Atom), called Jupyter side car. It's not ready yet, but will share some of the same components. All this is pretty exciting for the Jupyter project.
Re:Show HN: Hydrogen Brings Light Table to Atom by revenz on Wednesday May 20, 2015 @06:50PM (#9579888)
Can you expand on where I might find details on LT in intellij?
Re:Show HN: Hydrogen Brings Light Table to Atom by redtuesday on Thursday May 21, 2015 @05:32AM (#9581691)
Would be interested in this as well. I only know the "Scala Worksheet" which is similar: https://confluence.jetbrains.com/display/IntelliJIDEA/Workin... and apeared first in Scala-Ide.
Re:Show HN: Hydrogen Brings Light Table to Atom by lemming on Thursday May 21, 2015 @06:16PM (#9585697)
I think he's referring to the in-editor debug values in IntelliJ v14.
Re:Show HN: Hydrogen Brings Light Table to Atom by mattdeboard on Wednesday May 20, 2015 @06:18PM (#9579724)
I don't understand how people use Atom for Python. Indentation in language-python is broken.

https://github.com/atom/language-python/issues/64 https://github.com/atom/language-python/issues/22

There are also several syntax highlighting issues but those aren't deal-breakers like broken indentation.

I'm sympathetic, I help maintain elixir-mode for emacs. I know it's hard to get this stuff right. But all things considered, Atom is unusable for Python for me. I was using it for working with JS & React but now that web-mode seems to have ironed at many kinks, I'm back to Emacs.

Re:Show HN: Hydrogen Brings Light Table to Atom by seanp2k2 on Wednesday May 20, 2015 @09:42PM (#9580516)
Know off-hand if there is a fix for JS auto-indenting in the works? My atom seems to just indent everything one level more than the last, never out-denting back. This is something which I've found JetBrains IDEs to be really good at, but at this point Atom has so many useful / fun packages and is so easily extensible that I don't think I'll switch back any time soon.

If there's already a package (I know about FixMyJS which...sorta works...) which does this well, please share!

EDIT: rainbow parens would also be KILLER in Atom, but last time I looked it sounded like it was non-trivial to modify the colors like that.

Re:Show HN: Hydrogen Brings Light Table to Atom by chc on Wednesday May 20, 2015 @06:53PM (#9579899)
Python indentation in Emacs was awful for a long time too, wasn't it?
Re:Show HN: Hydrogen Brings Light Table to Atom by mattdeboard on Wednesday May 20, 2015 @07:04PM (#9579939)
Doesn't matter, it works now. This isn't a moral question about which project has had the fewest bugs in their respective lifetimes. It's a practical question about which mode gets auto-indentation right right now.

edit: I don't know the answer to your question. What I do know is that it's really hard to get indentation right in Emacs for languages with significant whitespace where new lines are the only marker, and I assume the same is true for TextMate (which Atom piggybacks on for indentation). I'm not an expert on emacs, emacs lisp or creating language modes for emacs, but I do have a decent amount of experience[1]. So when I say I'm sympathetic I mean it down in my bones.

But still, if an editor can't get auto-indentation right, it's a deal-breaker.

[1] https://github.com/elixir-lang/emacs-elixir/blob/master/elix...

Re:Show HN: Hydrogen Brings Light Table to Atom by chc on Wednesday May 20, 2015 @08:47PM (#9580358)
Oh, I didn't mean it as a moral question or smack-talk or anything like that. I was just noticing that Python seems to be neglected by a lot of editors. I'm normally an Emacs user, but I gave up on it for Python because I had to spend too much time fighting it on indentation, so I was kind of surprised to see it mentioned in your comment and it made me think.
Re:Show HN: Hydrogen Brings Light Table to Atom by mattdeboard on Thursday May 21, 2015 @07:23AM (#9581962)
No, python-mode works beautifully for me. There are a couple very minor hiccups (I think there's some error with indentation after a method with no `return` statement or some such) but it's not a deal breaker.
Re:Show HN: Hydrogen Brings Light Table to Atom by sherbondy on Wednesday May 20, 2015 @04:35PM (#9579106)
Congrats on the release, Will! This would make for a killer default env for MIT's 6.815 course (http://ocw.mit.edu/courses/media-arts-and-sciences/mas-531-c...) (presently taught in Python). Also, ahem, I believe it is now time to JUPYTER ALL THE REPLS.
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @04:59PM (#9579259)
I'm looking forward to that Elixir kernel!
Re:Show HN: Hydrogen Brings Light Table to Atom by lambdaops on Thursday May 21, 2015 @02:28PM (#9584516)
Yes please, Jupyter all the REPLs.
Re:Show HN: Hydrogen Brings Light Table to Atom by jscottmiller on Wednesday May 20, 2015 @04:20PM (#9579004)
Nice work. Question for anyone using light table or similar environments on a day-to-day basis: does this statement-by-statement eval and output scale to larger projects? It makes a nice demo for contained scripts, in particular those working with a concrete dataset (image, samples). I have trouble imagining what it is like for larger, more abstract stretches of code.
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @04:38PM (#9579121)
I like to break my code up into little functions that are easy to test, so that flow works well for me.

Even more powerful, though, is autocomplete from the running environment. It means that (just like in the Chrome Dev Tools) when you start typing something, the autocomplete suggestions include all of the valid names that are defined. It really helps in navigating complex APIs like Torch: https://www.dropbox.com/s/e6hriw5quwct65a/Screenshot%202015-...

Re:Show HN: Hydrogen Brings Light Table to Atom by CyberDildonics on Wednesday May 20, 2015 @07:21PM (#9580014)
Pretty awesome, this is something I had been thinking about since using light table and julia - live programming, visualization and bringing auto complete and live syntax checking to julia. Very cool! I think these methods if they work on a larger scale will ultimately be a better way to program.
Re:Show HN: Hydrogen Brings Light Table to Atom by nawitus on Wednesday May 20, 2015 @05:52PM (#9579573)
How powerful is autocomplete, when statically typed languages also provide it?
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @05:59PM (#9579609)
The development experience for statically typed languages is often _amazing_ compared to that of dynamically typed ones; we sometimes choose dynamically typed ones anyway because of the flexibility and speed of development they give. I'd be very happy with an environment that provided dynamically typed languages the same analysis, checking, completion, etc that statically typed languages take for granted.
Re:Show HN: Hydrogen Brings Light Table to Atom by espadrine on Thursday May 21, 2015 @07:12AM (#9581930)
> I'd be very happy with an environment that provided dynamically typed languages the same analysis, checking, completion

Thinks like tern.js[0] or my own Aulx[1] provide that with varying success. Visual Studio's JS autocompletion is also stellar. The techniques used could be applied (with tweaks) to most dynamic languages.

[0]: http://ternjs.net/doc/demo.html

[1]: http://espadrine.github.io/aulx/

Re:Show HN: Hydrogen Brings Light Table to Atom by seanmcdirmid on Thursday May 21, 2015 @02:24AM (#9581229)
I'm working a type system called type-less that is oriented in this direction; check out:

https://www.youtube.com/watch?v=II1PgYTPW_U

I need to do another video soon, the work has progressed a bit further since then.

Re:Show HN: Hydrogen Brings Light Table to Atom by rattray on Thursday May 21, 2015 @03:32AM (#9581408)
Relatedly, I would love to see - what is this like with Django?
Re:Show HN: Hydrogen Brings Light Table to Atom by jarpineh on Wednesday May 20, 2015 @04:51PM (#9579211)
Yes! I like this very much. This is the favorite feature I used in LT (though I've wished to delve more in its architecture), I never really got the hang of external REPLs and browser sessions.

I recently tested Wallaby.js, which brings LT approach to testing. Now I wonder if the logic in Hydrogen could be extended to call module's tests and bring results just like the evaluation messages come. I think both immediate coding and testing might make coding more intuitive and reliable.

Is there an Atom to Jypyter bridge or something? How does Hydgoren and Atom communicate with Jypyter kernel?

Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @04:58PM (#9579252)
Jupyter provides a spec for a ZeroMQ-based messaging API, which kernels in each language have implemented. Hydrogen acts as a client to those kernels the same way that the Jupyter frontend does, sending execution requests to the kernel and displaying responses.

I'd love to see live test results in Atom too! It would make it so much easier to be confident in your code's correctness.

Re:Show HN: Hydrogen Brings Light Table to Atom by jarpineh on Wednesday May 20, 2015 @05:33PM (#9579468)
Thank you. I managed to miss that when reading the first time. I'm currently learning testing with the TAP protocol [1], which might be simple enough to bring into Atom or Oxygen and also use in Jypyter languages. I know that Python and JavaScript supports it.

Just had another thought. Regular Jypyter kernel supports multiple connections. Have you tested connecting to Oxygen's Python kernel from Notebook or IPython session? I'm thinking that console + Atom is nicer environment for a coder than Notebook. Afterwards the session could then be saved as a Notebook.

Anyways, I must now find time to dig into this! I don't like to leave my editor just to look at code execute nor tests run, there is more than enough context switching in programming.

[1] http://en.wikipedia.org/wiki/Test_Anything_Protocol

Re:Show HN: Hydrogen Brings Light Table to Atom by lewisl9029 on Wednesday May 20, 2015 @06:01PM (#9579626)
I have a question for those who are either still using Light Table or have switched away from it:

I've been meaning to start a project in ClojureScript and was thinking of using Light Table as my editor. I vaguely recall seeing news about development of Light Table slowing down, but despite this, would you guys still recommend Light Table today for Clojure/ClojureScript development? In its current state, how does it compare to editors like Atom/Sublime and whatever other options that are out there for Clojure development?

Re:Show HN: Hydrogen Brings Light Table to Atom by mattdeboard on Wednesday May 20, 2015 @07:17PM (#9579994)
I would recommend Emacs or vim. I know for sure that both of these have really great development environments.
Re:Show HN: Hydrogen Brings Light Table to Atom by _halgari on Thursday May 21, 2015 @12:27AM (#9580948)
Support for ClojureScript recently got a lot better in Cursive Clojure. I recommend giving it a shot.
Re:Show HN: Hydrogen Brings Light Table to Atom by jinxedID on Wednesday May 20, 2015 @03:33PM (#9578656)
I wonder if they know their logo is also the Ionic logo?
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @03:36PM (#9578683)
Shit, really?

<Googles>

Huh. I just banged this out in ten minutes when I needed an icon for autocomplete. I'll change it.

Re:Show HN: Hydrogen Brings Light Table to Atom by gabeio on Wednesday May 20, 2015 @03:45PM (#9578749)
I feel like it's not/shouldn't be possible to copyright/trademark/etc an element/element's atomic structure unless it's man made.
Re:Show HN: Hydrogen Brings Light Table to Atom by joshuapants on Wednesday May 20, 2015 @04:12PM (#9578959)
Regardless of whether that's the case, it's probably best to avoid having a logo that looks very similar to another, if only to avoid confusion.

That said, the atomic structure isn't the concern but rather a specific artistic visualization of it which may be protected.

Re:Show HN: Hydrogen Brings Light Table to Atom by zyxley on Wednesday May 20, 2015 @04:26PM (#9579045)
But the copyright (if there is one in this case) isn't on the element, it's on the specific visual interpretation of it for branding purposes.
Re:Show HN: Hydrogen Brings Light Table to Atom by gabeio on Wednesday May 20, 2015 @06:09PM (#9579677)
I still feel like that's basically "copyrighting"/or otherwise the atomic structure of the element...
Re:Show HN: Hydrogen Brings Light Table to Atom by weego on Thursday May 21, 2015 @04:10AM (#9581518)
A filled circle with a ring round it that has an intersecting filled circle is not an accurate representation of how a hydrogen atom looks. It is an artistic simplification. There are any number of ways of interpreting it.
Re:Show HN: Hydrogen Brings Light Table to Atom by PetitPrince on Thursday May 21, 2015 @05:51AM (#9581737)
And also Dr. Manhattan from the Watchmen, slightly rotated.
Re:Show HN: Hydrogen Brings Light Table to Atom by bryanjos on Wednesday May 20, 2015 @03:32PM (#9578650)
That looks so cool! I'm not an Atom user anymore (jumped back to Sublime), but this is the kind of thing that makes me want to jump back again. Wondering if there is an equivalent for Sublime.
Re:Show HN: Hydrogen Brings Light Table to Atom by rattray on Thursday May 21, 2015 @03:36AM (#9581418)
SublimeCodeIntel doesn't do quite the same thing, but does at least provide intelligent code completion for languages including Python. I think it can be a bit buggy, though - and this actually has the autocompletes come from the kernel, which is clearly better.

In short, I'm in the same boat about wanting to jump back to Atom. Just want to wait on improved performance, which I hear is in the works.

Re:Show HN: Hydrogen Brings Light Table to Atom by dethstar on Wednesday May 20, 2015 @03:44PM (#9578747)
There's plugins for different languages e.g RubyEval
Re:Show HN: Hydrogen Brings Light Table to Atom by wldcordeiro on Wednesday May 20, 2015 @04:02PM (#9578891)
SublimeREPL exists as well and it does a great job for many languages.
Re:Show HN: Hydrogen Brings Light Table to Atom by dimino on Wednesday May 20, 2015 @05:49PM (#9579554)
As recently as today I thought IPython might be worth looking into -- I've heard too many good things about IPython to ignore it, but I didn't really know how to get started.

I guess I don't have that excuse any longer! My only concern is that my mind will have trouble adjusting to the evolving state of the "app" I'm working on -- it seems like values in lines above others change, which then change values at other places, not just below the code? Will take some getting used to.

Re:Show HN: Hydrogen Brings Light Table to Atom by ajtulloch on Thursday May 21, 2015 @01:31AM (#9581111)
Awesome - and very cool to see ITorch getting some love. Thanks very much @willwhitney.
Re:Show HN: Hydrogen Brings Light Table to Atom by philipn on Wednesday May 20, 2015 @04:46PM (#9579174)
For a vim version(ish) of this, be sure to check out vim-ipython: https://github.com/ivanov/vim-ipython
Re:Show HN: Hydrogen Brings Light Table to Atom by rando3826 on Thursday May 21, 2015 @12:26AM (#9580947)
I clicked the link and then my browser (firefox) froze. Thanks.
Re:Show HN: Hydrogen Brings Light Table to Atom by hysan on Thursday May 21, 2015 @01:12AM (#9581061)
If you're on the latest Firefox (38), then it has been insanely crashy. Even with the 38.0.1 update that supposedly fixed a crash bug, the browser still crashes on a lot of websites. I'm not sure why Mozilla felt the need to push a suboptimal version out, but it is making me think of leaving Firefox again (been very unstable for me the past few versions).
Re:Show HN: Hydrogen Brings Light Table to Atom by rando3826 on Thursday May 21, 2015 @12:31AM (#9580967)
And it repros.
Re:Show HN: Hydrogen Brings Light Table to Atom by bronson on Thursday May 21, 2015 @12:43AM (#9580998)
There is nothing questionable on that page. Check your browser.
Re:Show HN: Hydrogen Brings Light Table to Atom by Animats on Thursday May 21, 2015 @01:30AM (#9581106)
Happened to me twice. Someone please click the "hostile code" box on that page.
Re:Show HN: Hydrogen Brings Light Table to Atom by RangerScience on Wednesday May 20, 2015 @03:36PM (#9578685)
What's the state of using this with non-Python languages?
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @03:40PM (#9578714)
I'm actively using it with Julia and Torch. It should work with any Jupyter kernel (and there are lots: https://github.com/ipython/ipython/wiki/IPython-kernels-for-...).

In practice, different kernels have various oddities or holes in their implementation of the spec. I'm accommodating them when I can and posting issues when I can't. Let me know if you find a kernel that doesn't work!

Re:Show HN: Hydrogen Brings Light Table to Atom by bronson on Wednesday May 20, 2015 @05:14PM (#9579352)
Wow, that's a lot of languages!

How is the Ruby support? A Rails console in the file I'm writing sounds epic. No longer would I need to clumsily suck the interesting lines back out of irb history using copy/paste.

Looks active: https://github.com/SciRuby/iruby I'll have to try it.

Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @05:20PM (#9579398)
I haven't tried the Ruby kernel - let me know how it works, and post an issue if anything breaks!
Re:Show HN: Hydrogen Brings Light Table to Atom by bronson on Thursday May 21, 2015 @01:42AM (#9581144)
Pretty dismal for now. :( https://github.com/SciRuby/iruby/issues/1

It looks like they got it working with python2, then the switch to python3 broke everything.

Hopefully in a few months the python3 version will work better than the python2 version.

Re:Show HN: Hydrogen Brings Light Table to Atom by outworlder on Wednesday May 20, 2015 @04:04PM (#9578910)
I was thinking about the same thing yesterday! Glad to know it already exists.

My own Emacs feels... inadequate right know. But I guess something like this could be done for it too.

Re:Show HN: Hydrogen Brings Light Table to Atom by knicholes on Wednesday May 20, 2015 @05:52PM (#9579569)
While this is very cool, it seems like this type of development supplants TDD by running the intermediate results manually once and is forgotten.
Re:Show HN: Hydrogen Brings Light Table to Atom by saidajigumi on Wednesday May 20, 2015 @06:43PM (#9579846)
I find this a surprising reaction, just because for so many devs I've known, it's common to keep a "sketchpad" interpreter open to mess about with code ideas. And these are all dedicated TDD folks. Perhaps if the dev(s) in question don't really understand TDD, but I think that's a cultural problem rather than a tooling problem.

In my experience, "getting" TDD is about two main things. First, internalizing what to test & why to test. (Fortunately, we've got a lot of help these days on the "how to test" front.) Second, having that moment when having tests makes your life-as-developer easier, or perhaps just possible. (Re: "possible", I recently upgraded a mature, legacy Rails 2.3 app to Rails 4.2. My blessings upon the devs prior to me who saw fit to create a comprehensive and well-maintained test suite. Without that, there would have needed to be a "throw it away and start afresh" discussion. Perhaps even project cancellation.)

Re:Show HN: Hydrogen Brings Light Table to Atom by shepardrtc on Wednesday May 20, 2015 @03:33PM (#9578663)
Very cool is an understatement. I can't imagine the amount of work that is going on behind the scenes to orchestrate this.
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @03:47PM (#9578773)
Most of the credit goes to the Jupyter team and the people who have implemented the kernels for various languages. The Jupyter API spec is what has made this possible. I'm really looking forward to what can be done next (hint: https://github.com/jupyter/notebook/issues/99)
Re:Show HN: Hydrogen Brings Light Table to Atom by billwilliams on Wednesday May 20, 2015 @06:43PM (#9579851)
Thank you for bringing us the future.
Re:Show HN: Hydrogen Brings Light Table to Atom by spv on Thursday May 21, 2015 @05:30AM (#9581687)
This is cool but I am eagerly waiting for this though https://github.com/atom/atom/issues/307
Re:Show HN: Hydrogen Brings Light Table to Atom by billwilliams on Wednesday May 20, 2015 @06:44PM (#9579856)
Any easy way to run remote kernels?
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @06:51PM (#9579891)
Right now it only works with local kernels, but that's on the to do list for sure.
Re:Show HN: Hydrogen Brings Light Table to Atom by billwilliams on Wednesday May 20, 2015 @07:25PM (#9580034)
Awesome, great work. This is one of those situations where I wish massive bribes were part of the open source ethos.
Re:Show HN: Hydrogen Brings Light Table to Atom by willwhitney on Wednesday May 20, 2015 @07:44PM (#9580126)
:D

I mean, if you're offering...