django-wkhtmltopdf icon indicating copy to clipboard operation
django-wkhtmltopdf copied to clipboard

Issue when updating to Django 4

Open mijaramillo opened this issue 3 years ago • 1 comments

image

Hello, when I upgraded my project to django 4 and tried to run it with runserver I got the error attached. Therefore, the dependency requires the smart_text function which is no longer available for this version of Django. However, in the Django repository it is noted that smart_text is deprecated, so smart_str should be used, which is available in Django 4, so this could solve the problem.

mijaramillo avatar Jan 11 '22 19:01 mijaramillo

AFAICT the tentative fix works.

As we wait for it to land here, you can get it by patching your requirements.txt like this:

-django-wkhtmltopdf
+git+https://github.com/simevo/django-wkhtmltopdf.git@bugfix/issue-193-smart_text

I am not sure about making a PR because this may break with older Djangos ...

simevo avatar Jan 20 '22 15:01 simevo