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
Fix for gems not downloading from git via http #7649
Conversation
Thanks for opening a pull request and helping make RubyGems and Bundler better! Someone from the RubyGems team will take a look at your pull request shortly and leave any feedback. Please make sure that your pull request has tests for any changes or added functionality. We use GitHub Actions to test and make sure your change works functionally and uses acceptable conventions, you can review the current progress of GitHub Actions in the PR status window below. If you have any questions or concerns that you wish to ask, feel free to leave a comment in this PR or join our #rubygems or #bundler channel on Slack. For more information about contributing to the RubyGems project feel free to review our CONTRIBUTING guide |
@llenk thank you! It was great working with you at RailsConf. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a minor style comment but looks good to me other than that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like the revisions. Looks more general now. Maybe even a pattern to follow if there's other ways to back off the command when it doesn't work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤔 IMHO best would be to be able to check if remote supports "shallow capabilities", but I wasn't able to find out generic way to find out.
@llenk would you mind to squash commits please before merge? |
I was considering that, but (in addition to not being obvious how to do it) since most servers these days support them, it felt better to optimize for that case, and react when servers don't support it, instead of detecting support upfront. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the great work here!
Oops, I didn't notice it wasn't squashed yet. It's only 1 extra commit so I won't feel too bad 😉 |
What was the end-user or developer problem that led to this PR?
#7547
What is your fix for the problem, implemented in this PR?
The depth arguments in the git command were causing the problem. If we get the error on the first try, we remove the depth arguments from the command and try again.
Make sure the following tasks are checked