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 #10871] Restore RuboCop::ConfigLoader.project_root
as deprecated
#10872
Merged
bbatsov
merged 1 commit into
rubocop:master
from
koic:restore_rubocop_config_loader_project_root
Aug 5, 2022
Merged
[Fix #10871] Restore RuboCop::ConfigLoader.project_root
as deprecated
#10872
bbatsov
merged 1 commit into
rubocop:master
from
koic:restore_rubocop_config_loader_project_root
Aug 5, 2022
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
koic
added a commit
to koic/rubocop-packaging
that referenced
this pull request
Aug 5, 2022
Fixes utkarsh2102#44. Fix a build error when using RuboCop 1.33+. The upstream will be resolved by the release of rubocop/rubocop#10872. Aprt from that, this patch can be resolved by RuboCop::Packaging alone independently from the upstream.
koic
added a commit
to koic/rubocop-packaging
that referenced
this pull request
Aug 5, 2022
Fixes utkarsh2102#44. Fix a build error when using RuboCop 1.33+. The upstream will be resolved by the release of rubocop/rubocop#10872. Apart from that, this patch can be resolved by RuboCop::Packaging alone independently from the upstream.
koic
added a commit
to koic/rubocop-packaging
that referenced
this pull request
Aug 5, 2022
Fixes utkarsh2102#44. Fix a build error when using RuboCop 1.33+. The upstream will be resolved by the release of rubocop/rubocop#10872. Apart from that, this patch can be resolved by RuboCop::Packaging alone independently from the upstream.
We can also start making use of https://www.rubydoc.info/gems/yard/file/docs/Tags.md#deprecated |
…eprecated Fixes rubocop#10871 and utkarsh2102/rubocop-packaging#44. This PR restores `RuboCop::ConfigLoader.project_root` as deprecated. It fixes the following build error. ```console % cd path/to/github.com/utkarsh2102/rubocop-packaging % bundle update && bundle exec rake (snip) Failures: 1) RuboCop::Cop::Packaging::BundlerSetupInTests when `require bundler/setup` is used in a Rakefile does not register an offense Failure/Error: let(:project_root) { RuboCop::ConfigLoader.project_root } NoMethodError: undefined method `project_root' for RuboCop::ConfigLoader:Class # ./spec/rubocop/cop/packaging/bundler_setup_in_tests_spec.rb:6:in `block (2 levels) in <top (required)>' # ./spec/rubocop/cop/packaging/bundler_setup_in_tests_spec.rb:39:in `block (3 levels) in <top (required)>' # ./spec/rubocop/cop/packaging/bundler_setup_in_tests_spec.rb:43:in `block (3 levels) in <top (required)>' ``` I considered a soft deprecation, but decided to issue a warning as it is probably of limited use.
koic
force-pushed
the
restore_rubocop_config_loader_project_root
branch
from
August 5, 2022 14:34
5dd7b0d
to
6c20212
Compare
That sounds like a good idea! I've updated it. And I will open a separate PR looking for and marking other deprecated APIs as well. |
I checked and it was already marked with |
WJWH
pushed a commit
to WJWH/rubocop
that referenced
this pull request
Aug 8, 2022
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.
Fixes #10871 and utkarsh2102/rubocop-packaging#44.
This PR restores
RuboCop::ConfigLoader.project_root
as deprecated.It fixes the following build error.
I considered a soft deprecation, but decided to issue a warning as it is probably of limited use.
Before submitting the PR make sure the following are checked:
[Fix #issue-number]
(if the related issue exists).master
(if not - rebase it).bundle exec rake default
. It executes all tests and runs RuboCop on its own code.{change_type}_{change_description}.md
if the new code introduces user-observable changes. See changelog entry format for details.