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

Use targeted repositories that are only scanned explicitly #4353

Closed
wants to merge 1 commit into from

Conversation

zevisert
Copy link

@zevisert zevisert commented Aug 4, 2021

This PR adds functionality for "targeted" repositories, which are not scanned during solving unless a package explicitly marks it as a source.

Example:

[[tool.poetry.source]]
name = "slow"
url = "https://foo.bar/simple/"
targeted = true

[tool.poetry.dependencies]
python = "^3"
your_package = { version = "^1", source="slow" }

Pull Request Check List

Resolves: #4035

  • Added tests for changed code.
  • Updated documentation for changed code.

@zevisert
Copy link
Author

zevisert commented Aug 4, 2021

I haven't yet added a test to confirm that solving doesn't communicate with a targeted source unless explicitly requested. The tests started to look pretty complicated with all of the MockRespository functionality, so I thought it best to first check if there's interest in merging this PR at all.

@neersighted
Copy link
Member

neersighted commented Jun 4, 2022

I'm not sure this is the approach we are going to take -- it's generally agreed that the current design is poor, but we would like to make a breaking change and improve it instead of tacking on more variant settings that increase the difficulty in reasoning about repositories. I would suggest joining the Discord server to discuss this with the core team, or creating an issue to talk about a new design for repositories.

I'm going to close this for now as this won't get merged in its current form -- feel free to re-open if suggestions for a new design occur and they crystalize into code, however.

@neersighted neersighted closed this Jun 4, 2022
@zevisert
Copy link
Author

zevisert commented Jun 7, 2022

No problem, the code changes here were mostly just hacks to get the idea somewhat demonstrable. I agree with that sentiment tacking on more hacks is not the way to go!

🚀

Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add ability to specify package sources that are not scanned/used by default
2 participants