[reportlab-users] LGPL dependency - chardet

Josiah Kane josiah.kane at refeyn.com
Mon Jun 16 06:28:20 EDT 2025


Hello,

The current version of reportlab has a mandatory dependency on a library called "chardet" for guessing character encodings.
Chardet is released under the LGPL. This is a more restrictive license than the BSD license used by reportlab. It effectively prohibits using reportlab to those unable to comply with the lgpl. 

There is another popular library for addressing the character encodings called charset_normalizer (https://pypi.org/project/charset-normalizer/), which is released under a more permissive MIT license. It offers a compatibility interface with chardet, such that the only code changes required should be switching the module name. According to the author's tests, charset_normalizer also runs faster and supports more encodings. As a proxy for general popularity, according to https://piptrends.com/compare/charset-normalizer-vs-chardet, charset_normalizer is  downloaded approximately ten times more frequently than chardet. 

Would there be any openness to swapping out the dependency? 

Thanks
Josiah Kane
Josiah Kane
Principal Algorithm Engineer
josiah.kane at refeyn.com
+447474509563
+44 (0)1865 203956 
Refeyn Ltd, Unit 9, Trade City Oxford, Sandy Lane West, Oxford, OX4 6FF, UK
www.refeyn.com
•
@refeynit
Refeyn has a zero-tolerance policy towards sexual harassment, including by third parties. We insist that third parties treat our Employees professionally and with respect. Sexual harassment will not be tolerated and any complaint of sexual harassment by a third party will be fully investigated. In the interest of employee safety, we may pause all dealings with the third party until the investigation has been concluded. 
​
​Refeyn Ltd is a company registered in England & Wales with company number 11333643 and its registered address at c/o Penningtons Manches, Oxford Business Park, 9400 Garsington Road, Oxford, Oxfordshire, United Kingdom, OX4 2HN. This message is intended only for the use of the person(s) ("the Intended Recipient") to whom it is addressed. It may contain information that is privileged and confidential within the meaning of the applicable law. Accordingly any dissemination, distribution, copying or other use of this message or any of its content by any person other than the Intended Recipient may constitute a breach of civil or criminal law and is strictly prohibited. If you are not the Intended Recipient please contact the sender as soon as possible.
  
 Please consider the environment before printing this email.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20250616/a25e6b3d/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image041176.png
Type: image/png
Size: 134875 bytes
Desc: image041176.png
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20250616/a25e6b3d/attachment-0001.png>


More information about the reportlab-users mailing list