-
-
Notifications
You must be signed in to change notification settings - Fork 16
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
Fix exception when parsing USFM with an empty verse paragraph #201
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #201 +/- ##
==========================================
+ Coverage 67.24% 67.27% +0.03%
==========================================
Files 441 441
Lines 34966 34993 +27
Branches 4689 4694 +5
==========================================
+ Hits 23514 23543 +29
+ Misses 10366 10361 -5
- Partials 1086 1089 +3 ☔ View full report in Codecov by Sentry. |
@ddaspit - added more errors found from the sample project. You may have a specific way you want to fix them. |
0aea06d
to
a30bbd8
Compare
The current error is: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding the errors. I will look into them.
Reviewable status: 0 of 4 files reviewed, 1 unresolved discussion (waiting on @johnml1135)
tests/SIL.Machine.Tests/Corpora/TestData/usfm/Tes/41MATTes.SFM
line 5 at r2 (raw file):
Previously, johnml1135 (John Lambert) wrote…
The current error is:
System.InvalidOperationException : An error occurred while parsing the text 'MAT
. Verse: MAT 1:0, offset: 179, error: 'Stack empty.'`. I still think that more context would be helpful - instead of people trying to count 179 tokens past the beginning of the verse (which starts exactly where?).
We could do line number and column instead of verse ref and verse offset. It would be a bit more work, since the UsfmTokenizer and UsfmParser aren't tracking line number and column, but it should be doable.
Previously, ddaspit (Damien Daspit) wrote…
Line number and offset (along with verse ref) would be nice - let's do it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 2 of 3 files at r1, 1 of 2 files at r2, 1 of 1 files at r3, 2 of 2 files at r4, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @ddaspit)
@ddaspit - Failed GetUsfm_NonVerse_Paragraph [84 ms] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 3 of 3 files at r5, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @ddaspit)
This change is