Open xeruf opened 3 years ago
I've added a check for missing/empty result file. Note that this will catch only certain cases.
In general, when you put an empty libe before the {end_of_abc}
, you can run the whole .cho file through abcm2ps and may get better diagnostics.
Leave this issue open as a reminder that this should be improved.
Issue
If there is some error in the embedded ABC notation, chordpro spits out roughly this:
Lots of text without any informative content - the first and the last line are the only interesting ones.
Idea
It would be nice to omit the lines in between by checking for file existence and then return information on the abc block that failed (there may be multiple), as well as writing that to a file so it can be debugged without hassle.
So, for example:
Where
/tmp/something.abc
contains the content of the abc block, which for the example below would be:Sample
For testing, you can use a simple chordpro file containing this (which has an incomplete abc header):
System information
ChordPro version 5.982 Perl version v5.34.0 Perl program /usr/bin/perl Storable 3.23 Resource path /usr/share/perl5/site_perl/App/Music/ChordPro/res Text::Layout 0.021 File::LoadLines 1.021 PDF::API2 2.041 Font::TTF 1.06