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

Better handling for number dictionary #3

Open
nsmarkop opened this issue Jul 6, 2018 · 0 comments
Open

Better handling for number dictionary #3

nsmarkop opened this issue Jul 6, 2018 · 0 comments

Comments

@nsmarkop
Copy link
Owner

nsmarkop commented Jul 6, 2018

Unit testing the numbers dictionary has revealed some issues even though the base functionality works as expected.

First, reverse_lookup sort-of worked but does not handle cases where the numbers are split with - or reversed with * properly. This may be a lost cause as at the moment it seems like it'd take significant effort to resolve.

Secondly, lookup is quite permissive of input. If you give it 1258 instead of 125-8, 1290 instead of 12-90, etc. it works fine even though that violates how the steno order is supposed to be written.

Thirdly, You can't unit test reverse_lookup code that has a return value (so, a "passing" case) because when it calls normalize_stroke it errors out due to a raised AssertionError because a "system" has not been initialized in the plover package which it's using during normalize_steno internally for things like NUMBER_KEY lookups and such.

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

No branches or pull requests

1 participant