8000 Fix #1841 - Provide a better error when input is used by WebReflection · Pull Request #1857 · pyscript/pyscript · GitHub
[go: up one dir, main page]

Skip to content

Fix #1841 - Provide a better error when input is used #1857

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 14, 2023
Merged

Fix #1841 - Provide a better error when input is used #1857

merged 1 commit into from
Nov 14, 2023

Conversation

WebReflection
Copy link
Contributor

Description

This MR fixes #1841 by providing a better error when input is used on the main thread.

Changes

  • add a main codeBeforeRun hook that raises an error when no worker is used
  • smoke-test both pyodide and micropython
  • add an integration test to validate expectations (input is tested in workers too so it skips the worker test as it's pointless)

Checklist

  • All tests pass locally
  • I have updated CHANGELOG.md
  • I have created documentation for this(if applicable)

Copy link
Contributor
@antocuni antocuni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wonderful!

@WebReflection WebReflection merged commit 48e3383 into pyscript:main Nov 14, 2023
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.

input() should raise a clean error in the main thread
3 participants
0