MCPcopy Index your code
hub / github.com/plotly/dash / _validate

Function _validate

dash/_validate.py:430–444  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

428 component_ids = set()
429
430 def _validate(value):
431 def _validate_id(comp):
432 component_id = stringify_id(getattr(comp, "id", None))
433 if component_id and component_id in component_ids:
434 raise exceptions.DuplicateIdError(
435 f"""
436 Duplicate component id found in the initial layout: `{component_id}`
437 """
438 )
439 component_ids.add(component_id)
440
441 _validate_id(value)
442
443 for component in value._traverse(): # pylint: disable=protected-access
444 _validate_id(component)
445
446 if isinstance(layout_value, (list, tuple)):
447 for component in layout_value:

Callers 1

validate_layoutFunction · 0.85

Calls 2

_validate_idFunction · 0.85
_traverseMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…