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

Invalid path missing segment orientation causes crash upon loading graph #166

Closed
ASLeonard opened this issue Nov 18, 2024 · 1 comment · Fixed by #167
Closed

Invalid path missing segment orientation causes crash upon loading graph #166

ASLeonard opened this issue Nov 18, 2024 · 1 comment · Fixed by #167

Comments

@ASLeonard
Copy link

In the case of a malformed path in the gfa, specifically a segment missing its orientation, BandageNG will just instantly crash and exit (at least on macos).

This graph is able to reproduce the behaviour (or the path segment 1,2+). Changing to the valid 1+,2+ will load the graph successfully)

S       1       TAG
S       2       CAT
L       1       +       2       +       0M
P       foo     1+,2    0M

It seems like oriented_segment in io/gfa.cpp should handle invalid input and complain later, but this just crashes.

Best,
Alex

@asl
Copy link
Owner

asl commented Nov 28, 2024

Thanks for the report! Apparently, it seems that while there is a note in oriented_segment that segment name should be validated further on, this did not happen.

Should be fixed in #167 (and new snapshot will be available shortly)

asl added a commit that referenced this issue Nov 28, 2024
@asl asl closed this as completed in #167 Nov 28, 2024
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 a pull request may close this issue.

2 participants