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

StreamCore is now a Music21Object; Iterator improvements #1295

Merged
merged 5 commits into from
May 6, 2022

Conversation

mscuthbert
Copy link
Member

Typed Python does not work well with Mixin classes. There's little harm to making StreamCore a Music21Object, so it is now.

Other changes:
Attempt to unify __getitem__ on Stream and StreamIterator. For v8, a bare string w/o a dot or other query mark is discouraged, since in v7 it does different things on Streams (getElementSByClass) and on StreamIterators (getElementSINGULARById). In v9, these two types of calls will be unified into the same syntax.

mscuthbert added 5 commits May 5, 2022 13:23
This was for typing reasons.  But it seems that we need another approach.  Stream will need to derive from StreamCore -- a base.Music21Object
@coveralls
Copy link

Coverage Status

Coverage increased (+0.003%) to 93.097% when pulling dd8685a on iterator-mypy into 11dc9e6 on master.

@mscuthbert mscuthbert merged commit 137bf09 into master May 6, 2022
@mscuthbert mscuthbert deleted the iterator-mypy branch January 3, 2024 20:12
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

Successfully merging this pull request may close these issues.

2 participants