I have this exact use case.
I thought I could break the cycle by using raise PreventUpdate
when I can assert that the two inputs (box and slider) are synced with each other. However it looks like the rendered throws an error when it detects a cycle.
Perhaps a short term solution is to allow a way to explicitly disable the cycle checking (as in “trust me”, akin to supress_callback_exceptions
) ?
Update
I dived into dash-renderer, and it looks like the error for circular dependencies is thrown from createDFS from dependecy-graph. Fortunately, the more recent version of that library introduced a “circular” argument exactly to prevent that error from being thrown.
I forked dash-renderer to allow for this error to be disabled (diff here)
Happy to do a PR if this is something useful to others, although I’d probably need help with figuring out how to make the parameter configurable more upstream.