DigiScore / neoscore

A python library for notating music in a graphics-first paradigm
https://neoscore.org
BSD 3-Clause "New" or "Revised" License
108 stars 9 forks source link

running example doesn't work #59

Closed kitchWWW closed 2 years ago

kitchWWW commented 2 years ago

Steps to produce:

1) mkdir test 2) cd test 3) python -m venv . 4) pip install neoscore 5) touch score.py 6) pasting the following text into score.py:

from neoscore.common import *
neoscore.setup()
Text(ORIGIN, None, "Hello, neoscore!")
neoscore.show()

7) python score.py produces this error:

Traceback (most recent call last):
  File "score.py", line 1, in <module>
    from neoscore.common import *
  File "/Users/bse/Documents/cs/pythonws/neoscore/lib/python3.7/site-packages/neoscore/common.py", line 1, in <module>
    from neoscore.core import neoscore
  File "/Users/bse/Documents/cs/pythonws/neoscore/lib/python3.7/site-packages/neoscore/core/neoscore.py", line 17, in <module>
    from neoscore.core.mouse_event import MouseEvent
  File "/Users/bse/Documents/cs/pythonws/neoscore/lib/python3.7/site-packages/neoscore/core/mouse_event.py", line 38, in <module>
    @dataclass(frozen=True)
  File "/Users/bse/Documents/cs/pythonws/neoscore/lib/python3.7/site-packages/neoscore/core/mouse_event.py", line 56, in MouseEvent
    window_pos: tuple[int, int]
TypeError: 'type' object is not subscriptable

Other things as an FYI:

ajyoon commented 2 years ago

Hey Brian, thanks for the report! It looks like there was a pasting mishap on the error you posted, could you provide the stacktrace? Also, what's your OS?

kitchWWW commented 2 years ago

Ahhhh, my b, thanks for the call out! updated. macOS Monterey 12.3.1

ajyoon commented 2 years ago

Got it, I'll fix this shortly.

ajyoon commented 2 years ago

Okay, this is fixed in 0.1.5, which I just released. Try updating neoscore to latest and lmk if that did the trick!

ajyoon commented 2 years ago

closing on expectation this is resolved