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
Inconsistent defaulting to python
implementation, and errors when using cpp
#9180
Comments
I ran into a variation of this error recently and managed to fix it by adding the flag |
(UPDATED; SEE END OF COMMENT) I just started running into what appears might be a related issue.
I get:
The odd thing:
On Mac 2 this comes up empty (though the rest of the package is there).
As I mentioned, the software environments on both are pretty identical. Mac 2 is one of the new M1 Max MBPs and does not have Rosetta installed, while the first is a regular M1 with Rosetta installed. Could either of those things be a factor somehow? (the architecture is the same and this is all native code, so I wouldn't think so, but perhaps it is somehow?..) UPDATE: After some more thorough cleaning/reinstalling, I'm no longer seeing .so files on Mac1. Its looking like these were stale files left over from a conflicting homebrew protobuf package installed as a dependency and they were sticking around despite uninstalling/reinstalling things via pip. So now I'm seeing no .so files anywhere and everything is working via the 'python' implementation everywhere. So I'm guessing this is the expected state of the world and all is well. I'll leave this comment up though in case my little journey of discovery is useful to anyone. |
@efroemling I assume you intend to use the |
I was able to reproduce this, thanks. I think the root cause here is that 3.18.0 moved us from "manylinux1" to "manylinux2014" as our platform tag. Earlier versions of Python appear to still require older platform tags such as manylinux1. This change was caused by #8280 (cc @jtattermusch) I think perhaps the solution here is to revert to manylinux1 for x86-64 and only use manylinux2014 for aarch64. More detail follows: For Python 3.7.2 with Protobuf 3.17.1, it is installing the wheel
For Protobuf 3.19.1, it doesn't appear we are building a
Whereas for 3.17.3 we released:
Diffing these two lists we get: -cp27-cp27m-macosx_10_9_x86_64.whl
-cp27-cp27mu-manylinux_2_5_x86_64.manylinux1_x86_64.whl
-cp35-cp35m-macosx_10_9_intel.whl
-cp35-cp35m-manylinux_2_5_x86_64.manylinux1_x86_64.whl
-cp35-cp35m-win32.whl
-cp35-cp35m-win_amd64.whl
+cp310-cp310-macosx_10_9_universal2.whl
+cp310-cp310-manylinux2014_aarch64.whl
+cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
cp36-cp36m-macosx_10_9_x86_64.whl
-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl
+cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
cp36-cp36m-win32.whl
cp36-cp36m-win_amd64.whl
cp37-cp37m-macosx_10_9_x86_64.whl
cp37-cp37m-manylinux2014_aarch64.whl
-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl
+cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
cp37-cp37m-win32.whl
cp37-cp37m-win_amd64.whl
cp38-cp38-macosx_10_9_x86_64.whl
cp38-cp38-manylinux2014_aarch64.whl
-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl
+cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
cp38-cp38-win32.whl
cp38-cp38-win_amd64.whl
cp39-cp39-macosx_10_9_x86_64.whl
cp39-cp39-manylinux2014_aarch64.whl
-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl
+cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
cp39-cp39-win32.whl
cp39-cp39-win_amd64.whl
py2.py3-none-any.whl The two main changes I observe here are:
|
Any idea how to revert the manylinux2014 to manylinux1 for Linux? |
I looked into this and found that the problem most likely has nothing to do with my PR #8280 (which only affects the build or aarch64 wheels and it doesn't change anything for the x86_64 wheels). @haberman is correct that there was a sudden switch from It seems that the unintended switch from manylinux1 to manylinux2014 wasn't actually caused by a change in this repository, but by a change in https://github.com/matthew-brett/multibuild.
On Aug 21, matthew-brett/multibuild has switched the default manylinux image from Some extra evidence:
The solution is relatively simple:
|
Thanks @jtattermusch - do you have a rough idea of when this fix might make it into a release? |
That is up to the protobuf team to decide. Also, they'll need to decide about possibly backporting into the existing releases. |
Thanks @jtattermusch very much appreciated. Seems like the updates on the PR have stopped, is there anything we can do to revive that thread? |
Same issue here. Any timeline update for the fix release? |
I was able to get rid of the
|
It doesn't seem that the fix #9216 has made it into the 3.19.x branch for the 3.19 release. Unless it gets backported, to 3.19.x, it will be in the next release 3.20.x. @anandolee please consider backporting to 3.19.x |
Hi, I'm curious to know if there's a timeline for the 3.20.x release? Or if it's been announced / tracked somewhere? |
3.20.0 which includes the fix has already been pre released. Office release will happen in these two weeks |
@anandolee thanks for the heads up. Do you know if this fix will get back ported to already released versions? If not we'll need to exclude versions |
We do not have plan to back ported |
Hey, we were hit by this issue too. Was this fix released in |
@taliastocks if it helps, we're currently using |
We are about to release version 4.21.0, which builds wheels using an entirely new Bazel-based workflow. It should address the issues raised in this bug, and it uses More information here: https://developers.google.com/protocol-buffers/docs/news/2022-05-06#python-updates |
What version of protobuf and what language are you using?
Versions:
3.17.3
,3.18.0
,3.18.1
, and3.19.0
Language: Python (versions
3.7.2
,3.8.6
,3.9.0
, and3.10.0
What operating system (Linux, Windows, ...) and version? gLinux
What runtime / compiler are you using (e.g., python version or gcc version) python and/or cpp
What did you do?
Steps to reproduce the behavior:
Run this bash script. Note that it require
pyenv
to be installed, along with Python versions3.7.2
.What did you expect to see
I expect this script to run without error.
What did you see instead?
Make sure you include information that can help us debug (full error message, exception listing, stack trace, logs).
This was first detected as a performance issue, as our benchmarks began showing large regressions due to the library unknowingly running the
python
implementation. For more context on the history see this Issue.Anything else we should know about your project / environment
There are issues with a number of combinations of Python versions and
protobuf
library versions. Here are the combinations I found that have problems when running the above reproduction script:python
implementation incorrectlycpp
python
implementation incorrectlypython
implementation incorrectlycpp
cpp
python
implementation incorrectlypython
implementation incorrectlycpp
cpp
python
implementation incorrectlycpp
The text was updated successfully, but these errors were encountered: