aliyun / django-oss-storage

Django storage backends for AliCloud OSS.
MIT License
145 stars 67 forks source link

Fix "cannot import name 'force_text'" error to support Django > 4.0 #39

Open frankjlin16 opened 1 year ago

frankjlin16 commented 1 year ago

The "ImportError: cannot import name 'force_text' from 'django.utils.encoding'" error occurs when a package or module tries to import the force_text function from Django's encoding module, but the function has been removed and replaced with force_str in Django version 4. @huiguangjun @baiyubin

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.