Chaotic/intransparent execution order: Marimo creates NEW Problems normal notebooks do not have #4598
Replies: 2 comments 1 reply
-
@Julian-J-S — this is interesting. Thank you for sharing in such detail. I don't have a solution off the top of my head, but perhaps there is something we can do; will think about it. |
Beta Was this translation helpful? Give feedback.
-
@akshayka you are welcome 😉 Though I love many things about marimo, I cannot use it for production because in my personal option the "flaw" with the execution order is too big and requires a fundamental change in the way developers write code. You already get the "problem" with the easiest use case of just loading data and printing a message: Separating the SAME CODE into two adjacent cells will result in "unexpected outcomes" if you are not familiar with marimo or do not pay precise attention. This gets worse when you get a little more going on: To solve this requires littering the code with marimo specific "stop-commands" which is very unergonomic and cumbersome: Thinking about this a lot and one of my findings is that usually developers expect the following when working with notebooks: Every cell has an implicit dependency on ALL cells ABOVETo be honest I think reproducibility in standard notebooks is a non-issue that is trivial to solve:
The same is not true for marimo because it will run but in unexpected ways/order which is very hard to predict/debug/solve. In my opinion marimo has A LOT going for it! So with my experience it appears that a top-down execution while still being reactive would be a great way to solve this (all from my perspective and use-cases) Thanks a lot for reading! Have a great day! Open for any discussion 🤓 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Let me preface this by saying that overall I really like marimo ❤️
However, having worked with it a lot but also normal Jupyter notebooks and lots of Databricks notebooks I actually have a rather big problem with order of execution which is supposed to be marimo's strength.
Marimo hat lots of benefits compared to standard notebooks which I will not bringt up here but focus on the "problem" I see.
Order of Execution Importance
When running any kind of notebook (DE/DS/DA/ML) in production for example on databricks having a clearly defined order (for the USER) is extremely important.
I want to look at a notebook/code and understand the order of execution.
When checking jobs from the past that were successful or failed I want to know in what order their ran.
Also a lot of times you do sanity checks and if they fail you want to stop execution of the notebook (e.g. in Databricks
dbutils.notebook.exit("value to high")
). Everything after/below should not run!Normal Notebook VS Marimo
Normal Notebook:
Example
Marimo
Example
My Wish: Top-To-Bottom mode (with reactivity)
I really wish marimo had a "top-to-bottom" mode that:
Beta Was this translation helpful? Give feedback.
All reactions