Depending on what happened before loading jit_verbose, it fails with "error in error handling". This is reproducible for me if jit_verbose is the only mod on top of MTG. The following seems to work better for me:
local success, v = coroutine.resume(coroutine.create(function()
setfenv(0, ie)
return ie.require("jit.v")
end))
assert(success, "The jit_verbose mod couldn't load jit.v")
I don't know, but I tested it on several games and it never failed so far. Maybe doing setfenv(0) on a new throwaway thread is less brittle than doing it on the default thread, but I have no clue.
I don't know, but I tested it on several games and it never failed so far. Maybe doing setfenv(0) on a new throwaway thread is less brittle than doing it on the default thread, but I have no clue.
My fix ended up being to just wrap it in pcall, this gives a real error message now
I tried pcall, too, but the problem isn't the error reporting...it's the require failing when it shouldn't.
What error message does it report
I think I was trying local ok, result = pcall(ie.require, "jit.v") without a new function, but that seems to work, too. So I was probably doing something wrong.
If the issue is fixed for you, maybe you can put [fixed] in the thread name if you want
As soon as I find out how to do it:-)
Thanks!
EDIT: I don't see a way to edit the thread title...I'm probably just not seeing it or my browser is broken...sorry!
Depending on what happened before loading jit_verbose, it fails with "error in error handling". This is reproducible for me if jit_verbose is the only mod on top of MTG. The following seems to work better for me:
very weird
Why would it work
if i use the mod in devtest it seems to work fine
Okay, i reproduced it by not having luaJIT installed on my system, i'll try to fix it
Ok, i wrapped ie.require("jit.v") in pcall, it should now work
It will also give you a hint that you should have luaJIT installed on your system
I don't know, but I tested it on several games and it never failed so far. Maybe doing setfenv(0) on a new throwaway thread is less brittle than doing it on the default thread, but I have no clue.
My fix ended up being to just wrap it in pcall, this gives a real error message now
Does the latest release work for you
I tried pcall, too, but the problem isn't the error reporting...it's the require failing when it shouldn't.
What error message does it report
Yes it works, but it also does without the pcall. Just wrapping the require in a function seems to be enough to make it not error out.
interesting, well i think i'll keep the pcall just in case
if the issue is fixed for you, maybe you can put [fixed] in the thread name if you want
I think I was trying
local ok, result = pcall(ie.require, "jit.v")without a new function, but that seems to work, too. So I was probably doing something wrong.As soon as I find out how to do it:-)
Thanks!
EDIT: I don't see a way to edit the thread title...I'm probably just not seeing it or my browser is broken...sorry!