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

Add a missing require for octokit/repository #185

Merged
merged 2 commits into from
May 31, 2022
Merged

Conversation

elia
Copy link
Member

@elia elia commented May 31, 2022

Summary

The Repository constant is not autoloaded nor eagerly loaded in
Octokit v4.23.

While running rake clobber (from bin/setup) on my copy of solidus_subscription the following error was shown:

⤑ bin/rake clobber --trace                                                                              ~/C/N/solidus_subscriptions
To use retry middleware with Faraday v2.0+, install `faraday-retry` gem
rake aborted!
NameError: uninitialized constant Octokit::Repository

        repo = Octokit::Repository.from_url(gemspec.metadata['source_code_uri'] || gemspec.homepage)
                      ^^^^^^^^^^^^
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_dev_support-2.5.3/lib/solidus_dev_support/rake_tasks.rb:81:in `block in install_changelog_task'
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/github_changelog_generator-1.16.4/lib/github_changelog_generator/task.rb:43:in `define'
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/github_changelog_generator-1.16.4/lib/github_changelog_generator/task.rb:37:in `initialize'
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_dev_support-2.5.3/lib/solidus_dev_support/rake_tasks.rb:79:in `new'
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_dev_support-2.5.3/lib/solidus_dev_support/rake_tasks.rb:79:in `install_changelog_task'
/Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_dev_support-2.5.3/lib/solidus_dev_support/rake_tasks.rb:26:in `install'
<internal:kernel>:90:in `tap'
…

Checklist

  • I have structured the commits for clarity and conciseness.
  • I have added relevant automated tests for this change.

The Repository constant is not autoloaded nor eagerly loaded in
Octokit v4.23.
@elia elia self-assigned this May 31, 2022
@elia elia requested a review from waiting-for-dev May 31, 2022 09:16
@mergify
Copy link
Contributor

mergify bot commented May 31, 2022

It looks like this PR is missing a label to determine the type of change it introduces. The maintainer should add one of the following labels:

  • bug for bugfixes.
  • enhancement for new features and improvements.
  • documentation for documentation changes.
  • security for security patches.
  • removed for feature removals.
  • infrastructure for internal changes that should not go in the changelog.

Additionally, the maintainer may also want to add one of the following:

  • breaking for breaking changes.
  • deprecated for feature deprecations.

Once the correct labels have been set, simply remove the needs changelog label label from this PR so I can merge it.

@mergify mergify bot added the needs changelog label Needs a label to determine the type of change. label May 31, 2022
See rubocop/rubocop#10675 for details.
Let's keep `test_files` until this issue is clarified.
@kennyadsl kennyadsl added bug Describes or fixes a bug. and removed needs changelog label Needs a label to determine the type of change. labels May 31, 2022
@mergify mergify bot merged commit 077ce4b into master May 31, 2022
@mergify mergify bot deleted the elia/octokit-require branch May 31, 2022 10:50
@waiting-for-dev
Copy link
Contributor

It'll be fixed upstream when octokit/octokit.rb#1420 is merged.

@waiting-for-dev
Copy link
Contributor

Thanks, @elia!! ❤️

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

Successfully merging this pull request may close these issues.

None yet

3 participants