You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now the DiscError exception is being called for any issue with reading the disc, e.g., including there not being a disc drive at all or the user not having permission to access it. It would be nice if at least these two (no drive, no permissions) could be handled by their own exceptions.
The text was updated successfully, but these errors were encountered:
Well, libdiscid only has the two options success or failure and on failure there is a function to get the error message.
We would then need to parse the error message (which is not necessarily the same on all platforms, as are the reasons for failure) and based on that raise different exceptions.
That's for "no drive". Even the libdiscid code doesn't when something is not working due to permissions. (It just doesn't work in terms of libdiscid code). Now it would be possible to add some code to libdiscid to also check for that (for all platforms), but I don't think I would have time for that.
So I don't see that happen :-/
I would accept patches for python-discid though if anybody wants to check the libdiscid code, note down all error messages, and add some "detection" code to python-discid.
This would be a bit hacky, but could in theory work backwards compatible when the new Exception is a subclass of 'DiscError'.
Right now the
DiscError
exception is being called for any issue with reading the disc, e.g., including there not being a disc drive at all or the user not having permission to access it. It would be nice if at least these two (no drive, no permissions) could be handled by their own exceptions.The text was updated successfully, but these errors were encountered: