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

Building ovirt-imageio without build files #174

Open
liranr23 opened this issue Jan 3, 2023 · 6 comments
Open

Building ovirt-imageio without build files #174

liranr23 opened this issue Jan 3, 2023 · 6 comments

Comments

@liranr23
Copy link
Member

liranr23 commented Jan 3, 2023

When building using bazel and installing ovirt-imageio-common RPM to the image it ended up with:
Error processing tar file(exit status 1): link /usr/lib64/python3.9/site-packages/ovirt_imageio/_internal/handlers/pycache/checksum.cpython-39.pyc /usr/lib64/python3.9/site-packages/ovirt_imageio/_internal/handlers/pycache/checksum.cpython-39.opt-1.pyc: no such file or directory

Hopefully, if we remove the build files bazel will succeed to build the image.

@nirs
Copy link
Member

nirs commented Jan 3, 2023

What do you mean by "building using bazel"?

We don't have such build. Why are you building ovirt-imageio and not using released
package or pip?

@liranr23
Copy link
Member Author

liranr23 commented Jan 3, 2023

I am trying to build an image using bazel, the running code is with golang and needs ovirt-imageio installed in the image. I install in the image ovirt-image-common RPM. But the build fails with the above error.

@aesteve-rh
Copy link
Member

pyc files give better performance to run the package, avoiding re-parsing files every time. I'm not sure if it is a good idea to remove them.

Have you tried to install the package using pip?

@ahadas
Copy link
Member

ahadas commented Jan 9, 2023

pyc files give better performance to run the package, avoiding re-parsing files every time. I'm not sure if it is a good idea to remove them.

Fair enough

Have you tried to install the package using pip?

That would probably work but we try to build the images using bazeldnf as @liranr23 pointed out and seems it has an issue with links..

@rmohr
Copy link

rmohr commented Mar 15, 2023

Are the links "dead links"? That is something I did not consider in bazeldnf. We can probably handle that gracefully on the bazeldnf side if there are really dead links in the tar file. If the links are not dead, then maybe bazeldnf has a bug when reading the tar content.

@rmohr
Copy link

rmohr commented Mar 15, 2023

Also bazeldnf -- intended by design -- does not execute post-install scripts (in case the pyc files get generated there). That decisions favours reproducible builds and zero-privileges over full dnf/rpm compatibility.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants