Issue 119 in mingus: Some minor code issues in progressions.py

2 views
Skip to first unread message

min...@googlecode.com

unread,
Feb 9, 2013, 9:28:06 PM2/9/13
to mingus...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 119 by andreas....@gmail.com: Some minor code issues in
progressions.py
http://code.google.com/p/mingus/issues/detail?id=119


I'm not a python head but as I am porting this to C++ I am finding a few
logical errors here and there. I will report as I go along.

progressions.py



line 302 if ignore_suffix is True any elif will be ignored

# Minor to major substitution
if suff == 'm' or suff == 'm7' or (suff == '' and roman in
["II", "III", "VI"]) or ignore_suffix:
n = skip(roman, 2)
a = interval_diff(roman, n, 3) + acc
if suff == 'm' or ignore_suffix:
res.append(tuple_to_string((n, a, 'M')))
elif suff == 'm7' or ignore_suffix:
res.append(tuple_to_string((n, a, 'M7')))
elif suff == '' or ignore_suffix:
res.append(tuple_to_string((n, a, '')))
return res


line 281..not really an issue but...

if r != None:
suff = suff if suff == '7' else ''<--this does nothing no?
res.append(tuple_to_string((r, acc, suff)))





Reply all
Reply to author
Forward
0 new messages