@@ -565,6 +565,8 @@ def _dissonanceScore(pitches, smallPythagoreanRatio=True, accidentalPenalty=True
565565 score_ratio = 0.0
566566 score_triad = 0.0
567567
568+ intervals : list [interval .Interval ] = []
569+
568570 if not pitches :
569571 return 0.0
570572
@@ -1159,7 +1161,7 @@ def listNames(cls):
11591161 'one-and-a-half-flat', 'one-and-a-half-sharp', 'quadruple-flat', 'quadruple-sharp',
11601162 'sharp', 'triple-flat', 'triple-sharp']
11611163 '''
1162- return sorted (accidentalNameToModifier . keys (), key = str . lower )
1164+ return sorted (a . lower () for a in accidentalNameToModifier )
11631165
11641166 # PUBLIC METHODS #
11651167
@@ -3209,7 +3211,7 @@ def implicitOctave(self) -> int:
32093211 else :
32103212 return self .octave
32113213
3212- # noinspection SpellCheckingInspection
3214+ # noinspection SpellCheckingInspection,GrazieInspection
32133215 @property
32143216 def german (self ) -> str :
32153217 '''
@@ -3274,7 +3276,7 @@ def german(self) -> str:
32743276 # noinspection SpellCheckingInspection
32753277 @property
32763278 def italian (self ) -> str :
3277- # noinspection SpellCheckingInspection
3279+ # noinspection SpellCheckingInspection,GrazieInspection
32783280 '''
32793281 Read-only attribute. Returns the name
32803282 of a Pitch in the Italian system
@@ -3357,7 +3359,7 @@ def _getSpanishCardinal(self) -> str:
33573359 'G' : 'sol' ,
33583360 }
33593361
3360- # noinspection SpellCheckingInspection
3362+ # noinspection SpellCheckingInspection,GrazieInspection
33613363 @property
33623364 def spanish (self ) -> str :
33633365 '''
@@ -3731,10 +3733,6 @@ def harmonicFromFundamental(self,
37313733 # 'target', target])
37323734
37333735 if distanceLower <= distanceHigher :
3734- # pd = 'distanceLower (%s); distanceHigher (%s); distance lower ' +
3735- # 'is closer to target: %s'
3736- # environLocal.printDebug(['harmonicFromFundamental():',
3737- # pd % (candidateLower, candidateHigher, target)])
37383736 # the lower is closer, thus we need to raise gap
37393737 match = candidateLower
37403738 gap = - abs (distanceLower )
@@ -4253,6 +4251,7 @@ def simplifyEnharmonic(
42534251 return returnObj
42544252
42554253 def getEnharmonic (self : PitchType , * , inPlace = False ) -> PitchType | None :
4254+ # noinspection GrazieInspection
42564255 '''
42574256 Returns a new Pitch that is the(/an) enharmonic equivalent of this Pitch.
42584257 Can be thought of as flipEnharmonic or something like that.
@@ -5055,7 +5054,7 @@ def set_displayStatus(newDisplayStatus: bool):
50555054 set_displayStatus (True )
50565055 return
50575056
5058- # no pitches in past...
5057+ # no pitches in the past list ...
50595058 if not pitchPastAll :
50605059 # if we have no past, we show the accidental if this pitch name
50615060 # is not in the alteredPitches list, or for naturals: if the
0 commit comments