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

Remove untyped methods from activerecord.rbi #347

Merged

Conversation

connorshea
Copy link
Contributor

No reason to have all these methods, they only make maintaining forward/backward compatibility more difficult for no benefit.

If you want to know all the methods that exist in ActiveRecord, you should be generating gem RBIs with Sorbet or Tapioca.

I've left in mixes_in_class_methods usages, to make sure that this commit doesn't remove anything that srb rbi gems wouldn't know about itself.

This resolves a lot of issues with the RBI (e.g. different arguments between these sigs and the actual methods in rails).

No reason to have all these methods, they only make maintaining
forward/backward compatibility more difficult for no benefit.

If you want to know all the methods that exist in ActiveRecord, you
should be generating gem RBIs with Sorbet or Tapioca.

I've left in mixes_in_class_methods usages, to make sure that this
commit doesn't remove anything
that `srb rbi gems` wouldn't know about itself.

This resolves a lot of issues with the RBI (e.g. different arguments
between these sigs and the actual methods in rails).
@connorshea connorshea requested a review from a team as a code owner March 20, 2021 18:18
@connorshea connorshea requested review from elliottt and removed request for a team March 20, 2021 18:18
@jez
Copy link
Collaborator

jez commented Mar 21, 2021

I'm fine to land this but can you ask in the #rails channel on Slack and confirm whether this is something most people want?

Copy link
Contributor

@hdoan741 hdoan741 left a comment

Choose a reason for hiding this comment

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

I like this because there are tools for generating method definition without signatures like tapioca and srb rbi gems

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants