dash.exceptions.IncorrectTypeException: The output argument `

When attempting to deploy an application, I get the dashTypeException error.

Callback function:


@app.callback([Output("modal","is_open"),
                       Output("Name","children"),
                       Output("Address","children")],

                       [Input("map-graph1","clickData"),
                        Input("close","n_clicks")],

                       [State("modal", "is_open")],
)
def display_popup(clickData, close, is_open):

    if clickData is None:

        return (dash.no_update)

    else:

        Tenant = clickData['points'][0]['customdata']['Tenant']
        Address = clickData['points'][0]['customdata']['Address']

        return(not is_open, Tenant, Address)

    if close:

        return is_open

Traceback:


  File "/app/.heroku/python/lib/python3.6/site-packages/gunicorn/util.py", line 350, in import_app
           __import__(module)
         File "/app/index.py", line 17, in <module>
           from tabs import reporting, portfolio, market, deal, revenue, comps, analysis
         File "/app/tabs/comps.py", line 615, in <module>
           [State("modal", "is_open")],
         File "/app/.heroku/python/lib/python3.6/site-packages/dash/dash.py", line 834, in callback
           self._validate_callback(output, inputs, state, events)
         File "/app/.heroku/python/lib/python3.6/site-packages/dash/dash.py", line 612, in _validate_callback
           name.lower(), str(arg), name
       dash.exceptions.IncorrectTypeException: The output argument `[<dash.dependencies.Output object at 0x7fc912424710>, <dash.dependencies.Output object at 0x7fc912424198>, <dash.dependencies.Output object at 0x7fc9124246d8>, <dash.dependencies.Output object at 0x7fc912424588>, <dash.dependencies.Output object at 0x7fc912424550>, <dash.dependencies.Output object at 0x7fc912424518>, <dash.dependencies.Output object at 0x7fc9124244a8>, <dash.dependencies.Output object at 0x7fc912424470>, <dash.dependencies.Output object at 0x7fc912424438>]` is not of type `dash.Output`.

You’re missing a closing bracket for your list of Ouput elements,

Output("Address","children"),

should be

Output("Address","children")],

It also looks like the number of outputs that you function is returning is wrong (it should match the number of Output element, i.e. 3 in your case).

Sorry, that was typo.

This works on localhost, however, throws an error when I’m deploying to heroku.

The number of outputs is fine, no issues on localhost.