-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[WIP][PIP-56] Migrate the python2.7 to python3.7 #9684
[WIP][PIP-56] Migrate the python2.7 to python3.7 #9684
Conversation
As I mentioned in #9682 , though I've tested the new image in my local environment, currently there's no way to verify the change of I've just pushed the image to my dockerhub: https://hub.docker.com/r/bewaremypower/pulsar-build/tags?page=1&ordering=last_updated I'm not sure if it's proper to use the image for test. And after when all tests passed, those who have the permission of |
There's another concern that is bintray will shut down after May 2021, see https://jfrog.com/blog/into-the-sunset-bintray-jcenter-gocenter-and-chartcenter/ for details. However, the Boost official site uses bintray to download Boost source. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good
I have found the same solution googling
The python tests may fail because the new image use |
I think it still needs some code changes to make tests pass for Python3. So I'll also remove Python2 in this PR. |
After the latest commit, the python client tests ( For example:
It looks like the On the other hand, I found python functions code still use some python2 legacy code. |
I believe we should stick to python2. This new image must be 100% compatible with the previous one regarding python I initially added python3 in order to make the build of the image pass, because of "getpip" script. can you try to revert all of the changes related to python ? |
@eolivelli Removing Python2 support is a task of PIP 56 and issue 8622. Before the change of If it's not proper to do it in this PR, we need to find another way to fix the cpp/python tests. Then we cannot use Boost.Python for Python3 and should let CMake find Python2 instead of Python3. But eventually, we need to remove the Python2 related code and tests. So I just wanted to do it in this PR. |
Agreed. I also agree that one good way is to force cmake to find python2 |
OK, I may open a new PR to do it. And I'll keep this PR and the associated branch to do the task of PIP 56. |
@BewareMyPower @eolivelli I'm going to re-push the old image to docker hub to unblock CI while the issue is being fixed. We should also probably switch to a "versioned" build image, so that we can validate the switch in a PR. |
@merlimat I believe that @zymap already did it a few hours ago and he unblocked the release. |
Co-authored-by: Matteo Merli <[email protected]>
Since I've opened #9690 to fix the CI issue, I keeps this PR for PIP-56, which will remove Python2 from pulsar. |
The pr had no activity for 30 days, mark with Stale label. |
@BewareMyPower:Thanks for your contribution. For this PR, do we need to update docs? |
Fixes #8622
Motivation
Currently, ci-cpp-tests uses
pulsar-build
image that is fromubuntu:16.04
to build C++/Python client. The image useslibboost-all-dev
for CMake to find boost dependencies. However, the Boost.Python library from Ubuntu 16.04's apt source only supports Python 2.Modifications
Dockerfile
to install Boost dependency from source.Verifying this change
This change is a trivial rework / code cleanup without any test coverage.