[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Issue 2044 in lilypond: convert-ly fails on input with invalid version s
From: |
lilypond |
Subject: |
Issue 2044 in lilypond: convert-ly fails on input with invalid version string |
Date: |
Fri, 18 Nov 2011 00:11:42 +0000 |
Status: Accepted
Owner: ----
Labels: Type-Scripts OpSys-All Frog
New issue 2044 by address@hidden: convert-ly fails on input with
invalid version string
http://code.google.com/p/lilypond/issues/detail?id=2044
Reported by Werner Lemberg <address@hidden> with subject "convert-ly dies on
invalid input". From the report email:
Consider this (incorrect) input file `p.ly', consisting of a single
line:
\version "2.14."
convert-ly bombs out with
convert-ly (GNU LilyPond) 2.15.15
convert-ly: Processing `p.ly'...
Traceback (most recent call last):
File "/usr/local/bin/convert-ly", line 368, in <module>
main ()
File "/usr/local/bin/convert-ly", line 355, in main
do_one_file (f)
File "/usr/local/bin/convert-ly", line 260, in do_one_file
from_version = str_to_tuple (guess)
File "/usr/local/bin/convert-ly", line 172, in str_to_tuple
return tuple ([int(n) for n in s.split ('.')])
ValueError: invalid literal for int() with base 10: ''
It seems that the split() call in str_to_tuple() produces ['2','14',''] and
int('') throws ValueError. The root cause appears to be that convert-ly.py
fails to trap the malformed version string.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Issue 2044 in lilypond: convert-ly fails on input with invalid version string,
lilypond <=