decoder: Try to provide more explicit error context on invalid data (#29)
This partly reverts 572d0a6a and just changes %t -> %T so that printing does not enter infinite recursion and just print what we need: type of an object (%t is for true/false). Along the way I've added "pickle:" prefix to errors. In the future maybe it would make sense to create dedicated DecodeError which would contain position, current opcode, and error message itself. This way error reporting would be more structured and useful for users.
Showing
Please register or sign in to comment