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

ci: Timeline to drop Xenial + Python 2 support #10606

Open
EricCousineau-TRI opened this issue Feb 6, 2019 · 16 comments

Comments

@EricCousineau-TRI
Copy link
Contributor

commented Feb 6, 2019

Should determine when to remove support, and remove it.

Current timelines:

  • ~2019-07-15: For systems that support Python 3, make it the default.
    • #11728 Ensure that it's easy to still use --config=python2
    • #11731 Update docs to emphasize Python 3
    • #11733 Switch defaults to Python 3
  • 2019-10-01: Ensure that we can use Python 3 Director (possibly use it, or wait)
  • 2019-10-26: Drop support for Ubuntu Xenial.
  • 2019-10-26 2020-01-01: Drop support for Python 2, coupled with its EOL dropping Xenial.

Add'l actions:

  • #11729 Add some roadmap traceability Put into support roadmap

This will be kept open until timelines are complete.

\cc @jamiesnape

@jamiesnape

This comment has been minimized.

Copy link
Contributor

commented Feb 7, 2019

I will propose either October 26th, 2019 or April 26th, 2020 as an arbitrary date to switch off the last Xenial build with the turndown beginning three to six months before the chosen date.

@EricCousineau-TRI EricCousineau-TRI changed the title ci: Determine timeline for Xenial support ci: Determine timeline for Xenial, Python 2 support Feb 7, 2019

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Feb 7, 2019

Also need a date for Python 2. Ideally, Jan. 1, 2020, since that's its EOL. (TODO: Add authoritative ref.)

@jwnimmer-tri

This comment has been minimized.

Copy link
Collaborator

commented Feb 7, 2019

I think dropping Xenial toward the end of 2019 is a good goal (Oct 26th is fine). That will make room for working toward 20.04 LTS support after the new year.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Feb 14, 2019

Per f2f, should define a date to make python2 the explicitly needed call-out in build jobs, and make python3 the default. For now, on or before June 15, 2019.

Should also consider when to make platforms default to using Python 3. Could happen before or at the same time as build job switch. Min. 3 months before removing Python 2 support.

EDIT: Will be highly coupled to what our ROS1 support is.

@jwnimmer-tri

This comment has been minimized.

Copy link
Collaborator

commented Mar 1, 2019

@EricCousineau-TRI notable for the TRI side, we should endeavor to move past GCC-6 on Bionic internally, prior to GCC-5 (Xenial) disappearing from Drake's CI. If Drake CI only has GCC-7, we don't want to be firefighting GCC-6 issues in our internal CI. GCC-7 had major C++17 improvements, so GCC-6 and GCC-7 are relatively dissimilar.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Mar 7, 2019

Notes from f2f Kitware meeting:

Might also be able to push up Python 2 deprecation on Mac.
Would simplify Homebrew packaging, and lighten the load on Jamie for packaging.

Possibly just make Mojave images be Python 3 only?
Would relate Drake Visualizer upgrade, but that may not be too much overhead - all platforms should use Drake Visualizer on Python 3.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jun 20, 2019

Question from @jamiesnape, relevant to #11380:

  1. Where supported, can we default to Python 3?
  2. Can we drop Python 2 the same time as Xenial?

My personal vote:
(1) - yes
(2) - yes, depending on @RussTedrake's needs for underactuated / manipulation?

@RussTedrake

This comment has been minimized.

Copy link
Contributor

commented Jun 21, 2019

My vote:
(1) yes.
(2) yes.

@RussTedrake

This comment has been minimized.

Copy link
Contributor

commented Jun 21, 2019

@peteflorence asked "Does anybody know what the ROS’s Python 2 —>3 plan is?" Could we spell out any implications for ROS users here?

@jamiesnape

This comment has been minimized.

Copy link
Contributor

commented Jun 26, 2019

You can get it to (mostly) work if you build from source, otherwise time to migrate to ROS 2.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jun 26, 2019

Yup, that's what we do in Anzu for things that require C extensions like cv_bridge and tf2_py. Pure
Python packages just work out of the box in Python 3 (although you have Python 2 libraries on your path...).

Regarding Python 2 vs 3 defaulting in Slack discussion:

I would say we initially try to target July 15. I will add a checkbox above.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jun 26, 2019

Given votes and per discussion in #11729, updated timeline to push up Python 2 removal to the same date as Xenial.

@EricCousineau-TRI EricCousineau-TRI changed the title ci: Determine timeline for Xenial, Python 2 support ci: Timeline to drop Xenial + Python 2 support Jun 26, 2019

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jun 27, 2019

When we drop Python 2, we should use Director's Python 3 (changing branch, etc.).

@jwnimmer-tri jwnimmer-tri referenced this issue Jul 1, 2019
0 of 2 tasks complete
@jamiesnape

This comment has been minimized.

Copy link
Contributor

commented Jul 15, 2019

CI will be switching defaults either later today or tomorrow. I just need to create Mac -python2- jobs.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jul 18, 2019

Jamie mentioned that CI is now switched over to Python 3 default. Just need to fixup merge in #11733.

@EricCousineau-TRI

This comment has been minimized.

Copy link
Contributor Author

commented Jul 22, 2019

Just saw this ROS discourse post recently, but to @peteflorence's question about Python 2 + ROS1:
https://discourse.ros.org/t/ros-1-and-python-2-7-end-of-life/9941/6
Takeaway is that Python 3 support for ROS 1 won't really come until Noetic, which will have alpha releases around October, but seems like it'll be coupled to Ubuntu 20.04 and is targeted to release in May 2020?

I haven't yet figured out what that means for Drake; my ideal minimum-effort solution is that we still only accommodate Python 3 after the October deadline, meaning that it would cut off use of ROS1 prebuilt binaries with Drake.

However, from my experience in Anzu with our limited use of ROS1, it seems like most core pure Python ROS1 packages support Python 3, and most C extension libraries (e.g. tf2_py and cv_bridge) can be rebuilt in Python 3. These can be used as an overlay on an existing Python 2 installation, so the only finicky part is ensuring you map the upstream Python 2 dependencies to Python 3. (I will see if I can post the Docker recipe we have for producing the Python 3 C extension overlay in that ROS discourse post. EDIT: Posted example)

On the ROS 2 front, it seems to be up and coming, but the translation is still not completely trivial, and there are some remaining RViz features to be ported that had stopped me during my spike test. There is some active work on this, and I will revisit it later either this quarter or next.


In short: It's, uh, complicated, given ROS1's scheduling having dead-time to support Python 3 after Python 2's EOL, and possibly not supporting 16.04 / 18.04 for Noetic... :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.