News for hackers. Stuff that matters.
Re:JupyterCon: I don't like Notebooks [slides] by FridgeSeal on Tuesday August 28, 2018 @04:21AM (#17857329)
I seriously cannot agree more.

Jupyter notebooks were fun to use for a bit, then I hit the inevitable wall of "ok, now let's turn this into a real, properly built script, but now everything is breaking for inexplicable reasons".

Notebooks are fine for early stage experimenting, but if you've got to the point where you start up you are relying on a notebook for anything, or your workflow consists of "start up notebook, run cells until I get to the one I'm working on" then you need to stop, and build it into something proper.

Experimentation is fine, but it should not come at the cost of writing things properly when the time comes, and they are not an excuse for not knowing some good software engineering. Serious alarm bells go off in my head when I read tweets like "Data science code doesn't need to follow the rules of good software engineering".

Edit: that remote notebook - is that honestly not one of the most terrifying things you've seen? That runs so counter to almost every good bit of software design and engineering practice about clarity, maintainability, good practice, security, etc that I can think of. It's the very definition of indecipherable, inscrutable hidden state and unknown side effects.

Re:JupyterCon: I don't like Notebooks [slides] by daveguy on Tuesday August 28, 2018 @08:59AM (#17858441)
I don't even like it for initial experimentation and exploration. Much prefer the command line repl (the jupyter/ipython one). Faster feedback and easier navigation then you can just export the history when you're ready to capture and make permanent some workflow. It still requires going through and picking out the important bits, but reading the history like a story of commands is generally enough to pick out the important parts.

The only thing I would use notebooks for is demonstration / teaching.

Re:JupyterCon: I don't like Notebooks [slides] by cdancette on Tuesday August 28, 2018 @10:08AM (#17858857)
If you work with image processing, notebooks are very handy as they can display images directly. Also to display tables nicely with pandas, or for any data visualization actually.
Re:JupyterCon: I don't like Notebooks [slides] by bunderbunder on Tuesday August 28, 2018 @10:33AM (#17859041)
That's my problem. I agree that notebooks create a troublesome dev situation, but "%matplotlib inline" and stuff like the pivot table plugin keep me crawling back.
Re:JupyterCon: I don't like Notebooks [slides] by srean on Tuesday August 28, 2018 @12:28PM (#17860171)
Doesn't IPython repl running in a QTconsole terminal do that ?
Re:JupyterCon: I don't like Notebooks [slides] by cdancette on Thursday August 30, 2018 @07:22PM (#17881697)
Yeah but it's less nice, and if you're running on a distant server you have to deal with X forwarding
Re:JupyterCon: I don't like Notebooks [slides] by kovek on Tuesday August 28, 2018 @10:40AM (#17859102)
Will the REPL allow you to easily edit function definitions and then reinterpret them?
Re:JupyterCon: I don't like Notebooks [slides] by rspeer on Tuesday August 28, 2018 @11:08AM (#17859357)
I mean Jupyter doesn't really do that either, right? You can't edit most function definitions. Only ones that you've defined right there in the notebook, and only because you can run the cell that defines them again, overwriting the function.

But if you do use libraries instead of just a huge mess of notebooks, you're stuck if you want to change the code in a well-supported way. You can ask your notebook to monkey-patch the code (which is an even bigger mess), or you can use an unreliable magic extension, "%autoreload".

Re:JupyterCon: I don't like Notebooks [slides] by sstanie on Tuesday August 28, 2018 @04:52PM (#17862775)
Yep, in the ipython REPL if you do

  %load_ext autoreload
  autoreload 2
it'll reload functions from any module you edit each time you run a new command.
Re:JupyterCon: I don't like Notebooks [slides] by Dowwie on Tuesday August 28, 2018 @02:09PM (#17861236)
One-off "experiments" become production technology all the time. They address an immediate need at the cost of tomorrow. This hasn't ever changed. Hyperbolic discounting is real.

When you're in a job that requires running experiments, analyzing results, and summarizing findings, all within an hour, shortcuts are required.

I think that analysts/scientists using python and Jupyter notebooks are doing IT a favor. If your job is to refactor/re-engineer python notebooks and corresponding workflows, you've either forgotten how much worse it could be with excel+vba or you fortunately arrived after trench warfare.

Re:JupyterCon: I don't like Notebooks [slides] by commandlinefan on Tuesday August 28, 2018 @10:08AM (#17858861)
Wow, I thought I was the only one. I guess the biggest lesson I've ever learned from the internet is that I'm never the only one.
Re:JupyterCon: I don't like Notebooks [slides] by megamindbrian2 on Tuesday August 28, 2018 @08:17AM (#17858188)
I wrote a loader for this. And there are tools to split cells for compiling. I wrote a tool to split up cells too and compile in order. Pretty easy, all the code is in notebooks.
Re:JupyterCon: I don't like Notebooks [slides] by megamindbrian2 on Tuesday August 28, 2018 @02:42PM (#17861601)
A few quick searches, maybe something along these lines? https://jupyter-notebook.readthedocs.io/en/stable/examples/N...

My JavaScript version I just put a simple wrapper around my print-results call to check if it is in module mode or notebook mode.