emily-modifiers icon indicating copy to clipboard operation
emily-modifiers copied to clipboard

All strokes starting with # and ending with the LTZ cause an error

Open NSGauge opened this issue 5 months ago • 0 comments

Stroking any stroke starting with # and ending with the LTZ causes the following error:

2024-09-19 10:42:45,976 [Dummy-1] ERROR: engine on_stroked failed
Traceback (most recent call last):
  File "build/windist/data\Lib\site-packages\plover\engine.py", line 147, in run
  File "build/windist/data\Lib\site-packages\plover\engine.py", line 383, in _on_stroked
  File "build/windist/data\Lib\site-packages\plover\translation.py", line 204, in translate
  File "build/windist/data\Lib\site-packages\plover\translation.py", line 296, in translate_stroke
  File "build/windist/data\Lib\site-packages\plover\translation.py", line 455, in _lookup_with_prefix
  File "build/windist/data\Lib\site-packages\plover\translation.py", line 405, in _lookup_with_suffix
  File "build/windist/data\Lib\site-packages\plover\translation.py", line 391, in _lookup_strokes
  File "build/windist/data\Lib\site-packages\plover\steno_dictionary.py", line 226, in lookup
  File "build/windist/data\Lib\site-packages\plover\steno_dictionary.py", line 192, in _lookup
  File "C:\Users\user\AppData\Local\plover\plover\plugins\win\Python39\site-packages\plover_python_dictionary.py", line 56, in get
    return self._lookup(key)
  File "<string>", line 145, in lookup
AttributeError: 'NoneType' object has no attribute 'groups'

Specifically in:

Traceback (most recent call last):
  File "C:\Users\user\PycharmProjects\steno\emily-modifiers.py", line 211, in <module>
    print(lookup(('#LTZ',)))
          ^^^^^^^^^^^^^^^^^
  File "C:\Users\user\PycharmProjects\steno\emily-modifiers.py", line 144, in lookup
    (shape, number, vowel2) = secondMatch.groups()
                              ^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'groups'

The error occurs on either line 117 or 144 depending on if * is included.

NSGauge avatar Sep 19 '24 08:09 NSGauge