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

Revert "Remove Gem::DependencyInstaller#find_gems_with_sources" #3412

Merged
merged 1 commit into from
Mar 24, 2020

Conversation

deivid-rodriguez
Copy link
Member

@deivid-rodriguez deivid-rodriguez commented Mar 22, 2020

Description:

I noticed that a pretty popular gem, ruby-debug-ide, is using Gem::DependencyInstaller#find_gems_with_sources, so removing this method means that installation of any Gemfile including ruby-debug-ide will break in the next rubygems version.

We obviously don't want that, so I'm reverting the removal for the moment.

Final removal is postponed until next year until we find a better way to manage deprecations (#3013).

Note that the check ruby-debug-ide is actually broken, but we still don't want to break installing it. Hopefully, they will fix this and stop using this method soon. See ruby-debug/ruby-debug-ide#142.

Closes #3411.

Tasks:

  • Describe the problem / feature
  • Write tests
  • Write code to solve the problem
  • Get code review from coworkers / friends

I will abide by the code of conduct.

@bronzdoc
Copy link
Member

Hey @deivid-rodriguez 😃

Just to understand this correctly, we are reverting this because we didn't give enough time to people to be aware of the deprecation warning?

@deivid-rodriguez
Copy link
Member Author

deivid-rodriguez commented Mar 22, 2020

I believe the gem is popular enough to justify reverting. Note that even if they fix the extension and release a new version, any Gemfile locked to an older version of the extension will crash on bundle install.

I think @hsbt had some tools to grep for usages of code inside gems, we could run that to see if there's more usages.

@deivid-rodriguez
Copy link
Member Author

deivid-rodriguez commented Mar 22, 2020

As an alternative, we could keep it as a "noop" returning [] with a warning about it not doing anything useful and just being kept for compatibility.

That would allow ruby-debug-ide to still install and us to remove the code.

@bronzdoc
Copy link
Member

Maybe we just should not include the commit that removed the method in the next release?

Also if we put a deprecation warning in Rubygems code and people decide to ignore it we can't really do much about it.

@deivid-rodriguez
Copy link
Member Author

deivid-rodriguez commented Mar 22, 2020

Maybe we just should not include the commit that removed the method in the next release?

That is what I'm doing here, reverting that commit.

Also if we put a deprecation warning in Rubygems code and people decide to ignore it we can't really do much about it.

I don't think that a gem maintainer being a little slow (define "slow" anyways) when updating their code to be warning free on newer rubygems should affect end users that have nothing to do with maintenance of a single specific gem. This will not be breaking a single gem's maintainer workflow, this will be breaking bundle install for everybody using this gem.

This warning has only been out there for like, 3 months, anyways. I don't think it's enough time to just let this break. And I believe it's actually easier for us to keep this method as a noop for now, than to deal with all the issues about bundle install breaking after people upgraded rubygems.

@hsbt
Copy link
Member

hsbt commented Mar 23, 2020

This is the list used with Gem::DependencyInstaller#find_gems_with_sources.

https://gist.github.com/hsbt/1565e70bfc41b5e6c64db791cd8df14d

I thought we should revert this because this list includes chef that is the famous provisioning tool.

This reverts commit 04c79d3.

Final removal is postponed until next year until we find a better way to
manage deprecations.
@deivid-rodriguez
Copy link
Member Author

Thanks for double checking this @hsbt!

@deivid-rodriguez deivid-rodriguez merged commit 5768bab into master Mar 24, 2020
@deivid-rodriguez deivid-rodriguez deleted the restore_find_gems_with_sources branch March 24, 2020 09:52
@hsbt hsbt mentioned this pull request Apr 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ruby-debug-ide won't install with the next rubygems version
3 participants