-
Notifications
You must be signed in to change notification settings - Fork 981
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
Restore backward-compatibility layer for errors #1030
Merged
technoweenie
merged 5 commits into
lostisland:0.16.x
from
michaelherold:restore-backward-compatibility
Sep 27, 2019
Merged
Restore backward-compatibility layer for errors #1030
technoweenie
merged 5 commits into
lostisland:0.16.x
from
michaelherold:restore-backward-compatibility
Sep 27, 2019
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
michaelherold
force-pushed
the
restore-backward-compatibility
branch
from
September 27, 2019 18:44
f3bcde7
to
c180562
Compare
Faraday has been maintaining a backward-compatibility layer for errors in the `Faraday::Error::` "namespace". These were removed with v0.16.0, which caused issues for dependents that use semantic versioning constraints. It would be best if these were deprecated with a warning message and then dropped in v1.0 in order to make sure transitive dependencies do not break. See octokit/octokit.rb#1154
michaelherold
force-pushed
the
restore-backward-compatibility
branch
from
September 27, 2019 18:48
c180562
to
4925803
Compare
I rebased this on top of the 0.16.x branch because it should only go on those releases, not on the 1.0 release. The linter is now complaining about missing documentation for something that I didn't touch - I figure I shouldn't try to add those. |
This adds a very simple deprecation proxy that outputs when a deprecated constant is referenced. It's based on `ActiveSupport::Deprecations` but is much pared-down in functionality. Notably, it does not currently output the relevant part of the stacktrace that is referencing the error.
I added a very simple constant deprecation proxy for these backward-compatible error classes. Feel free to push back on the implementation! |
No clue why it's complaining here, and not every other file in lib/faraday :/
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Faraday has been maintaining a backward-compatibility layer for errors
in the
Faraday::Error::
"namespace". These were removed with v0.16.0,which caused issues for dependents that use semantic versioning
constraints.
It would be best if these were deprecated with a warning message and
then dropped in v1.0 in order to make sure transitive dependencies do
not break.
See octokit/octokit.rb#1154