I always heard that python was a language that was friendly to monkey patching... well now i need to monkey patch and know not what to do.
I specifically need to disable the 'raising' of a parsing exception to see if a iso parsing library behaves. It's not so simple, because i'm using libmirage (which is a cdemu a cd emulator underlying library, to treat the first track of any kind of mode2 form 1 or mixed like a iso so that the iso parser library pycdlib can read it.
This works almost perfectly except... some of the psx cds in the redump collection i'm testing this out raise a exception during the parsing in pycdlib because of various parsing errors:
PyCdlibInvalidISO: data in 3rd unused field not zero
\
ValueError: year is out of range
\
PyCdlibInvalidISO: File structure version expected to be 1
etc.
What i'm really looking for is to disable the raising of exceptions during parsing, since the information i'm looking for has nothing much to do with iso validation - basically the serial inside of a single txt file - and those isos are vetted by redump anyway.
Is there any way to do this without importing and editing the library myself?