Hi guys,
I wanted to create a dcc.Store component with an id of “type”:xyz and “index”:abc inside a callback. In this callback I also create e.g. a dropdown menue with the same index. However, I always get the dash error “A nonexistent object was used in an Output of a Dash callback…” for the callback that should fill this storage.
If I move the creation of the storage into the layout of the app, everything works fine. So what I am currently doing is creating a lot of storages in the layout and hope that I never dynamically create more indices than that
*[dcc.Store(id={“type”: “store”, “index”: i}, storage_type=“session”) for i in range(20)]
Do you guys have any idea how I could solve this problem?
Sadly I don’t get an min working example running. But at least I know now that it should work. I’ll keep trying it.
Essentially putting this into the layout works fine but creating this in a callback throws the error in the next callback.
dcc.Store(id={“type”: “store”, “index”: 0}, storage_type=“session”)