Black Lives Matter. Please consider donating to Black Girls Code today.

Component_registration in self.callback_map Error

HI, so i keep getting this error " component_registration in self.callback_map[target_id][‘inputs’]: KeyError: ‘displaying-an-image.children’"

whenever i change the output property in my app.callback. for example:

i have this
[Input(‘interval_component’ ,‘n_intervals’)])

but if i change to this:
[Input(‘interval_component’ ,‘n_intervals’)])

ill get that error, with the previous ID name.

The error suggests that you don’t have an element with ID named displaying-an-image.
Most likely something is still looking up for a callback with that element ID. My guess is that you get this error since there is some JS left that access the _dash-dependencies endpoint to trigger a callback for this output. Maybe you should refresh? are you using debug? what else is changed?

1 Like

thanks for your reply.
i wrote a whole new program but with the same code but it still gives that error. i’ve also restarted pycharm and all the programs.
yes, i am using debug. nothing else is changed

In pycharm, double press on shift key and search for displaying-an-image. You should find the object that you construct with that id and rename it according to your new implementation.

1 Like

i figured out the cause. it was beacause the previous dash app with that ID was still running in the browser. So i had to close it and reload

1 Like

Good to hear. That qualifies my first comment :slight_smile:

1 Like

This comment proved to be very useful for me as I too was facing the same issue.