Skip to content
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

BUGFIX: If python2js_buffer fails, python2js leaves the error flag in an invalid state #1111

Merged
merged 10 commits into from
Jan 12, 2021

Conversation

hoodmane
Copy link
Member

@hoodmane hoodmane commented Jan 11, 2021

I fixed #1110. If python2js_buffer fails, we need to clear the Python error flag before trying a backup approach.

@hoodmane hoodmane changed the title Fix #1110 BUGFIX: If python2js_buffer fails, python2js leaves the error flag in an invalid state Jan 11, 2021
@dalcde
Copy link
Contributor

dalcde commented Jan 11, 2021 via email

@hoodmane
Copy link
Member Author

I don't know, will investigate. I'm going to update conftest so that it checks whether PyErr_Occurred() at the end of every test too, that would have caught this bug.

@hoodmane
Copy link
Member Author

I think we should also try converting the numpy tests from selenium_standalone to selenium. I am suspicious that the reason they were changed to selenium_standalone in the first place may have been because of this bug.

@dalcde
Copy link
Contributor

dalcde commented Jan 11, 2021 via email

@hoodmane
Copy link
Member Author

hoodmane commented Jan 11, 2021

Original bug reproduction involved the code in console.html in a weird way. Also, it's very sensitive to tiny changes in the order of things.

@dalcde
Copy link
Contributor

dalcde commented Jan 11, 2021

You should load the numpy package first.

@hoodmane
Copy link
Member Author

Indeed I should.

@dalcde dalcde merged commit 2266ccf into pyodide:master Jan 12, 2021
@hoodmane hoodmane deleted the clear-buffer-error branch January 12, 2021 05:31
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.

Soundness error in python2js_buffer
2 participants