Fix LT-21867: Optional contexts don't work properly in Hermit Crab#296
Fix LT-21867: Optional contexts don't work properly in Hermit Crab#296jtmaxwell3 wants to merge 5 commits intomasterfrom
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #296 +/- ##
=======================================
Coverage 70.46% 70.47%
=======================================
Files 386 386
Lines 32256 32274 +18
Branches 4539 4542 +3
=======================================
+ Hits 22729 22744 +15
- Misses 8479 8481 +2
- Partials 1048 1049 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
ddaspit
left a comment
There was a problem hiding this comment.
This is definitely a bug in the Fst class. The class should properly handle the case where the start state is accepting. I would prefer that the Fst class is fixed. I took a stab at getting it to work in this PR. Let me know if it fixes the issue.
Reviewed 4 of 4 files at r1, all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @jtmaxwell3)
|
Fixing the Fst class is a better solution, and it seems to work. Thanks! You can delete this pull request. |
Fixed in the other PR. |
https://jira.sil.org/browse/LT-21867 reports that optional contexts don't work correctly. If a context is optional, then it should accept anything. But the code to traverse fsts doesn't accept the empty string. I wasn't able to fix the code to traverse fsts, so I changed the context code to check whether the context accepts the empty string.
This change is