Installing django on python3.5.2. Debian

27 views
Skip to first unread message

mihail.p...@gmail.com

unread,
Dec 13, 2016, 4:30:23 PM12/13/16
to Django users
Hello! I have a problem with installing Django on python 3.5.2, Debian
I can't install pip on this version of python. However, python 3.4 has pip.
How can I install pip in python 3.5.2? 

Antonis Christofides

unread,
Dec 14, 2016, 2:45:22 AM12/14/16
to django...@googlegroups.com

Hi,

How did you install Python? Usually pip is installed together with Python. If for some reason it hasn't been installed, you should be able to install it with "python -m ensurepip". See https://docs.python.org/3/library/ensurepip.html.

Regards,

Antonis Christofides
http://djangodeployment.com
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/11beec53-44d9-464b-953f-dbc8f484beb6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Michal Petrucha

unread,
Dec 14, 2016, 2:51:58 AM12/14/16
to django...@googlegroups.com
If you installed Python from apt repositories, then you should almost
never use pip directly, in fact, there's very little reason for you to
have a system-level pip at all.

What you should do is create a virtualenv (either with the
python3-virtualenv package with the command “virtualenv”, or
python3-venv, using “python3 -m venv”). The virtualenv will already
contain a version of pip that you can use, and you're free to mess
with packages inside that virtualenv in whatever way you want.

The reason for this is that if you use pip with your system Python
installed from repositories, there's a high chance that you will
overwrite some of the essential repository-installed packages with
pip, which can render your entire Python installation unusable. This
does happen to people quite often, and it's quite difficult to recover
from.

Good luck,

Michal
signature.asc

GMail

unread,
Dec 14, 2016, 7:46:28 AM12/14/16
to django...@googlegroups.com
As far as I remember, in Debian-based distributions you have to install pip via another package, usually python-pip or python3-pip. Also, there's a way to install pip via easy_install.

And yes, you probably shouldn't use system pip, virtualenv does install pip inside newly created virtual environments.
> --
> You received this message because you are subscribed to the Google Groups "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
> To post to this group, send email to django...@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/20161214075129.GI22986%40koniiiik.org.
Reply all
Reply to author
Forward
0 new messages