Skip to content

Callbacks with no output and pattern MATCH not allowing dash to run #2944

Closed as duplicate

Description

@micmizer

Using a callback with no output in Dash 2.17.1 and using a MATCH pattern on the input from a data table prevents dash from loading.

Describe your context
Create a simple single file app with a data table and a pattern matching callback with no output.

This works:

@callback(
    Input({'type': 'data-table', 'index': ALL}, 'active_cell'),
    State('url', 'pathname'),
)
def print_table_id_and_column(active_cell, pathname):
    print("hello")

This however causes the app to not load at all. The only indication of an issue is in the browser console. screenshot provided below:

@callback(
    Input({'type': 'data-table', 'index': MATCH}, 'active_cell'),
    State('url', 'pathname'),
)
def print_table_id_and_column(active_cell, pathname):
    print("hello")

Environment:

pip list | grep dash
dash                      2.17.1
dash-bootstrap-components 1.5.0
dash-bootstrap-templates  1.1.2
dash-core-components      2.0.0
dash-extensions           1.0.14
dash-html-components      2.0.0
dash-iconify              0.1.2
dash_mantine_components   0.14.4
dash-table                5.0.0

Describe the bug

Uncaught error TypeError: Cannot read properties of undefined (reading 'id') prevents dash from running.

Expected behavior

I expect that using a callback with no output works with both ALL and MATCH pattern matching.

Screenshots

image

Activity

  1. changed the title [-][BUG] Callbacks with no output and pattern MATCH not allowing dash to run[/-] [+]Callbacks with no output and pattern MATCH not allowing dash to run[/+] on Aug 13, 2024
  2. aGitForEveryone commented on Aug 30, 2024

    @aGitForEveryone
    Contributor

    This is the same issue as in #2462. Dash requires that if you use MATCH in the input, it should also appear in the output. The referenced issue also requested this restriction to be removed now that we can have callbacks with duplicate outputs. No idea, where on the roadmap this issue is.

  3. BSd3v commented on Aug 19, 2025

    @BSd3v
    Contributor

    Been running into this issue as well

  4. AnnMarieW commented on Nov 25, 2025

    @AnnMarieW
    Collaborator

    Closing as a duplicate of #2462. It's best to consolidate into one issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3backlogbugsomething broken

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions