I am using st.data_editor so that the user can input data in the project. Point is, when I use ‘on_change’ to call a function ‘ABC’, that receives as input that same data, the function is called on the previous data, not on the ‘changed’ data.
If applicable, please provide the steps we should take to reproduce the error or specified behavior.
Expected behavior / Actual behavior
It was expected the the function ABC was run with the new st.session_state[‘demanda_sugerida_unica_edit’] value, but it’s running with the old value instead.
In other words, if my current value is X and I change it to Y, I need my function ABC to be ran with Y, not X.
So, the link you sent is basically the same problem I am facing and there is no solution on that.
Let’s say I my original value is A.
When I change it, it calls a function, which uses my value to do some calculation. The problem is, when I change my value from A to B, the function is ran with A.
When I change my value from B to C, then my function uses B.
If i change my value from A to B, i need my function to use the uptaded value, which is not happening.