diff --git a/packages/kernel/py/stlite-lib/stlite_lib/codemod.py b/packages/kernel/py/stlite-lib/stlite_lib/codemod.py index 68d154dac..ee039c847 100644 --- a/packages/kernel/py/stlite-lib/stlite_lib/codemod.py +++ b/packages/kernel/py/stlite-lib/stlite_lib/codemod.py @@ -911,6 +911,7 @@ def patch(code: str | ast.Module, script_path: str) -> ast.Module: wildcard_import_monitor_targets = set( [ WildcardImportTarget(module="time", attr="sleep"), + WildcardImportTarget(module="streamlit", attr="write"), WildcardImportTarget(module="streamlit", attr="write_stream"), WildcardImportTarget(module="asyncio", attr="run"), ] @@ -924,6 +925,7 @@ def patch(code: str | ast.Module, script_path: str) -> ast.Module: func_call_handler = FuncCallTransformHandler( { FunctionCall(name="time.sleep"): TransformRuleAction.TIME_SLEEP, + FunctionCall(name="streamlit.write"): TransformRuleAction.AWAIT_CALL, FunctionCall(name="streamlit.write_stream"): TransformRuleAction.AWAIT_CALL, AttrFunctionCall( obj=ReturnValue(called_function="streamlit.navigation"), diff --git a/streamlit b/streamlit index 4dfc2e692..61b7eb578 160000 --- a/streamlit +++ b/streamlit @@ -1 +1 @@ -Subproject commit 4dfc2e692d3126dec566e46babdd360d2d4c1bdb +Subproject commit 61b7eb578df81310c421b8ebc8985424dcf4b79d