Crash and error fixes - #64
Open
UncleGrumpy wants to merge 5 commits into
Open
Conversation
Fix get_flags/1 undefined crash by adding default value 0, this will allow `is_beam/1` and `is_entrypoint/1` to return `false` rather than crash on malformed or unrecognized files. Signed-off-by: Winford <winford@object.stream>
UncleGrumpy
force-pushed
the
crash_and_error_fixes
branch
from
July 25, 2026 05:28
27307ec to
0e17161
Compare
Add default [] to get_imports/1 and get_atoms/1. Signed-off-by: Winford <winford@object.stream>
Use structured tuple `{no_start_module_found, ParsedFiles}` in `prune/2` for
error reporting.
Signed-off-by: Winford <winford@object.stream>
Propagate write errors in write_packbeam/2, return {error, {write_failed, ...}}
instead of silently swallowing the error.
Signed-off-by: Winford <winford@object.stream>
Replace exit/1 with throw/1 in get_parsed_file/2 to prevent early VM termination, and allow error to be reported. Signed-off-by: Winford <winford@object.stream>
UncleGrumpy
force-pushed
the
crash_and_error_fixes
branch
from
July 25, 2026 05:31
0e17161 to
66c7f0a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Prevent some avoidable crashes in API calls. Fix early exits in API calls, allowing errors to propagate to applications to allow graceful error reporting and exit at the applications discretion. Throw an error when writing the avm file fails, rather than silently absorb the error, misleading users to believe the operation was successful.