Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate Python 2.x #693

Closed
7 of 8 tasks
bonjourmauko opened this issue Jul 23, 2018 · 15 comments
Closed
7 of 8 tasks

Deprecate Python 2.x #693

bonjourmauko opened this issue Jul 23, 2018 · 15 comments
Assignees
Labels
kind:theme A group of issues, directly tied to an OKR

Comments

@bonjourmauko
Copy link
Member

bonjourmauko commented Jul 23, 2018

As per python/devguide#344, Python 2 will be sunset come Jan 1st, 2020.

Additionally, a number of projects used in conjunction with OpenFisca have pledged to stop supporting Python 2 soon :

  • pandas
  • Matplotlib
  • NumPy
  • Jupyter notebook

Notably, NumPy's Python 2 maintenance mode will start come 2019.

Let's open the discussion and tackle this effort together.

To-do:

  • Change CircleCI configs
    • Core uses 3.7
  • Change READMEs
  • Edit doc
  • Shared in Slack #general (YouTube, future, ...)
  • Tweeted
  • Sent by email

EDIT by @fpagnoux:

Todo on January 1st:

  • Remove all the from __future__, from builtins and from future imports
@benjello
Copy link
Member

At IPP, we will be happy to participate to the big switch, but we will be ready to do that around next december ...

@fpagnoux
Copy link
Member

fpagnoux commented Jul 24, 2018

Shall we announce the end of Python 2 compatibility for January 1st 2019 then?

It seems a reasonable amount time for re-users to adapt their code.

@benjello
Copy link
Member

benjello commented Aug 2, 2018

@fpagnoux : I am not against having a strong deadline.

The best way to keep every contributors happy to reach it might be helping them to go through the necessary steps to transition to Python 3.

One point thought, using Python 2 until jan 2019 should be possible. And so the best way is having code supporting both Python until then.

Since @Anna-Livia and you went through the process, could you list somewhere if it is not to cumbersome the necessary steps to go through and I will definitively try to use that info to update IPP codebase and other packages like openfisca-survey-manager and openfisca-france-indirect-taxation (wich is BTW laggard in core too)

@guillett
Copy link
Member

guillett commented Aug 2, 2018

@jmdallais, @Lashchuk , @ThibaultCCMSA , @SChiusa , @JenniferTelep , @LacombeEric, @frtomas , @mtifarine , @marchand-laetitia-msa, would you be able to move PNDS servers to Python 3 before early 2019 ?

@jmdallais
Copy link

@guillett thanks for sharing.
@tchabaud, could you answer to @guillett please ? Strong prerequisites or constraints for us ?
Give me a call tomorrow please.

@fpagnoux
Copy link
Member

fpagnoux commented Aug 2, 2018

One point thought, using Python 2 until jan 2019 should be possible. And so the best way is having code supporting both Python until then.

Right now, the code is tested to run both in Python 2.7 and 3.6. So no worries until January!

Since @Anna-Livia and you went through the process, could you list somewhere if it is not to cumbersome the necessary steps to go through and I will definitively try to use that info to update IPP codebase and other packages like openfisca-survey-manager and openfisca-france-indirect-taxation (wich is BTW laggard in core too)

Yes, we can work on some documentation to support re-users migrations. We are right now still learning how to do it best, but we'll share recommandations when we have stronger convictions.

If I can recommend two things to get ready to migrating your codebase:

@t-chab
Copy link

t-chab commented Aug 3, 2018

Hello @jmdallais @guillett

Migration delay to switch to Python 3 seems really feasible, but I need to check with technical teams.
I'll let you know when I get an answer from them.

@t-chab
Copy link

t-chab commented Aug 14, 2018

@guillett : we plan to take advantage of the python 3 switch to get rid of the apache / mod_wsgi stack we're currently using to serve openfisca on our infrastructure.

Which python webserver would you advocate to replace this stack ? Which one do you use in production ?

@guillett
Copy link
Member

We use gunicorn and nginx in MesAides.

@t-chab
Copy link

t-chab commented Sep 7, 2018

@guillett : is it possible to directly switch to a Python 3.7 interpreted or is it too risky at the moment ?

@guillett
Copy link
Member

guillett commented Sep 7, 2018

@tchabaud I don't understand your question. Please feel free to call me next week.

@t-chab
Copy link

t-chab commented Sep 7, 2018

@guillett : I just wanted to know if we could install openfisca on a 3.7 python interpreter instead of a 3.6. According to this comment it seems to be only tested with 3.6 but we'll prefer to install the latest stable Python version if possible.

@bonjourmauko
Copy link
Member Author

@tchabaud Just for your information, I just ran a CircleCI build against OpenFisca-France and Python 3.7, and there were no visible problems: https://circleci.com/gh/openfisca/openfisca-france/3293#queue-placeholder.

@fpagnoux
Copy link
Member

fpagnoux commented Oct 2, 2018

Everything seems ready, we just need to wait for January 1st to:

  • Shut down Python 2.7 releasing
  • Remove backward compatibility code
    • Remove all from __future__, from builtins and from future imports
    • Remove other adaptations

@bonjourmauko
Copy link
Member Author

Thanks @fpagnoux 👍. I'll create another issue to track down shut down and close this one.

@bonjourmauko bonjourmauko added kind:theme A group of issues, directly tied to an OKR and removed flow:team:themes labels Oct 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:theme A group of issues, directly tied to an OKR
Projects
None yet
Development

No branches or pull requests

6 participants