-
-
Notifications
You must be signed in to change notification settings - Fork 136
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
lupa coroutines choke on nested pcalls & yield #48
Comments
@immerrr that's strange, but for me your example prints
|
Lua 5.2.3, lupa 1.1 from pypi, OS X |
Still fails for me on Ubuntu 12.04, lupa=1.1 and Lua 5.2.0. But probably this is a hint in the right direction: pcall should return all the outputs of the function it wraps after Maybe 5.2.3 is more liberal and doesn't think this is an error :) |
This is a problem with Lua 5.2.0 which is fixed in 5.2.1: http://www.lua.org/bugs.html#5.2.0-4, closing the issue. |
I have been running after a weird
error in error handling
error lately when hacking splash and I seem to have pinned the issue down. Here's an example that looks admittedly contrived when all the unnecessary details are omitted:It produces the following output for me:
As you can see, the coroutine is easily traversed inside Lua code but not in Python code. The issue is reproduced when all three following conditions are true:
pcall
s in the coroutinecoro.yield
somewhere inside thosepcall
sThe text was updated successfully, but these errors were encountered: