Skip to content

Commit 2d93372

Browse files
authored
Merge pull request #1739 from cuthbertLab/fix-doctests
music21 9.3.0
2 parents 4e90bfc + 2c153ec commit 2d93372

28 files changed

Lines changed: 265 additions & 151 deletions

CONTRIBUTING.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
`Music21` welcomes contributions such as bug reports, new features, fixes, and
22
documentation improvements. The
3-
[project repository](http://www.github.com/cuthbertLab/music21) is hosted at GitHub.
3+
[project repository](https://github.com/cuthbertLab/music21) is hosted at GitHub.
44

55
Information that was formerly here is now in
6-
[Developer Reference](https://web.mit.edu/music21/doc/developerReference/index.html)
6+
[Developer Reference](https://www.music21.org/music21docs/developerReference/index.html)
77

88
## Resources ##
99

10-
[Module Documentation and User's Guide](https://web.mit.edu/music21/doc/index.html)
10+
[Module Documentation and User's Guide](https://www.music21.org/music21docs/)
1111

1212
[Mailing List](https://groups.google.com/forum/#!forum/music21list)
1313

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ See: https://groups.google.com/forum/#!forum/music21list
4040

4141
[Contributing Guide](CONTRIBUTING.md)
4242

43-
## Community Code of Conduct ##
43+
## Community Code of Conduct<a name="community-code-of-conduct"></a> ##
4444

4545
`Music21` encourages contributions, discussions, and usage from all people interested in
4646
music and computers. This encouragement extends to all people regardless of (among other aspects)

dist/dist.py

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -28,51 +28,51 @@
2828
2929
3030
4. run test/warningMultiprocessTest.py for lowest and highest Py version -- fix all warnings!
31-
4b. run `from music21.test import treeYield
31+
5. run `from music21.test import treeYield
3232
and then run `treeYield.find_all_non_hashable_m21objects()` and check that the set returned is
3333
empty. Note -- it will print a bunch of module names, but only the final set matters.
3434
Then do the same for `treeYield.find_all_non_default_instantiation_m21objects()`.
35-
5. commit and wait for results on GitHub Actions
35+
6. commit and wait for results on GitHub Actions
3636
(normally not necessary, because it's slower and mostly duplicates multiprocessTest,
3737
but should be done before making a release).
3838
39-
6. run documentation/make.py clean (skip on minor version changes)
40-
7. run documentation/make.py linkcheck [*]
41-
8. run documentation/make.py [*]
39+
7. run documentation/make.py clean (skip on minor version changes)
40+
8. run documentation/make.py linkcheck [*]
41+
9. run documentation/make.py [*]
4242
4343
[*] you will need sphinx, Jupyter (pip or easy_install), markdown, and pandoc (.dmg) installed
4444
45-
10. ssh to athena.dialup.mit.edu (yes, dialup!), cd music21/doc and rm -rf * (skip on minor version changes)
45+
10. move music21 documentation/build/html to music21.org/music21docs/
46+
via Amazon S3 (contact MSAC for authentication if need be)
4647
47-
11. run documentation/upload.py or upload via ssh.
48-
-- you will need an MIT username and password + a dual authentication passcode
49-
50-
12. zip up documentation/build/html and get ready to upload/delete it.
48+
11. zip up documentation/build/html and get ready to upload/delete it.
5149
Rename to music21.v.7.1.0-docs.zip (skip for Alpha/Beta)
5250
53-
13. Run "hatch build" -- requires hatch to be installed "brew install hatch"
51+
12. Run "hatch build" -- requires hatch to be installed "brew install hatch"
52+
This builds the dist/music21-9.3.0.tar.gz and dist/music21-9.3.0-py3-none-any.whl
53+
files. That used to be what *this* script did, but now hatch does it better!
5454
55-
14. Run this file -- it builds the no-corpus version of music21.
56-
DO NOT RUN THIS ON A PC -- the Mac .tar.gz might have an incorrect permission if you do.
55+
13. Run this file: it builds the no-corpus version of music21.
56+
DO NOT RUN THIS ON A PC or the Mac .tar.gz might have an incorrect permission if you do.
5757
58-
15. PR and Commit to GitHub at this point w/ commit comment of the new version,
58+
14. PR and Commit to GitHub at this point w/ commit comment of the new version,
5959
then don't change anything until the next step is done.
6060
(.gitignore will avoid uploading the large files created here.)
6161
62-
16. Switch back to master/main branch
62+
15. Switch back to master/main branch
6363
64-
17. Tag the commit: git tag -a vX.Y.Z -m "music21 vX.Y.Z"
64+
16. Tag the commit: git tag -a vX.Y.Z -m "music21 vX.Y.Z"
6565
Don't forget the "v" in the release tag.
6666
Sanity check that the correct commit was tagged: git log
6767
68-
18. Push tags: git push --tags (or git push upstream --tags if not on main branch)
68+
17. Push tags: git push --tags (or git push upstream --tags if not on main branch)
6969
70-
19. Create a new release on GitHub and upload the TWO non-wheel files created here and docs.
70+
18. Create a new release on GitHub and upload the TWO non-wheel files created here and docs.
7171
Drag in this order: .tar.gz, -docs.zip, no-corpus.tar.gz
7272
7373
Finish this before doing the next step, even though it looks like it could be done in parallel.
7474
75-
20. Upload the new file to PyPI with "twine upload music21-7.3.5a2.tar.gz", and same for the
75+
19. Upload the new file to PyPI with "twine upload music21-7.3.5a2.tar.gz", and same for the
7676
whl file (but NOT no corpus) [*]
7777
7878
[*] Requires twine to be installed
@@ -87,9 +87,9 @@
8787
username:your_username
8888
password:your_password
8989
90-
21. Delete the two .tar.gz files and .whl file in dist.
90+
20. Delete the two .tar.gz files and .whl file in dist.
9191
92-
22. For starting a new major release create a GitHub branch for the old one.
92+
21. For starting a new major release create a GitHub branch for the old one.
9393
9494
22. Immediately increment the number in _version.py and run tests on it here
9595
to prepare for next release.

documentation/source/about/about.rst

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,17 @@ the BSD license (see below).
1010
About the Authors
1111
-----------------------
1212

13-
**Michael Cuthbert**, the creator of `music21`, is Associate Professor of Music at M.I.T.
13+
**Michael Cuthbert**, the creator of `music21`, is co-founder and chief music officer of
14+
`Artusi`_ and former tenured professor of music at M.I.T. where he created the Mellon-Funded
15+
Digital Humanities lab and taught computational music theory and musicology.
1416
He received his A.B. *summa cum laude*, A.M. and Ph.D. degrees from Harvard University.
1517
Cuthbert spent 2004-05 at the American Academy as a Rome Prize winner in Medieval Studies,
1618
2009-10 as Fellow at Harvard's Villa I Tatti Center for Italian Renaissance Studies
1719
in Florence, and 2012-13 at the Radcliffe Institute.
1820

1921
Prior to joining the M.I.T. faculty, Cuthbert was on the faculties of Smith
2022
and Mount Holyoke Colleges. He has worked extensively on computer-aided musical analysis,
21-
fourteenth-century music, and the music of the past forty years. He has published
22-
on computer-aided treatment of fragments and palimpsests of the late Middle Ages and
23-
on set analysis of Sub-Saharan African Rhythm and the music of John Zorn. In addition to
24-
work on music21, Cuthbert is currently writing a book on sacred music in Italy during the
25-
age of the Black Death and Great Papal Schism.
23+
fourteenth-century music, and the music since 1960.
2624

2725
**Christopher Ariza** is Emeritus Lead Programmer of `music21` and was
2826
Visiting Assistant Professor of Music
@@ -41,6 +39,8 @@ degree from Harvard University and his M.A. and Ph.D. degrees from New York Univ
4139
Additional contributions by many MIT students and visitors and the
4240
Open Source software community.
4341

42+
.. _Artusi: https://www.artusimusic.com/
43+
4444

4545
Acknowledgements
4646
----------------
@@ -52,7 +52,7 @@ Funding
5252
from the **Seaver Institute** and
5353
the **National Endowment for the Humanities**/Digging into Data research fund.
5454

55-
In addition, we acknowledge consistent support from `M.I.T.`_, the
55+
In addition, we acknowledge previous support from `M.I.T.`_, the
5656
`School of Humanities Arts and Social Sciences`_, and the
5757
`Music and Theater Arts`_ section.
5858

@@ -91,6 +91,10 @@ to this project. Their contributions and generosity are greatly appreciated.
9191
support and for their contributions to the open source music notation projects,
9292
including the Bach Goldberg Variations and the Handel Arias included.
9393

94+
* `Jacob Tylor Walls`_, contributed greatly to the type-safety, speed, and test coverage
95+
of `music21`. If your music21 program "just works" without needing to guess what
96+
any argument goes where, Jacob is to thank.
97+
9498
* `Donald Byrd`_, researcher on University of Indiana who created
9599
a schema for computer-aided musicology (along with the source of all sorts of
96100
examples of how music notation is difficult).
@@ -119,10 +123,10 @@ to this project. Their contributions and generosity are greatly appreciated.
119123
* Walter B. Hewlett and Craig Sapp of Stanford's CCARH for support.
120124

121125
* `Justin London` compiled and maintained the list of Second-Viennese
122-
row forms now available in serial.py.
126+
row forms that form the original backbone of serial.py.
123127

124128
* `McGill University`_ ELVIS project for including the MEI parser. Special thanks to Julie
125-
Cumming, Andrew Hankinson, and especially Christopher Antila for contributing.
129+
Cumming, Andrew Hankinson, Ichiro Fujinaga, and especially Christopher Antila for contributing.
126130

127131
* `Manuel Op de Coul`_ has kindly gave permission to use the Scala
128132
scale archive of nearly 4000 scales in music21.
@@ -138,6 +142,7 @@ to this project. Their contributions and generosity are greatly appreciated.
138142
Haydn, and Mozart, in musicxml format which we have been able to include in music21.
139143

140144
.. _Donald Byrd: https://web.archive.org/web/20220610200930/https://homes.luddy.indiana.edu/donbyrd/CMNExtremes.htm
145+
.. _Jacob Tylor Walls: https://jacobtylerwalls.com/
141146
.. _Laura E. Conrad: http://www.serpentpublications.org/drupal7/
142147
.. _MuseScore: https://musescore.com/
143148
.. _Bryen Travis: http://www.bachcentral.com/

documentation/source/developerReference/developerGuidelines.ipynb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"\n",
88
"`Music21` welcomes contributions such as bug reports, new features, fixes, and\n",
99
"documentation improvements. The\n",
10-
"[project repository](http://www.github.com/cuthbertLab/music21) is hosted at GitHub."
10+
"[project repository](https://github.com/cuthbertLab/music21) is hosted at GitHub."
1111
],
1212
"metadata": {
1313
"collapsed": false
@@ -20,7 +20,7 @@
2020
"\n",
2121
"Get to know this before contributing:\n",
2222
"\n",
23-
"[Module Documentation and User's Guide](https://web.mit.edu/music21/doc/index.html)\n",
23+
"[Module Documentation and User's Guide](https://www.music21.org/music21docs/index.html)\n",
2424
"\n",
2525
"[Mailing List](https://groups.google.com/forum/#!forum/music21list)\n",
2626
"\n",
@@ -186,7 +186,7 @@
186186
" - `Music21` was originally designed without this principle in mind, so you will find\n",
187187
" parts of the system that do not follow LSP and for backwards compatibility never will.\n",
188188
" I (Myke) have personally apologized to Barbara Liskov for my past ignorance.\n",
189-
" - Use [Sphinx formatting](https://web.mit.edu/music21/doc/developerReference/documenting.html#documenting-modules-and-classes)\n",
189+
" - Use [Sphinx formatting](https://www.music21.org/music21docs/developerReference/documenting.html#documenting-modules-and-classes)\n",
190190
" to link to classes and methods in docstrings\n",
191191
" - Prefer methods that by default do not alter the object passed in and instead return a new one.\n",
192192
" It is permitted and encouraged to have an `inPlace: bool = False` argument that allows for\n",
@@ -216,7 +216,7 @@
216216
"\n",
217217
"We write doctests and unit tests, and we strive for the total\n",
218218
"test coverage of the project to increase with every pull request. See the\n",
219-
"[developer docs](https://web.mit.edu/music21/doc/developerReference/index.html)\n",
219+
"[developer docs](https://www.music21.org/music21docs/developerReference/index.html)\n",
220220
"to dig in to specific topics like adjusting doctests to prevent\n",
221221
"actions we don't want executed when running the general test suite (such as opening\n",
222222
"browser windows or playing music).\n",

documentation/source/developerReference/musicxmlTest.ipynb

Lines changed: 138 additions & 36 deletions
Large diffs are not rendered by default.

documentation/source/usersGuide/usersGuide_08_installingMusicXML.ipynb

Lines changed: 6 additions & 6 deletions
Large diffs are not rendered by default.

documentation/source/usersGuide/usersGuide_11_corpusSearching.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
{
7070
"data": {
7171
"text/plain": [
72-
"3193"
72+
"3194"
7373
]
7474
},
7575
"execution_count": 2,

documentation/source/usersGuide/usersGuide_22_graphing.ipynb

Lines changed: 29 additions & 24 deletions
Large diffs are not rendered by default.

documentation/source/usersGuide/usersGuide_44_advancedGraphing.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1122,7 +1122,7 @@
11221122
"\n",
11231123
"* 'alpha' sets transparency, from 0 (transparent) to 1 (opaque).\n",
11241124
"* 'color' gives a color to the data point -- specified like \"red\" or \"green\" or an HTML color like \"#ff0044\"\n",
1125-
"* 'marker' on a scatter plot will choose a shape for a marker as in [this diagram](https://matplotlib.org/api/markers_api.html)\n",
1125+
"* 'marker' on a scatter plot will choose a shape for a marker as in [this diagram](https://matplotlib.org/stable/api/markers_api.html)\n",
11261126
"* 'markersize' gives the size of the marker -- notice that we're using matplotlib names, so the \"s\" of size is lowercased (in `music21` almost everything is camelCase)\n",
11271127
"\n",
11281128
"Let's make a new axis class which returns the frequency of each pitch but also changes its marker according to whether it's in a certain key or not:"
@@ -1328,7 +1328,7 @@
13281328
"source": [
13291329
"## Graph Primitives\n",
13301330
"\n",
1331-
"Untill now, all our our examples have used Plot classes taken from :ref:`moduleGraphPlot` because they were acting on streams to get their data. If you wanted to make graphs of data not coming from a Stream you could use matplotlib directly -- they have a great tutorial on [using their `pyplot` interface](https://matplotlib.org/users/pyplot_tutorial.html), for instance. Or if you want to get some of the advantages of the `music21` Plot types without going all the way into matplotlib, there are Graph primitives in the :ref:`moduleGraphPrimitives` module. Here are some examples of how those work:"
1331+
"Untill now, all our our examples have used Plot classes taken from :ref:`moduleGraphPlot` because they were acting on streams to get their data. If you wanted to make graphs of data not coming from a Stream you could use matplotlib directly -- they have a great tutorial on [using their `pyplot` interface]( https://matplotlib.org/2.0.2/users/pyplot_tutorial.html), for instance. Or if you want to get some of the advantages of the `music21` Plot types without going all the way into matplotlib, there are Graph primitives in the :ref:`moduleGraphPrimitives` module. Here are some examples of how those work:"
13321332
]
13331333
},
13341334
{

0 commit comments

Comments
 (0)