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

Pip remaps - error when install #1792

Open
szuhow opened this issue Jul 12, 2024 · 1 comment
Open

Pip remaps - error when install #1792

szuhow opened this issue Jul 12, 2024 · 1 comment
Labels
bug rez-pip ingesting py pkgs into rez (pip, wheels, etc)

Comments

@szuhow
Copy link

szuhow commented Jul 12, 2024

Hey. I was just installing Opencue in rez environment, but i got some issue:

18:27:34 ERROR Unknown source file in pyoutline-0.22.14.dist-info/RECORD! '../../wrappers/local_wrap_frame'

To resolve, try:

    Manually install the pip package using 'pip install --target'
    to a temporary location.

    See where '../../wrappers/local_wrap_frame'
    actually got installed to by pip, RELATIVE to --target location

    Create a new rule to 'pip_install_remaps' configuration like:

    {
    "record_path": r"{pardir}{sep}{pardir}{sep}wrappers{sep}local_wrap_frame",
    "pip_install": r"<RELATIVE path pip installed to in 2.>",
    "rez_install": r"",
    }

    Try rez-pip install again.

If path remapping is not enough, consider submitting a new issue
via https://github.com/AcademySoftwareFoundation/rez/issues/new

Traceback (most recent call last):
File "/opt/software/rez-2.114.1/bin/rez/rez-pip", line 8, in
sys.exit(run_rez_pip())
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/cli/_entry_points.py", line 183, in run_rez_pip
return run("pip")
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/cli/_main.py", line 191, in run
returncode = run_cmd()
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/cli/_main.py", line 183, in run_cmd
return func(opts, opts.parser, extra_arg_groups)
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/cli/pip.py", line 64, in command
pip_install_package(
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/pip.py", line 366, in pip_install_package
src_dst_lut = _get_distribution_files_mapping(distribution, targetpath)
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/pip.py", line 565, in _get_distribution_files_mapping
rel_src, rel_dest = get_mapping(rel_src_orig)
File "/opt/software/rez-2.114.1/lib64/python3.9/site-packages/rez/pip.py", line 548, in get_mapping
raise IOError(
OSError: [Errno 89] Don't know what to do with relative path in pyoutline-0.22.14.dist-info/RECORD, see above error message for: '../../wrappers/local_wrap_frame'
18:27:34 ERROR BuildError: The custom build system failed.

I did those steps as above (installed pyoutline manually) and I have created rezconfig:

pip_install_remaps = [{
        "record_path": r"{pardir}{sep}{pardir}{sep}wrappers{sep}local_wrap_frame",
        "pip_install": r"{pardir}{sep}{pardir}{sep}wrappers{sep}local_wrap_frame",
        "rez_install": r"/home/rez/packages/",
    }]

And then I set REZ_PIP_INSTALL_REMAPS to those config file, but result is: File "/opt/rez/lib64/python3.9/site-packages/rez/config.py", line 52, in _parse_env_var
raise NotImplementedError

Any help on that case?
Thank you

@szuhow szuhow added the bug label Jul 12, 2024
@BryceGattis
Copy link
Contributor

@szuhow You shouldn't have to set REZ_PIP_INSTALL_REMAPS since you are setting this configuration option in your config file, you just need to make sure that rez is picking up your config file. Have you already set your REZ_CONFIG_FILE environment variable to ensure your custom rezconfig is being loaded?

@JeanChristopheMorinPerso JeanChristopheMorinPerso added the rez-pip ingesting py pkgs into rez (pip, wheels, etc) label Oct 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug rez-pip ingesting py pkgs into rez (pip, wheels, etc)
Projects
None yet
Development

No branches or pull requests

3 participants