Migration to Python 3?

Post here if you want to help developing something for FAF.

Migration to Python 3?

Postby Eximius » 16 Mar 2014, 03:52

Are there any plans to port the lobby code to python 3?

Just because It was kind of a trivial task, I did it for funsies.
2to3 python conversion script did the job for the most part, the only manual changes I made were editing string literals which have '\' followed by 'U' or 'u' (which in python 3 mean unicode character points, and changing types.{Int,Float,List,Dict}Type to just int,float,list,dict (because python 3). Also, string.maketrans is just str.maketrans now.

I am using 64bit python3.3 (I am not expecting anyone to change to 64bit, because, well, people hate change.)

You can see the changes here: https://bitbucket ~ org/Eximius_/modular-client/commits/6270edb6d5b789a98998a89cc298840be10af4e5

Motivation
- Python 2 is still full-fledge python environment with little drawbacks from python 3.
+ Python 3 has a cleaner standard library.
+ Python 3 is constantly being updated.
+ Python 3 adds quite a few performance improvements.
+ All the cool kids use Python 3.

Troubles
    no py2exe for python3 ~ Solution ~> cx-freeze.sourceforge (Which even works on linux (I like linux))[/size]
    mumble_link is python2

Troubles due to my 64bit python
    uid.dll is 32bit
    mumble_link is 32bit

I guess the real question is what do you guys think?
Eximius
Crusader
 
Posts: 13
Joined: 16 Mar 2014, 00:41
Has liked: 1 time
Been liked: 13 times
FAF User Name: Eximius

Re: Migration to Python 3?

Postby Ze_PilOt » 16 Mar 2014, 23:35

Unnecessary.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Migration to Python 3?

Postby Eximius » 17 Mar 2014, 00:01

Can't say I expected much else, still kind of bummed though, but I fully understand. :)
Eximius
Crusader
 
Posts: 13
Joined: 16 Mar 2014, 00:41
Has liked: 1 time
Been liked: 13 times
FAF User Name: Eximius

Re: Migration to Python 3?

Postby Dragonfire » 27 Sep 2014, 19:00

Never change a running system ...
Not sure what happen with all the PyQt Code stuff ...
My native language is not english, please correct me, because I want to improve my skills # Resource Overview
User avatar
Dragonfire
Evaluator
 
Posts: 559
Joined: 19 Dec 2013, 10:18
Has liked: 39 times
Been liked: 61 times
FAF User Name: Dragonfire

Re: Migration to Python 3?

Postby Frozen_byte » 27 Sep 2014, 20:09

Since Py2 is still provided with security updates it is not necessary to update asap.
Anyway I also like to change for Python3.
Consider this:
Python3 is in active development
That means it will get more efficient, more secure, more feature-rich, more compatible over time.

So I approve the migration to Py3.


Dragonfire wrote:Never change a running system ...
Not sure what happen with all the PyQt Code stuff ...

Wiki answers:
https://wiki.python.org/moin/PyQt wrote:PyQt is available in two editions: PyQt4 which will build against Qt 4.x and 5.x and PyQt5 which will only build against 5.x. Both editions can be built for Python 2 and 3.
~¿Quis custodes custodit?~
User avatar
Frozen_byte
Avatar-of-War
 
Posts: 208
Joined: 21 Sep 2011, 22:03
Has liked: 37 times
Been liked: 22 times
FAF User Name: Frozen_byte

Re: Migration to Python 3?

Postby Aurion » 27 Sep 2014, 20:15

Frozen_byte wrote:Since Py2 is still provided with security updates it is not necessary to update asap.
Anyway I also like to change for Python3.
Consider this:
Python3 is in active development
That means it will get more efficient, more secure, more feature-rich, more compatible over time.

So I approve the migration to Py3.


Dragonfire wrote:Never change a running system ...
Not sure what happen with all the PyQt Code stuff ...

Wiki answers:
https://wiki.python.org/moin/PyQt wrote:PyQt is available in two editions: PyQt4 which will build against Qt 4.x and 5.x and PyQt5 which will only build against 5.x. Both editions can be built for Python 2 and 3.


Migration should happen if one of the following happens:

- Security flaws which won't get updated
- Really noticable performance increase (should compensate the amount of effort)
- New features are needed for something you want to develop

Updates just for the sake of buzz is not an option in professional development. I know it's exciting for the developers themselves to work with cutting edge (if not bleeding edge), I know, I am a developer too.
Aurion
Priest
 
Posts: 380
Joined: 25 Jul 2013, 20:03
Has liked: 12 times
Been liked: 15 times
FAF User Name: NuclearPudding

Re: Migration to Python 3?

Postby Ze_PilOt » 28 Sep 2014, 19:06

I would answer the exact same thing than Aurion.

Also, Python 2.x is still the most used version out there, and most likely the most stable and secured version.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt


Return to Contributors

Who is online

Users browsing this forum: No registered users and 1 guest