-
Notifications
You must be signed in to change notification settings - Fork 542
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
pip_parse
using hermetic python interpreter is failing
#1463
Comments
This is failing because it is trying to build a wheel as there are no wheels available on PyPI. The workaround for this would be to build a wheel for |
May I know why it works when I don't set such attribute then? |
This is because when you don't set the attribute, it uses the system-wide python installation and it could be working because you may have all of the dependencies for building the wheel already installed on your system.
Repository rules are non-hermetic and in general produce different results on different machines.
…On 6 October 2023 12:54:31 GMT+09:00, Willy Soesanto ***@***.***> wrote:
May I know why it works when I don't set such attribute then?
--
Reply to this email directly or view it on GitHub:
#1463 (comment)
You are receiving this because you commented.
Message ID: ***@***.***>
|
After further investigation, I notice that it is using The command above works after I install Basically the following command.
|
We also encountered this issue when adding the requirements.txt
sw/requirements_lock.txt
WORKSPACE
produces the below error:
Unfortunately, We ended up adding extra arguments to the call to
WORKSPACE
Clearly, this isn't ideal.
|
You can consider pre-building wheels for your target platform(s) and hosting them on your own artifact repository such as Artifactory, AWS CodeArtifact, GCP Artifact Registry, GCP Assured OSS Software, S3 bucket etc. Then "pin" or "lock" your dependencies against wheels in pip using
Likely similar to above. Any resolution algorithm will try to backtrack to find wheels if none exist. This is likely slow unless you can short-circuit and give it some wheels to find using techniques as above. An entirely different approach could be for you to consider using alternative rules such as rules_pycross, which aims to support building from None of this is an easy problem, because Python package management is essentially |
It looks like #824 is tracking adding support for building C/C++ extensions. Perhaps another possible approach would be to build the missing wheels directly in Bazel? I haven't looked into how feasible that approach is at this time or how much of a lift it would be, though. |
I spent some time yesterday attempting to get
It's probably solvable, but I stopped there. Welcome to sdist building, I guess. |
Just echoing that I'm also unable to configure pcsclite on my Ubuntu host. Bootstrap errors out:
Sigh... Edit: I had to do
to run
for
and |
I think in these scenarios, the best option is generally to work with and support the upstream package (eg pcslite) to fix packaging errors or make their packages easier to build. It may also be possible to get them to publish wheels using projects like https://github.com/pypa/cibuildwheel |
This issue has been automatically marked as stale because it has not had any activity for 180 days. It will be closed if no further activity occurs in 30 days. |
This issue was automatically closed because it went 30 days without a reply since it was labeled "Can Close?" |
🐞 bug report
Affected Rule
The issue is caused by the rule:
pip_parse
Is this a regression?
Not certain.
Description
I am getting compilation error when it's trying to build wheel dependency.
It doesn't throw an error when I left out
python_interpreter_target
attribute ofpip_parse
.🔬 Minimal Reproduction
Repository link can be seen here: https://github.com/wsoesanto-arbo/rules_python-pipcompile
WORKSPACE
BUILD
requirements.in
requirements.txt
🔥 Exception or Error
🌍 Your Environment
Operating System:
Output of
bazel version
:Rules_python version:
Anything else relevant?
Nothing else. Please do let me know if I can provide more information.
The text was updated successfully, but these errors were encountered: