I think you are not correcly cheking what version of python OpenWISP uses.

Here's how to do it (commands copied from one of the instances I manage):

federico@ow2-controller:~$ cd /opt/openwisp2/
federico@ow2-controller:/opt/openwisp2$ source env/bin/activate
(env) federico@ow2-controller:/opt/openwisp2$ python --version
Python 3.6.

OpenWISP uses python 3 by default and python 2 is end of life soon:
https://pythonclock.org/

Best regards
Federico


On Fri, Feb 15, 2019 at 6:26 AM andreil1 <[email protected]> wrote:

> Hi !
>
> Which Python version should be set with:
>
> update-alternatives --install /usr/bin/python python /usr/bin/python2 1
> update-alternatives --install /usr/bin/python python /usr/bin/python3 2
> update-alternatives --config python
>
>
> on OpenWisp server?
> I found by default on Ubuntu 18.04LTS Ansible playbook installed OpenWisp
> under Python2, although playbook lists
>
> - hosts: openwisp2
>   roles:
>     - openwisp.openwisp2
>   vars:
>     openwisp2_default_from_email: "[email protected]"
>
>     openwisp2_python: python3
>
>
> There is no problem to stick with Python2, yet on 18.04LTS python-pip
> (python 2) is broken:
>
>  python-pip : Depends: python-pip-whl (= 9.0.1-2) but 9.0.1-2.3~ubuntu1 is
> to be installed
>               Recommends: python-all-dev (>= 2.6) but it is not going to
> be installed
>               Recommends: python-setuptools but it is not going to be
> installed
> E: Unable to correct problems, you have held broken packages.
>
> All that could be fixed somehow, yet installation path becomes rather
> thorny.
>
> Which distro and Python version is being used by OpenWISP developers ?
> Thanks in advance.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "OpenWISP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenWISP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to