marimo-team / marimo

A reactive notebook for Python — run reproducible experiments, execute as a script, deploy as an app, and version with git.
https://marimo.io
Apache License 2.0
5.35k stars 156 forks source link

fix: Set stale status to false on cell transition to idle #1626

Closed wasimsandhu closed 2 weeks ago

wasimsandhu commented 2 weeks ago

📝 Summary

Fixes regression introduced by #1625.

🔍 Description of Changes

image

📋 Checklist

📜 Reviewers

@akshayka OR @mscolnick

vercel[bot] commented 2 weeks ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
marimo-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 17, 2024 5:26am
marimo-storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 17, 2024 5:26am
github-actions[bot] commented 2 weeks ago

🚀 Development release published. You may be able to view the changes at https://marimo.app?v=0.6.20-dev5

akshayka commented 2 weeks ago

@wasimsandhu one more issue:

I ran marimo tutorial dataflow. The following cells are stale on main but they shouldn't be stale:

image

mscolnick commented 2 weeks ago

@wasimsandhu - i think you may want to put unintialized later in the if/else statement, to take a later priority

akshayka commented 2 weeks ago

I think the issue is actually that lastExecutionTime is empty for errored cells -- cells with eg MultipleDefinitionErrors don't actually run. (cc @wasimsandhu)

Minimal repro:

import marimo

__generated_with = "0.6.19"
app = marimo.App()

@app.cell
def __():
    x = 0
    x
    return x,

@app.cell
def __():
    x = 1
    x
    return x,

if __name__ == "__main__":
    app.run()