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

refactor(source): Split RecursivePathSource out of PathSource #13993

Merged
merged 7 commits into from
Jun 3, 2024

Conversation

epage
Copy link
Contributor

@epage epage commented May 31, 2024

What does this PR try to resolve?

PathSource serves a couple of roles

  • When a dependency / patch uses path (non-recursive)
  • As the implementation details of a git source (recursive)
  • Dependency overrides (recursive)

Instead of using a PathSource::new vs PathSouce::new_recursive, this does RecursivePathSource::new. This makes the intent a lot clearer and makes it easier to customize the behavior to each role that is played.

Specifically, there are two ways I expect to leverage this refactor

How should we test and review this PR?

Additional information

@rustbot
Copy link
Collaborator

rustbot commented May 31, 2024

r? @ehuss

rustbot has assigned @ehuss.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added A-git Area: anything dealing with git A-workspaces Area: workspaces S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 31, 2024
@epage epage force-pushed the path-source branch 3 times, most recently from 97407c9 to 406bf68 Compare June 3, 2024 13:59
@ehuss
Copy link
Contributor

ehuss commented Jun 3, 2024

Thanks!

@bors r+

@bors
Copy link
Contributor

bors commented Jun 3, 2024

📌 Commit 406bf68 has been approved by ehuss

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 3, 2024
@bors
Copy link
Contributor

bors commented Jun 3, 2024

⌛ Testing commit 406bf68 with merge 1f020f0...

@bors
Copy link
Contributor

bors commented Jun 3, 2024

☀️ Test successful - checks-actions
Approved by: ehuss
Pushing 1f020f0 to master...

@bors bors merged commit 1f020f0 into rust-lang:master Jun 3, 2024
21 checks passed
@epage epage deleted the path-source branch June 3, 2024 16:40
bors added a commit to rust-lang-ci/rust that referenced this pull request Jun 5, 2024
Update cargo

9 commits in 7a6fad0984d28c8330974636972aa296b67c4513..34a6a87d8a2330d8c9d578f927489689328a652d
2024-05-31 22:26:03 +0000 to 2024-06-04 15:31:01 +0000
- Silence the warning about forgetting the vendoring (rust-lang/cargo#13886)
- fix(vendor): Ensure sort happens for vendor (rust-lang/cargo#14004)
- fix(add): Avoid escaping double-quotes by using string literals (rust-lang/cargo#14006)
- refactor(source): Split `RecursivePathSource` out of `PathSource` (rust-lang/cargo#13993)
- doc: Add README for resolver-tests (rust-lang/cargo#13977)
- Allows the default git/gitoxide configuration to be obtained from the ENV and config (rust-lang/cargo#13687)
- refactor: Transition direct assertions from cargo-test-support to snapbox (rust-lang/cargo#13980)
- Fix: Skip deserialization of unrelated fields with overlapping name (rust-lang/cargo#14000)
- chore(deps): update alpine docker tag to v3.20 (rust-lang/cargo#13996)

r? ghost
@rustbot rustbot added this to the 1.80.0 milestone Jun 5, 2024
flip1995 pushed a commit to flip1995/rust-clippy that referenced this pull request Jun 28, 2024
Update cargo

9 commits in 7a6fad0984d28c8330974636972aa296b67c4513..34a6a87d8a2330d8c9d578f927489689328a652d
2024-05-31 22:26:03 +0000 to 2024-06-04 15:31:01 +0000
- Silence the warning about forgetting the vendoring (rust-lang/cargo#13886)
- fix(vendor): Ensure sort happens for vendor (rust-lang/cargo#14004)
- fix(add): Avoid escaping double-quotes by using string literals (rust-lang/cargo#14006)
- refactor(source): Split `RecursivePathSource` out of `PathSource` (rust-lang/cargo#13993)
- doc: Add README for resolver-tests (rust-lang/cargo#13977)
- Allows the default git/gitoxide configuration to be obtained from the ENV and config (rust-lang/cargo#13687)
- refactor: Transition direct assertions from cargo-test-support to snapbox (rust-lang/cargo#13980)
- Fix: Skip deserialization of unrelated fields with overlapping name (rust-lang/cargo#14000)
- chore(deps): update alpine docker tag to v3.20 (rust-lang/cargo#13996)

r? ghost
bors added a commit that referenced this pull request Jul 1, 2024
refactor(source): Clean up after PathSource/RecursivePathSource split

### What does this PR try to resolve?

This is a follow up to #13993 and prep for future improvements (e.g. cargo script, #10752)

### How should we test and review this PR?

### Additional information
bors added a commit that referenced this pull request Jul 11, 2024
refactor(source): More RecursivePathSource clean up

### What does this PR try to resolve?

This is a follow up to #13993 and #14169 and is part of my work towards #10752.

### How should we test and review this PR?

### Additional information
bors added a commit that referenced this pull request Jul 15, 2024
fix(source): Don't warn about unreferenced duplicate packages

### What does this PR try to resolve?

This also improves the message, consolidating multiple duplicates and saying which was loaded instead, as it naturally fell out of the design

Fixes #10752

### How should we test and review this PR?

### Additional information

We're still subject to #13724 and fully load every manifest, even if we don't use it.  I'm exploring that topic at https://rust-lang.zulipchat.com/#narrow/stream/246057-t-cargo/topic/Redundant.20code.20in.20.60GitSouce.60.3F/near/450783427

This change builds on
- #13993
- #14169
- #14231
- #14234
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-git Area: anything dealing with git A-workspaces Area: workspaces S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants