[reportlab-users] Undeclared dependency on chardet

Robin Becker robin at reportlab.com
Mon Nov 13 09:04:38 EST 2023


Hi Matt,

sorry to delay my reply, this just got lost in my spam folder.

I think you are right and both para.py and rparsexml have been left behind.

I will add chardet as a dependency in the next micro release, 4.0.8.

I will definitely remove the breakpoint and some prints from smartdecode in rparsexml.


On 09/11/2023 13:18, Matt Folwell wrote:
> reportlab/lib/rparsexml.py contains a smartDecode class, which tries to import chardet at runtime, but reportlab doesn't 
> declare a dependency on chardet, so that gives an error.
> 
> Also smartDecode contains what look suspiciously like debugging print() calls.
> 
> It first appeared in Reportlab 3.6.12
> 
> rparsexml.py is only used by platypus/para.py and I realise para.py doesn't get a lot of attention, but it would be nice 
> if it worked in a default installation, either by declaring the dependency, or reverting rparsexml.py to a version that 
> didn't try to guess at an encoding.
...........
> 
> 
> -- 
> Matt Folwell
> 
> _______________________________________________
> reportlab-users mailing list
> reportlab-users at lists2.reportlab.com
> https://pairlist2.pair.net/mailman/listinfo/reportlab-users

-- 
Robin Becker



More information about the reportlab-users mailing list