Skip to content

bump git2 dependencies #7706

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

Merged
merged 1 commit into from
Dec 23, 2019
Merged

bump git2 dependencies #7706

merged 1 commit into from
Dec 23, 2019

Conversation

matthiaskrgr
Copy link
Member

This required some manual code changes which dependabot could not perform.

@rust-highfive
Copy link

r? @Eh2406

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 13, 2019
@Eh2406
Copy link
Contributor

Eh2406 commented Dec 13, 2019

Ci seems unhappy.

@@ -197,7 +197,7 @@ pub fn add_submodule<'a>(
default_repo_cfg(&subrepo);
t!(subrepo.remote_add_fetch("origin", "refs/heads/*:refs/heads/*"));
let mut origin = t!(subrepo.find_remote("origin"));
t!(origin.fetch(&[], None, None));
t!(origin.fetch(&[&String::new()], None, None));
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you explain why this change is needed? The docs still say an empty array is OK.

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, I see, it is due to rust-lang/git2-rs#482. Perhaps it could use a cast instead?

Copy link
Member

Choose a reason for hiding this comment

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

Yes I believe this is the cause of the broken CI as well, and agree that this should use an explicit cast and/or type parameter to convince the build it should work.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah looks like I broke the tests by having none-empty vectors, silly me...
Using &Vec::<String>::new() instead of &[&String::new()] seems to work.

@Eh2406
Copy link
Contributor

Eh2406 commented Dec 23, 2019

Ci is green so:
@bors r+
Thanks for the PR!

@bors
Copy link
Contributor

bors commented Dec 23, 2019

📌 Commit 8245e02 has been approved by Eh2406

@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 Dec 23, 2019
@bors
Copy link
Contributor

bors commented Dec 23, 2019

⌛ Testing commit 8245e02 with merge b42bec7...

bors added a commit that referenced this pull request Dec 23, 2019
bump git2 dependencies

This required some manual code changes which dependabot could not perform.
@@ -1201,7 +1201,7 @@ fn dep_with_changed_submodule() {
.remote_set_url("origin", &git_project3.url().to_string())
.unwrap();
let mut origin = subrepo.find_remote("origin").unwrap();
origin.fetch(&[], None, None).unwrap();
origin.fetch(&Vec::<String>::new(), None, None).unwrap();
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
origin.fetch(&Vec::<String>::new(), None, None).unwrap();
origin.fetch(&[] as &[&str], None, None).unwrap();

@@ -197,7 +197,7 @@ pub fn add_submodule<'a>(
default_repo_cfg(&subrepo);
t!(subrepo.remote_add_fetch("origin", "refs/heads/*:refs/heads/*"));
let mut origin = t!(subrepo.find_remote("origin"));
t!(origin.fetch(&[], None, None));
t!(origin.fetch(&Vec::<String>::new(), None, None));
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
t!(origin.fetch(&Vec::<String>::new(), None, None));
t!(origin.fetch(&[] as &[&str], None, None));

@bors
Copy link
Contributor

bors commented Dec 23, 2019

☀️ Test successful - checks-azure
Approved by: Eh2406
Pushing b42bec7 to master...

@bors bors merged commit 8245e02 into rust-lang:master Dec 23, 2019
@ehuss ehuss added this to the 1.42.0 milestone Feb 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

7 participants