# Default version of python2 not being used



## mix_room (Dec 13, 2013)

As per the 20131003 entry in ports/UPDATING I have changed my make.conf to include 

```
DEFAULT_VERSIONS=python=2.7 python2=2.7
```
However, when I try to build lang/python2 I keep getting an older version, python2-2_2. 

My make.conf


```
PERL_VERSION=5.16.3
CC=clang
CXX=clang++
CPP=clang-cpp
DEFAULT_VERSIONS=       perl5=5.16 ruby=1.9 python=2.7 python2=2.7
```

This problem shows up both when using ports-mgmt/poudriere and when trying to build a local copy. Any idea what I am doing wrong?


----------



## DutchDaemon (Dec 13, 2013)

Try adding whitespace after the first equal sign.


----------



## mix_room (Dec 13, 2013)

There is white space there already, at least in my make.conf, some went missing in the copying from ports/UPDATING.


----------



## deflected (Dec 13, 2013)

Please note that installing of the lang/python2 port will install two Python packages:
lang/python2 - with current version python2 2_2 (if your ports tree is up to date) - this port will take care of symlinks of python2x
lang/python27 - with current version python27 2.7.6_1 (if your ports tree is up to date) - this is actually python2.7


----------



## mix_room (Dec 13, 2013)

So what you are saying is that having these two versions does not imply that the setting is not being applied?


----------



## DutchDaemon (Dec 13, 2013)

```
$ pkg info -ix python                                                                                                                              
python-2.7_1,2
python2-2_2
python27-2.7.6_1
```

If you have that output, it works as advertised.


----------



## deflected (Dec 14, 2013)

What I'm saying is that you are speaking for about different things.

lang/python2 is a meta-port - it's only responsible for symlinks of python 2.x.

I think that you are confused by 

```
DEFAULT_VERSIONS = ... python2=2.7
```
This itself doesn't mean that port lang/python2 needs to be 2.7 - this means that your python2 (because there is a python3) default version is 2.7.  And yes, the latest version of lang/python2 is 2_2 (not 2.7).


----------



## mix_room (Dec 17, 2013)

That is slightly confusing. I have the same output as @DutchDaemon. 

Thanks for helping me clear it up.


----------

