You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is the sister issue of #1761.
We currently have 14 tests marked as @skip_worker
The goal of this issue is to give a rough explanation, try to group them into categories and serve as a starting point for further discussion, and to decide which ones we want to absolutely fix before the final release, and which ones can wait.
I expect that some of them will be uncontroversial, others will require more discussion, so depending on the case we might want to open separate sub-issues for them.
Missing error messages
These are all cases in which we display a nice error banner when we run in the main thread, but not when running in a worker:
@skip_worker("NEXT: display(target=...) does not work")
deftest_tag_target_attribute(self):
self.pyscript_run(
"""
<script type="py" target="hello">
from pyscript import display
display('hello')
display("goodbye world", target="goodbye")
display('world')
</script>
<div id="hello"></div>
<div id="goodbye"></div>
"""
)
hello=self.page.locator("#hello")
asserthello.inner_text() =="hello\nworld"
goodbye=self.page.locator("#goodbye")
assertgoodbye.inner_text() =="goodbye world"
these are for a different case: display(..., target=x) works fine is x points to e.g. a div, but not if it points to a <script type="py"> tag. Note that this works in the main thread, not in the worker:
This comes from times we had a different core, so I think this should be closed, as current integration tests have different reasons about the why, while other tests via workers got implemented.
Uh oh!
There was an error while loading. Please reload this page.
This is the sister issue of #1761.
We currently have 14 tests marked as
@skip_worker
The goal of this issue is to give a rough explanation, try to group them into categories and serve as a starting point for further discussion, and to decide which ones we want to absolutely fix before the final release, and which ones can wait.
I expect that some of them will be uncontroversial, others will require more discussion, so depending on the case we might want to open separate sub-issues for them.
Missing error messages
These are all cases in which we display a nice error banner when we run in the main thread, but not when running in a worker:
pyscript/pyscript.core/tests/integration/test_01_basic.py
Lines 87 to 111 in c6aaacd
pyscript/pyscript.core/tests/integration/test_01_basic.py
Lines 281 to 294 in c6aaacd
pyscript/pyscript.core/tests/integration/test_when.py
Lines 152 to 178 in c6aaacd
problems related to
display()
when we are inside a worker,
display()
doesn't take into account thetarget
attribute of its surrounding tag:pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 75 to 93 in c6aaacd
these are for a different case:
display(..., target=x)
works fine isx
points to e.g. a div, but not if it points to a<script type="py">
tag. Note that this works in the main thread, not in the worker:pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 95 to 112 in c6aaacd
pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 114 to 136 in c6aaacd
pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 191 to 206 in c6aaacd
this is another case of
display(..., target=...)
not working:pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 441 to 464 in c6aaacd
misc
matplotlib-pyodide seems to have problems inside workers, we need to investigate:
pyscript/pyscript.core/tests/integration/test_02_display.py
Lines 356 to 385 in c6aaacd
this is a sub issue, worth its own discussion:
Should workers support py-* events? #1763
test_escaping_of_angle_brackets
has a very weird behavior:Fix escaping of <py-script> #1764
The text was updated successfully, but these errors were encountered: