ImportError: cannot import name ‘datetime_safe’ from ‘django.utils’ (C:\Users\Omar.virtualenvs\vidly-SAfzz8MZ\Lib\site-packages\django\utils_init_.py)
I have got this error everytime I try to run the server following the django web application section in the python course this happened after the part where we install “django-tastypie” in the api section
at the beginning of the course was told to install Django 2.6 or something like that I guess, which is not supported and not working anymore with python 3.11 so I installed the latest version of Django to solve this issue but then found out that ‘datetime_safe’ no longer supported in the new versions of Django so I uninstalled Django then installed version 4.1 and it solved the problem
I wanted to post the solution not delete the post in case someone get the same issue later in the future