News for hackers. Stuff that matters.
Re:REPL Driven Design by snicker7 on Thursday May 28, 2020 @01:09PM (#23339756)
This is sort of like how I develop using Jupyter notebooks. Write code in the notebook until I get a function / component correct. Copy it into a module. Restart the kernel and import the module. Rinse and repeat.
Re:REPL Driven Design by nerdponx on Thursday May 28, 2020 @01:16PM (#23339853)
Yup, a notebook is a REPL with better scrollback + the ability to take notes alongside your code.
Re:REPL Driven Design by smabie on Thursday May 28, 2020 @03:25PM (#23341351)
Except unlike a REPL, all your code is still there so that you eventually find yourself in an unreproducible state that on the surface looks reproducible. Referencing variables that don't exist in the notebook (only to be caught when run by someone else), cells that need to be executed out of order, etc. The problems go on and on. People sometimes go days or weeks without restarting their notebook and the amount of "shadow" state is remarkable.

I think notebooks are useful (though only for exploratory analysis), but there has to be a better way.

Re:REPL Driven Design by EForEndeavour on Thursday May 28, 2020 @04:23PM (#23342118)
Part of the problem is discipline and avoiding anti-patterns. It's unfortunate that Jupyter encourages this kind of inconsistency to creep in, leaving it up to the analyst to maintain top-to-bottom "runnability".
Re:REPL Driven Design by nerdponx on Saturday May 30, 2020 @02:11AM (#23358926)
You can go for days and weeks without restarting your REPL. It's literally the same problem.