Error trying to initialize a cloned Django project from github (Modulenotfounderror: No module named 'django_filters')

Asked

Viewed 361 times

0

I am trying to run on my pc a Django project that I cloned from github, but if I try to run the command 'python Manage.py' returns me the following error: File "Manage.py", line 16 ) from exc Syntaxerror: invalid syntax

and if I try to run python3 Manage.py runserver I have the following error: Modulenotfounderror: No module named 'django_filters'

I tried to run with and without a virtual environment. I tried to know and saw that maybe they are different versions of Django installed. If so, how can I make my virtual environment run in the correct version, since I don’t know the version that runs in the original environment?

  • 1

    At first it seems that the module Django-filter is not installed. You have already spun pip install -r requirements.txt, pip install django-filter or something like that?

  • Giovanni, the pip3 install Django filter solved, I was trying to install with’s' which appears in the error, in the case: pip3 install Django-Filters. but now is giving another error... No module named 'psycopg2'. knows which command to install this module?

  • 1

    There must be a file called "Reshuffles.txt" in the project you downloaded that contains its dependencies for you to install (in the first comment is the syntax of pip for this).

  • I created a requiriments.txt with Pip Freeze that I got from the original environment and it worked fine, thanks

1 answer

1

Just install the project dependencies as shown errors.

Check if there is a file in the project called Restore.txt, if not, install the dependencies as the errors shown in the console.

To isntalar Django-filter, run the Pip install Django-filter command, to install psycopg2, run the Pip install psycopg2-Binary command, and so on.

  • Thanks! I just had to find the correct versions of some dependencies.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.