Sonali
Sonali•6mo ago

can anyone please help me on this .. its

can anyone please help me on this .. its very urgent Thanks a lot in advance
8 Replies
Myles Scolnick
Myles Scolnick•6mo ago
you dont want to declare globals like global layout. youll want to split things up between multiple cells and use the reactivity to power updates. updates wont happen from within the same cell. check out marimo tutorial ui and marimo tutorial dataflow
Sonali
SonaliOP•6mo ago
So I simply need to split the code into different cells ?
Myles Scolnick
Myles Scolnick•6mo ago
and remove global
Sonali
SonaliOP•6mo ago
yes Thanks a lot will try and get back to you 🙂 It is not allowing me to split the above code can you help me which part I need to split can you share a sample code if you have
Myles Scolnick
Myles Scolnick•6mo ago
the tutorials are great examples
Sonali
SonaliOP•6mo ago
when I try to logically separate cells it is giving me below error : This cell wasn't run because it has errors This cell is in a cycle: cell-7 -> button_prev_day, button_prev_month, button_prev_week, button_prev_year -> cell-8 cell-8 -> bar_chart_component -> cell-6 cell-6 -> update_chart -> cell-4 cell-4 -> date_button -> cell-7 Tip: Merge these cells into a single cell
Sonali
SonaliOP•6mo ago
hi attached is the code with split cells I reolved the cycle issue but still bar chart is not getting updated. Please help @Myles Scolnick
Sonali
SonaliOP•6mo ago
Can you please help me on this