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

TSV converter bug fix: don't add 'd' prefix to 2-digit added tones like [add13] #1634

Merged
merged 4 commits into from
Aug 31, 2023

Conversation

malcolmsailor
Copy link
Contributor

The regex to add d to Mm7 chords on degrees other than 5 was giving false positives for cases like [add13], where it would match the 1, resulting in [addd13]. This PR fixes that bug.

I added 2 test cases to tsvEg_v2major.tsv and discovered that there was another bug where the d syntax (e.g., for IVd7) was not being removed when converting from Music21 to DCML tsv, although it is not used in the latter standard. So I also added a fix for that.

@coveralls
Copy link

coveralls commented Aug 19, 2023

Coverage Status

coverage: 93.036%. remained the same when pulling 8b76a3f on malcolmsailor:add-2-digit-figures into 8baa273 on cuthbertLab:master.

@mscuthbert mscuthbert merged commit f457a2b into cuthbertLab:master Aug 31, 2023
TimFelixBeyer added a commit to TimFelixBeyer/music21 that referenced this pull request Sep 2, 2023
commit f457a2b
Merge: fdb126c 8b76a3f
Author: Michael Scott Asato Cuthbert <michael.asato.cuthbert@gmail.com>
Date:   Wed Aug 30 22:54:36 2023 -1000

    Merge pull request cuthbertLab#1634 from malcolmsailor/add-2-digit-figures

    TSV converter bug fix: don't add 'd' prefix to 2-digit added tones like `[add13]`

commit fdb126c
Author: malcolmsailor <malcolm.sailor@gmail.com>
Date:   Sun Aug 27 10:42:42 2023 -0600

    Roman Numerals: Don't substitute `d` for `0` in `add10` (cuthbertLab#1635)

commit 8b76a3f
Author: Malcolm Sailor <malcolm.sailor@gmail.com>
Date:   Sat Aug 19 10:20:48 2023 -0400

    remove trailing ws

commit 9b5e387
Author: Malcolm Sailor <malcolm.sailor@gmail.com>
Date:   Sat Aug 19 09:50:07 2023 -0400

    update

commit d3af7bf
Author: Malcolm Sailor <malcolm.sailor@gmail.com>
Date:   Sat Aug 19 08:04:09 2023 -0400

    wip

commit 3babd94
Author: Malcolm Sailor <malcolm.sailor@gmail.com>
Date:   Mon Jul 17 14:10:56 2023 -0600

    don't match 'add13' when performing dominant 'd' substitution

commit 8baa273
Merge: 2a28ab1 9f35bbb
Author: Michael Scott Asato Cuthbert <michael.asato.cuthbert@gmail.com>
Date:   Thu Jul 13 14:07:36 2023 -1000

    Merge pull request cuthbertLab#1629 from TimFelixBeyer/patch-5

commit 9f35bbb
Author: Tim Beyer <35711942+TimFelixBeyer@users.noreply.github.com>
Date:   Thu Jul 13 23:56:39 2023 +0200

    fix flake

commit 4c5ee5f
Author: Tim Beyer <35711942+TimFelixBeyer@users.noreply.github.com>
Date:   Tue Jul 11 23:46:22 2023 +0200

    Remove use of hasElement

commit 8141355
Author: TimFelix <35711942+TimFelixBeyer@users.noreply.github.com>
Date:   Sat Jul 8 20:28:08 2023 +0200

    Remove uses of `hasElement`

commit d43ec76
Author: Tim Beyer <35711942+TimFelixBeyer@users.noreply.github.com>
Date:   Sat Jul 8 20:16:18 2023 +0200

    Speed up __contains__ by 2x and deprecate `hasElement`
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.

3 participants