File tree Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -155,8 +155,6 @@ def callback(
155
155
Function to call when the callback raises an exception. Receives the
156
156
exception object as first argument. The callback_context can be used
157
157
to access the original callback inputs, states and output.
158
- :param use_async:
159
- Tells the system to await for this async callback.
160
158
"""
161
159
162
160
long_spec = None
@@ -207,7 +205,6 @@ def callback(
207
205
manager = manager ,
208
206
running = running ,
209
207
on_error = on_error ,
210
- use_async = use_async
211
208
)
212
209
213
210
@@ -328,7 +325,6 @@ def register_callback(
328
325
manager = _kwargs .get ("manager" )
329
326
running = _kwargs .get ("running" )
330
327
on_error = _kwargs .get ("on_error" )
331
- use_async = _kwargs .get ("use_async" )
332
328
if running is not None :
333
329
if not isinstance (running [0 ], (list , tuple )):
334
330
running = [running ]
@@ -811,7 +807,7 @@ def add_context(*args, **kwargs):
811
807
812
808
return jsonResponse
813
809
814
- if use_async :
810
+ if asyncio . iscoroutinefunction ( func ) :
815
811
callback_map [callback_id ]["callback" ] = async_add_context
816
812
else :
817
813
callback_map [callback_id ]["callback" ] = add_context
Original file line number Diff line number Diff line change @@ -2356,8 +2356,7 @@ def router():
2356
2356
Output (_ID_CONTENT , "children" ),
2357
2357
Output (_ID_STORE , "data" ),
2358
2358
inputs = inputs ,
2359
- prevent_initial_call = True ,
2360
- use_async = True
2359
+ prevent_initial_call = True
2361
2360
)
2362
2361
async def update (pathname_ , search_ , ** states ):
2363
2362
"""
You can’t perform that action at this time.
0 commit comments