Closed frederiksteiner closed 2 months ago
Hi @frederiksteiner thanks for the bug report!
Unfortunately there's not enough in the logs for me to have a very good guess the problem. A couple questions for you:
pyre --sequential check
help any? If so, it's likely a failure in our parallelization logic.One possibility is that we made some changes around scheduling workers (Pyre runs in parallel by default) that might be playing a role here; if we see that --sequential
is okay then this is an especially likely root cause.
- What operating system are you on? I am running WSL2 with Ubuntu 20.04.5. Same error happens, when running pyre in a docker container (redhat/ubi8-minimal:8.9)
- Does running
pyre --sequential check
help any? If so, it's likely a failure in our parallelization logic. Nope, unfortunately, the error is the same
I'm having the same issue. I cannot replicate reliably in some environments but never get it on others.
0.9.19
works but 0.9.21
doesn't. --sequential
doesn't work.
@stroxler, could you provide the tags for versions 0.9.19
onwards? I don't see them on GitHub. Also, can you reliably rebuild the wheel for these versions?
The version tags actually do exist, but for some historical reason I have no context on we prepend a v
so the tags are v0.9.19
and v0.9.21
; I can work on getting rid of the prepending but you can see the tags here:
https://github.com/facebook/pyre-check/tags
The wheels can be reliably built in theory, although we might have some trouble actually accessing them (they are built by some internal CI processes that want to push the results to pypi); there's room for improvement here but it's what we have for now.
@frederiksteiner I cannot repro with your repo and steps on Mac. Do you have a dockerfile that can reproduce the issue?
@vthemelis I added a Dockerfile to the github repo: https://github.com/frederiksteiner/pyre-bug/blob/master/Dockerfile
It's not the most beautiful dockerfile, but it should do the job I guess :)
Looks like the issue is that pyre requires glibc>=2.34
(?).
# /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin
/root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin)
/root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin: /lib64/libc.so.6: version `GLIBC_2.29' not found (required by /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin)
/root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin: /lib64/libc.so.6: version `GLIBC_2.33' not found (required by /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin)
/root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin: /lib64/libc.so.6: version `GLIBC_2.34' not found (required by /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin)
/root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin: /lib64/libc.so.6: version `GLIBC_2.32' not found (required by /root/.cache/pypoetry/virtualenvs/bug-pyre-il7asoJj-py3.11/bin/pyre.bin)
@frederiksteiner, I guess that using a newer version of your operating system or upgrading glibc will resolve this for you. Also, I don't think that this is related to poetry.
@stroxler, would it be possible to statically link libc
in pyre?
@vthemelis Yes that seems to be the case. When changing the image version to ubi9-9.4 everything seems to work properly
Should I close the issue?
I think that it would still be worth thinking about statically linking libc into the executable as part of the issue.
Let's leave it open for now, I probably can't get an answer on statically linking this week but I'll ask around; that would probably be a great idea assuming there isn't something preventing it.
Also @vthemelis how did you get those logs? @samwgoldman had a theory that maybe OCaml is buffering stderr and then dying before it flushes, so I was wondering if we should look into it but I'm curious what worked for you.
@stroxler I got the logs by running pyre.bin directly (no arguments needed). The logs were in stderr and I opened #863 to propagate them through the python wrapper script.
I would look into the static linking bit but I don't have a Linux workstation handy which makes this a bit more tedious.
I had a quick look and in the end, I think that it may be a bad idea to statically link libc as this may make pyre even less compatible.
Looks like the best way is to use a manylinux container to build the wheel. I wonder if pyre could be build with such a container that supports an older version of libc.
Yeah, I think we came to the same conclusion.
Our current setup uses internal CI infra (which does not use or allow Docker) to build Pyre so we'll need to translate all of that into a setup we can containerize.
Should I wait until #863 is done or should I close the issue now?
We can close this, I'll keep working with @vthemelis to get #863 merged but I don't think that blocks this.
And I'll actually file a new issue for the glibc build since it's relatively clear what we need to do (and it may take some time)
Pyre Bug
Bug description Pyre returning ERROR Check command exited with non-zero return code: 1 since newest release when using pyre with poetry and running the following command: poetry run pyre --noninteractive --debug --sequential check Was working with version 0.9.19.
Reproduction steps https://github.com/frederiksteiner/pyre-bug/tree/master Here would be a pretty small github repo, with all the steps in the read me or also here: Step 1: Install python 3.11.9 and poetry Step 2: Run "poetry env use 3.11" Step 3: Run "poetry install" Step 4: Run "poetry run pyre --noninteractive --debug --sequential check"
Expected behavior Running smoothly and returning the expected
Logs Please include any relevant logs here:
Please run your reproduction steps followed by
pyre rage > pyre_rage.log
, and upload the file here: pyre_rage.logAdditional context Add any other context about the problem here. (like dependencies in your venv, third party stub files being used, overall goals, etc.)