-
Notifications
You must be signed in to change notification settings - Fork 189
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
How to do error handling on custom truffle filesystems #781
Comments
It would be nice to provide a simple test-case that reproduces this problem. I tried the following code:
and I am getting
In other words, an exception is thrown as expected/requested. I have noticed that you edited your report and that the initial version of the source code contained
Alternatively, you can set |
@iamstolis If you say you couldn't reproduce it, I will check it once more. |
Conclusion: Static imports are behaving as expected and for dynamic imports, the last paragraph of @iamstolis comment about unhandled rejections was what I was searching for. |
Hi,
I implemented a custom filesystem and in general it's working fine. But there is an edge case where I'm not sure if it's expected behavior or if I'm missing something. The edge case is using JS code with a module import.
The custom filesystem is implemented against a resource repository which is a database. Part of the filesystem is also some error handling like this:
The caller code is implemented like this.
My expectation was that I'm able to capture the IOException in the caller code. I can see that the exception is thrown and then get wrapped in the GraalVM framework code and at some point it seems like it is swallowed by GraalVM.
The text was updated successfully, but these errors were encountered: