-
Notifications
You must be signed in to change notification settings - Fork 5
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
Deprecate delegated check_*
methods
#75
Conversation
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.
Looks good to me!
This is a rather unremarkable reason to update a major version, though. As an alternative, what if instead we marked the methods with:
# :nodoc:
@[Deprecated("The visibility of this method will be changing in the future, and it should not be used directly")]
delegate check_jpeg, to: self.class
And then during a more noteworthy major release change, go through and clean up any @[Deprecated]
methods that were identified? That way we avoid the trap of doing a major version update for every technically-breaks-backwards-compatibility bug fix 😅
What do you think?
Apparently it doesn't work in the suggested order, but does work reversed. require "./src/pluto"
require "./src/pluto/format/webp"
class Test
include Pluto::Format::WebP
end
Test.new.check_webp(1)
|
Awesome suggestion, btw! |
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.
🚀
check_*
methodscheck_*
methods
I noticed these weren't private when playing with CrystalDoc.info.
This is indeed a breaking change, so the next release will have to be 2.0.0.