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

Install downstream packages in correct subdir #4763

Merged
merged 1 commit into from
Feb 9, 2023
Merged

Conversation

kenodegard
Copy link
Contributor

@kenodegard kenodegard commented Jan 31, 2023

Description

Resolves #4750

Checklist - did you ...

  • Add a file to the news directory (using the template) for the next release's release notes?
  • Add / update necessary tests?
  • Add / update outdated documentation?

@kenodegard kenodegard added the source::anaconda created by members of Anaconda, Inc. label Jan 31, 2023
@conda-bot conda-bot added the cla-signed [bot] added once the contributor has signed the CLA label Jan 31, 2023
pkg_loc = os.path.join(pkg_subdir, os.path.basename(pkg_file))
shutil.move(pkg_file, pkg_loc)
break
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why break?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it was missing from before, there's no need to continue processing once we have a valid pkg_loc

info = json.loads(Path(pkg_dir, "info", "index.json").read_text())
subdir = info["subdir"]
except (FileNotFoundError, KeyError):
subdir = m.config.host_subdir
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dislike this fallback, what do we do instead? let the errors propagate up?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

old packages don't have subdir IIRC

Copy link
Contributor

@dholth dholth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jezdez jezdez merged commit 925c227 into main Feb 9, 2023
@jezdez jezdez deleted the downstream-hacking branch February 9, 2023 09:50
@jezdez
Copy link
Member

jezdez commented Mar 13, 2023

This had missed news and tests :-/

@kenodegard kenodegard added this to the 3.24.0 milestone Mar 13, 2023
@kenodegard kenodegard mentioned this pull request Mar 13, 2023
3 tasks
jezdez pushed a commit that referenced this pull request Mar 20, 2023
@github-actions github-actions bot added the locked [bot] locked due to inactivity label Mar 13, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cla-signed [bot] added once the contributor has signed the CLA locked [bot] locked due to inactivity source::anaconda created by members of Anaconda, Inc.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Downstream tests download to wrong subdir (breaks boa+libsolv>=0.7.23)
4 participants