6 ms·
I really wish the Julia ecosystem would stop assuming that you always interact with your computer through the Julia REPL and started supporting proper command l
by nerdponx 6y ago
I really wish the Julia ecosystem would stop assuming that you always interact with your computer through the Julia REPL and started supporting proper command line interfaces. This is one of the big annoyances and mistakes of the R ecosystem, and I think it's unwise to carry that mistake over to Julia.
Also, big "ugh" to browser-based tooling. I want to browse webpages in my browser, I don't want to do my data science work there. We don't even have a good native client for Jupyter notebooks yet, let alone for this new Jupyter alternative that doesn't support the existing Jupyter kernel protocol.
Not only that, but Pluto also apparently has some obnoxious UX limitations that remind me of other less-than-usable wannabe-Jupyter-notebooks (e.g. Apache Zeppelin, Databricks): https://towardsdatascience.com/could-pluto-be-a-real-jupyter-replacement-6574bfb40cc6 https://towardsdatascience.com/could-pluto-be-a-real-jupyter...
In short: nice idea, but I'd rather see continued unification around Jupyter and a proper IDE that can at least emit and interact with Jupyter-compatible data.
On the other hand, the Jupyter notebook JSON format is bad for a variety of reasons (e.g. you need special tools for readable Git diffs) and I really wish we had all settled on R Markdown instead. But R has its own NIH tooling problem and nobody was ever going to adopt it because the R community itself (driven by RStudio) has little interest in sharing or interoperability with other languages.
</cynical-angry-rant>
- clarkevans 6y agoPluto notebooks are Julia scripts, usable at the command line. Edit: Pluto uses Julia's package manager; moreover, Manifest.toml can be used to pin all of your project's dependencies so the notebook is repeatable, from a code perspective.
- nerdponx 6y agoThat's good to know. But I was talking about the package manager and starting the Pluto server.
- newswasboring 6y agoYou can start pluto server from command line > julia -e "using Pluto; Pluto.run()" Also, package manager can be used from inside Pluto. To install somethin, you can just write in a cell > using Pkg > Pkg.add("Package Name")
- dash2 6y agoBig ugh to browser based tooling, and yet also continued unification around Jupyter? Are there any plans to have a non-browser Jupyter?
- kylebarron 6y agonbterm [0] was recently released. You can also use Jupyter as a command line interface through Jupyter Console. [0]: https://blog.jupyter.org/nbterm-jupyter-notebooks-in-the-terminal-6a2b55d08b70 https://blog.jupyter.org/nbterm-jupyter-notebooks-in-the-ter...
- nerdponx 6y agoIt's "ugh" in the Jupyter world too. A good quality standalone "notebook editor" would be an incredible tool. Nteract exists, but is not "good".
- Iwan-Zotow 6y ago> Are there any plans to have a non-browser Jupyter? Sure. VSCode with python and Jupyter extensions
- TechBro8615 6y agoI tried this for the first time the other day and it was a great experience. Ironically the most cumbersome part continues to be Python environment management. I'll spare you my usual rant about that, but hopefully by Python 4 they'll find a solution.
- gugagore 6y agoWhat difference does this make, though? Isn't VSCode an Electron app? All of its UI is based on web stuff, anyway!
- BlueTemplar 6y agoI assume that at least the browser shortcuts are out of the way ?
- 6y ago
- thenoblesunfish 6y agoIs Julia different from Python in this regard? I use Python mostly by executing scripts, but it’s nice to have the REPL and IPython and Jupyter. With Julia I’m free to just run “julia script.jl”, aren’t I? There’s probably more to your complaint than I naively realize, though. Maybe Python has better IDE support?
- nerdponx 6y agoPython has a decent command line argument parser in its standard library, and there are several even-better options in the 3rd party library ecosystem, e.g. https://pypi.org/project/click/ https://pypi.org/project/click/.
- adgjlsfhk1 6y agoJulia has ArgParse.jl for 3rd party argument parsing. It seems pretty fully featured.
- nerdponx 6y agoGood to know, thank you.
- JustFinishedBSG 6y ago> I really wish the Julia ecosystem would stop assuming that you always interact with your computer through the Julia REPL and started supporting proper command line interfaces. What does it even mean? What is a CLI interface for a programming language if not a REPL ?
- krastanov 6y agoI also do not really get the complaint, but it is along the lines of people wanting to write `julia-pkg install Pluto` instead of `julia -e 'using Pkg; Pkg.add("Pluto")'`. It seems it is a big pet peeve for some people.
- spekcular 6y agoYes. I agree with this complaint. The REPL is useful in some cases but in general I avoid interacting with it whenever possible. My impression is that workflow is highly task-dependent (perhaps obvious) but there are many of us who just want to write a script, run the script, and repeat.
- nerdponx 6y agoThe `-e` thing gets very messy quickly if you need to pass non-trivial data from the outside world into the application (have you ever tried to "parameterize" a Sed script?). It also doesn't compose well with other CLI tools. I think these are two perfectly reasonable things to be annoyed by.
- deleted 6y ago[deleted]
- chillfox 6y agoThanks for the example. As someone who has never used Julia... Wow, that looks exceptionally painful compared to most other modern languages.
- krastanov 6y ago
- lacker 6y agoTo me this seems like an improvement in the direction that you want, in particular that notebooks are reactive. All too often I get a Jupyter notebook from someone else and try to run it on my machine only to find that some intermediate step does not work any more, because the original developer ran something out of order or removed a critical step. A reactive notebook seems more likely to still work after a lot of changes are made while experimenting.
- leephillips 6y agoNot just more likely, it will work. Pluto notebooks are deterministic, and do not have the hidden global state that plagues Jupyter.
- pdeffebach 6y agoPlenty of people use the REPL in terminal and sublime text or vim or whatever. I also dislike browser-based tooling and think Julia has done a good job avoiding Rstudio-style dependencies. But if your point is the inability to do `julia script.jl` , yeah thats a pain point. Fortunately there has been some tooling to make running many jobs in a row easier: https://github.com/dmolina/DaemonMode.jl https://github.com/dmolina/DaemonMode.jl
- nerdponx 6y agoRight. I was also a bit harsh; you can at least do `julia -e 'using Pluto' -e 'Pluto.run()'`.
- leephillips 6y agoHow is it that I do `julia script.jl` all the time? Or by “inability” do you mean that it’s slow because of the startup time? If you need a utility that starts up instantly, create a sysimage.
- snicker7 6y agoIn contrast to interpreted languages, creating a sysimage is yet another step (in addition to installing a third party package). In contrast to AOT-compiled languages, PackageCompiler.jl doesn't statically analyze your code. So you need a "precompile script" that hopefully hits all callable methods (such a script will have to be made manually). The resulting "binary" is also massive.
- pdeffebach 6y agoYeah people in python are used to doing `python script.py` all the time, and that's not very convenient in julia. sysimages are great, as is daemonmode. But really just do Revise at the REPL.
- Bootvis 6y agoWhat do you mean by “RStudio-style dependencies”?
- extr 6y agoConfession: after doing Data Science work for the past 4 years I STILL don't really understand why people like Jupyter. R was my first programming language and I got really spoiled with RStudio where everything "just works" and the "highlight code -> run in REPL" workflow is super smooth and tightly integrated. All I want is for that to work in other languages, but it seems like if you want it in Python you need to be running PyCharm or a similarly-heavyweight IDE (seriously, despite all the hype of VSCode there are still a ton of issues with just highlighting code and running it in an IPython terminal) and for Julia it just doesn't exist. If you really want a Jupyter-like workflow you can just use R Notebooks, which are literally just better in every way.
- nerdponx 6y agoSpyder is basically an RStudio clone for Python, but I never had a great experience using it. Not really sure why, somehow I just ended up using Jupyter because that's what my coworkers all used. When doing "solo" stuff, it doesn't matter because I dislike every interface so I'm never happy anyway...
- KMag 6y ago> I dislike every interface so I'm never happy anyway... It sounds like you might have some good constructive criticism after trying several options. Care to elaborate on the shortcomings of various options?
- oivey 6y agoThat workflow has worked for me for Julia in Spacemacs and VS Code. Pretty sure it works in Atom, too.
- hervature 6y agoWell, R isn’t the best language when it comes to building systems. Most R code is essentially one file written to produce an output once (for a paper, project, etc.). This means that people want a better language to build systems which Python fit. That explains why people moved to Jupiter. I don’t like RStudio for the same reason I don’t like Matlab. I already have my editor and terminal workflow. I don’t want to use/learn a new tool for the privilege to use the language. Notebooks hit an acceptable middle ground where I can launch them via terminal. Notebooks have plenty of problems. Mainly, running cells out of order is just an incredibly dumb thing to be possible. This same problem is present in RStudio which you seem to enjoy (highlight and REPL) and you want it in other languages. If the code isn’t written to run in an order, a tool shouldn’t allow it.
- kkylin 6y agoThis preference seems to depend a lot on where you come from. Having come from Scheme / Lisp (same as some of the original Julia developers AFAIK), I find I prefer the REPL in Emacs for coding. I do use Jupyter quite a bit for running simulations, doing data analysis, etc. For me, the main reason to use Jupyter has been (i) interacting with sessions on remote machines without needing to bother with X, and (ii) being able to easily incorporate LaTeX and share whole documents (math + working code) to collaborators and students.
- kkylin 6y agoPS I have tried Pluto and find that I don't like it very much in its current form, though I kind of like the idea.
- cwyers 6y agoHow does RStudio have little interest in interoperability with other languages? They produce the reticulate package[1] to allow calling Python code for R, they have added support for Python to RMarkdown and RStudio[2], they let you host Python apps on their RStudio Connect product[3], they sponsor Ursa Labs to work on the Arrow project for easy data interchange[4]. 1) https://rstudio.github.io/reticulate/ https://rstudio.github.io/reticulate/ 2) https://solutions.rstudio.com/python/ https://solutions.rstudio.com/python/ 3) https://blog.rstudio.com/2020/12/16/rstudio-connect-1-8-6-python-update/ https://blog.rstudio.com/2020/12/16/rstudio-connect-1-8-6-py... 4) https://ursalabs.org/ https://ursalabs.org/
- nerdponx 6y agoThen things are a lot better now than they were when I was using it actively, and I take back that criticism.
- disgruntledphd2 6y agoYou're not wrong in the substance of your rant though, but unfortunately it does appear that the ship has sailed and we're stuck with jupyter. I really need to get a handle on ein, for when I'm inevitably dumped back into a notebook-driven environment (hard to avoid in DS these days).
- tambarskjelve 6y ago> Also, big "ugh" to browser-based tooling. Hear hear! A simple web-view inside a native application window is a huge improvement imho. If only JuptyerLab provided a simple interface to access menu elements as well, you could easily have a nearly complete native experience.
- alpaca128 6y agoI wish there was a plain text format as base that everyone agreed on no matter what UI or backend is used; that would suddenly make it usable in any text editor and people could build tools and plugins that "just work" no matter whether Jupyter or something else is used. The closest we got was the org-mode file format with human-readable data for everything, but it seems tightly coupled with Emacs unless you only want to use it as Markdown replacement.
- kgwgk 6y agoRmarkdown is also human-readable. https://bookdown.org/yihui/rmarkdown/language-engines.html https://bookdown.org/yihui/rmarkdown/language-engines.html
- disgruntledphd2 6y agoBut is tied to R, which maybe isn't the right approach. Personally I love org mode, but we'd need a jupyter plugin to convert ipynb to org and back to make it work.
- RocketSyntax 6y agoHard disagree.