plotly / plotly/dash

dict component id passed to clientside callbacks is object instead of string

Open
#1,461 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

bug dash-callbacks P3
Dominant language
Python
Stars
24.4k
Forks
2.3k
Avg merge
2d 7h
Merged PRs (30d)
13

Description

When passing an Input with the component_property being "id" and the component_id referring to a dict (instead of a string), the javascript function received an object (the id dict) and not the stringified/jsonified id. This makes it difficult to use.

See here https://community.plotly.com/t/clientside-callback-with-pattern-matching/45657/2 for the required workaround in javascript

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the clientside callback behavior described in the issue using an Input whose component_property is "id" and whose component_id is a dict, then trace where the callback arguments are serialized for JavaScript. Compare the result with the workaround in the linked community discussion; done means the callback receives the stringified or JSONified id without requiring that workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, python
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.