Skip to content

Declare asynchronous executor - #449

Merged
philippjfr merged 1 commit into
masterfrom
async_executor
Dec 21, 2020
Merged

philippjfr merged 1 commit into
masterfrom
async_executor

Conversation

@philippjfr

Copy link
Copy Markdown
Member

Allows declaring an asynchronous executor on param.parameterized.async_executor which allows using async functions (i.e. coroutines) as .param.watch callbacks and will schedule them on the event loop (Tornado or asyncio). As an example, Panel will register these executors depending on whether it is running on Bokeh server or the notebook:

Notebook

param.parameterized.async_executor = IOLoop.current().add_callback

Server

param.parameterized.async_executor = pn.state.curdoc.add_next_tick_callback

@philippjfr
philippjfr merged commit 3b005b1 into master Dec 21, 2020
@jbednar
jbednar deleted the async_executor branch December 21, 2020 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants