Skip to content

Upgrading octokit 1 to 2

Breaking1.25.0 → 2.7.2Breaking2New14Changed1Fixed6Other9

BreakingUpgrade verdict

2 breaking changes.

  • Remove warn for Releases and Search APIs.
  • Removes spec files from gemspec to fix installation on Windows.
2 items need code or config changes

octokit publishes an official migration guide for version 2. It covers more than the release notes do.

Upgrade Guide ↗

Adds sawyer ~> 0.5.2.

Drops addressable, faraday, faraday_middleware, hashie, multi_json, netrc.

Breaking2
Remove warn for Releases and Search APIs.
warn
Removes spec files from gemspec to fix installation on Windows.

Generated by DepDelta from published Ruby source. Not mixed with prose notes.

  • removed: module Faraday
  • removed: static method Octokit.new(_ = …)
  • added: const URI.TBLDECWWWCOMP_
  • added: const URI.TBLENCWWWCOMP_
  • added: module URI
  • added: static method Octokit.client()
  • added: static method URI.decode_www_form_component(_, _ = …)
  • added: static method URI.encode_www_form_component(_)
  • removed: class RaiseOctokitError < Response::Middleware
  • removed: const RaiseOctokitError.ERROR_MAP
  • removed: method RaiseOctokitError.on_complete(_)
  • removed: const Configuration.DEFAULT_ADAPTER
  • removed: const Configuration.DEFAULT_API_ENDPOINT
  • removed: const Configuration.DEFAULT_API_VERSION
  • removed: const Configuration.DEFAULT_AUTO_TRAVERSAL
  • removed: const Configuration.DEFAULT_STATUS_API_ENDPOINT
  • removed: const Configuration.DEFAULT_USER_AGENT
  • removed: const Configuration.DEFAULT_WEB_ENDPOINT
  • removed: const Configuration.VALID_OPTIONS_KEYS
  • removed: method Authentication.authenticated?()
  • removed: method Authentication.authentication()
  • removed: method Authentication.login_and_password_from_netrc(_ = …)
  • removed: method Authentication.oauthed?()
  • removed: method Authentication.unauthed_rate_limit_params()
  • removed: method Authentication.unauthed_rate_limited?()
  • removed: method Configuration.configure()
  • removed: method Configuration.faraday_config()
  • removed: method Configuration.options()
  • removed: method Configuration.reset()
  • removed: method Error.response_body()
  • removed: method Request.delete(_, _ = …)
  • removed: method Request.get(_, _ = …)
  • removed: method Request.patch(_, _ = …)
  • removed: method Request.post(_, _ = …)
  • removed: method Request.put(_, _ = …)
  • removed: module Configuration
  • removed: module Connection
  • removed: module Request
  • removed: property Client.VALID_OPTIONS_KEYS: accessor
  • removed: set Configuration.api_endpoint(_)
  • removed: set Configuration.web_endpoint(_)
  • changed: class BadGateway < Error → class BadGateway < ServerError
  • changed: class BadRequest < Error → class BadRequest < ClientError
  • changed: class Forbidden < Error → class Forbidden < ClientError
  • changed: class InternalServerError < Error → class InternalServerError < ServerError
  • changed: class NotAcceptable < Error → class NotAcceptable < ClientError
  • changed: class NotFound < Error → class NotFound < ClientError
  • changed: class NotImplemented < Error → class NotImplemented < ServerError
  • changed: class ServiceUnavailable < Error → class ServiceUnavailable < ServerError
  • changed: class Unauthorized < Error → class Unauthorized < ClientError
  • changed: class UnprocessableEntity < Error → class UnprocessableEntity < ClientError
  • added: class Arguments < Array
  • added: class ClientError < Error
  • added: class Conflict < ClientError
  • added: class MissingContentType < ArgumentError
  • added: class OneTimePasswordRequired < ClientError
  • added: class RateLimit < Struct.new :limit, :remaining, :resets_at, :resets_in
  • added: class RepoArguments < Arguments
  • added: class ServerError < Error
  • added: class TooManyLoginAttempts < Forbidden
  • added: class TooManyRequests < Forbidden
  • added: class UnsupportedMediaType < ClientError
  • added: const Default.API_ENDPOINT
  • added: const Default.MEDIA_TYPE
  • added: const Default.RACK_BUILDER_CLASS
  • added: const Default.USER_AGENT
  • added: const Default.WEB_ENDPOINT
  • added: const OneTimePasswordRequired.OTP_DELIVERY_PATTERN
  • added: constructor Arguments(_)
  • added: constructor RepoArguments(_)
  • added: method Authentication.application_authenticated?()
  • added: method Authentication.basic_authenticated?()
  • added: method Authentication.token_authenticated?()
  • added: method Authentication.user_authenticated?()
  • added: method Client.agent()
  • added: method Client.authorize_url(*)
  • added: method Client.delete(_, _ = …)
  • added: method Client.get(_, _ = …)
  • added: method Client.head(_, _ = …)
  • added: method Client.inspect()
  • added: method Client.last_response()
  • added: method Client.paginate(_, _ = …)
  • added: method Client.patch(_, _ = …)
  • added: method Client.post(_, _ = …)
  • added: method Client.put(_, _ = …)
  • added: method Client.root()
  • added: method Client.same_options?(_)
  • added: method Configurable.api_endpoint()
  • added: method Configurable.configure()
  • added: method Configurable.login()
  • added: method Configurable.netrc?()
  • added: method Configurable.reset!()
  • added: method Configurable.setup()
  • added: method Configurable.web_endpoint()
  • added: method Error.documentation_url()
  • added: method Error.errors()
  • added: method OneTimePasswordRequired.password_delivery()
  • added: module Configurable
  • added: module Default
  • added: module Response
  • added: property Arguments.options: reader
  • added: property Configurable.access_token: accessor
  • added: property Configurable.api_endpoint: writer
  • added: property Configurable.auto_paginate: accessor
  • added: property Configurable.client_id: accessor
  • added: property Configurable.client_secret: accessor
  • added: property Configurable.connection_options: accessor
  • added: property Configurable.default_media_type: accessor
  • added: property Configurable.login: writer
  • added: property Configurable.middleware: accessor
  • added: property Configurable.netrc: accessor
  • added: property Configurable.netrc_file: accessor
  • added: property Configurable.password: writer
  • added: property Configurable.per_page: accessor
  • added: property Configurable.proxy: accessor
  • added: property Configurable.user_agent: accessor
  • added: property Configurable.web_endpoint: writer
  • added: property RepoArguments.repo: reader
  • added: property Repository.owner: accessor
  • added: static method Configurable.keys()
  • added: static method Default.access_token()
  • added: static method Default.api_endpoint()
  • added: static method Default.auto_paginate()
  • added: static method Default.client_id()
  • added: static method Default.client_secret()
  • added: static method Default.connection_options()
  • added: static method Default.default_media_type()
  • added: static method Default.login()
  • added: static method Default.middleware()
  • added: static method Default.netrc()
  • added: static method Default.netrc_file()
  • added: static method Default.options()
  • added: static method Default.password()
  • added: static method Default.per_page()
  • added: static method Default.proxy()
  • added: static method Default.user_agent()
  • added: static method Default.web_endpoint()
  • added: static method Error.error_for_401(_)
  • added: static method Error.error_for_403(_)
  • added: static method Error.from_response(_)
  • added: static method OneTimePasswordRequired.required_header(_)
  • added: static method RateLimit.from_response(_)
  • removed: method GitHub.github_meta(_ = …)
  • removed: method Issues.issue_event(_, _, _ = …)
  • removed: method Issues.issue_events(_, _, _ = …)
  • removed: method Issues.search_issues(_, _, _ = …, _ = …)
  • removed: method Pulls.create_pull_comment(_, _, _, _, _, _, _ = …)
  • removed: method Pulls.create_pull_reply(_, _, _, _, _ = …)
  • removed: method Pulls.create_pull_request(_, _, _, _, _, _ = …)
  • removed: method Pulls.create_pull_request_comment(_, _, _, _, _, _, _ = …)
  • removed: method Pulls.create_pull_request_comment_reply(_, _, _, _, _ = …)
  • removed: method Pulls.create_pull_request_for_issue(_, _, _, _, _ = …)
  • removed: method Pulls.create_review_reply(_, _, _, _, _ = …)
  • removed: method Pulls.create_view_comment(_, _, _, _, _, _, _ = …)
  • removed: method Pulls.delete_pull_comment(_, _, _ = …)
  • removed: method Pulls.delete_pull_request_comment(_, _, _ = …)
  • removed: method Pulls.delete_review_comment(_, _, _ = …)
  • removed: method Pulls.merge_pull_request(_, _, _ = …, _ = …)
  • removed: method Pulls.pull(_, _, _ = …)
  • removed: method Pulls.pull_comment(_, _, _ = …)
  • removed: method Pulls.pull_comments(_, _, _ = …)
  • removed: method Pulls.pull_commits(_, _, _ = …)
  • removed: method Pulls.pull_files(_, _, _ = …)
  • removed: method Pulls.pull_merged?(_, _, _ = …)
  • removed: method Pulls.pull_request(_, _, _ = …)
  • removed: method Pulls.pull_request_comment(_, _, _ = …)
  • removed: method Pulls.pull_request_comments(_, _, _ = …)
  • removed: method Pulls.pull_request_commits(_, _, _ = …)
  • removed: method Pulls.pull_request_files(_, _, _ = …)
  • removed: method Pulls.pull_request_merged?(_, _, _ = …)
  • removed: method Pulls.pull_requests(_, _ = …, _ = …)
  • removed: method Pulls.pull_requests_comments(_, _ = …)
  • removed: method Pulls.pulls(_, _ = …, _ = …)
  • removed: method Pulls.pulls_comments(_, _ = …)
  • removed: method Pulls.review_comment(_, _, _ = …)
  • removed: method Pulls.review_comments(_, _, _ = …)
  • removed: method Pulls.reviews_comments(_, _ = …)
  • removed: method Pulls.update_pull_comment(_, _, _, _ = …)
  • removed: method Pulls.update_pull_request(_, _, _ = …, _ = …, _ = …, _ = …)
  • removed: method Pulls.update_pull_request_comment(_, _, _, _ = …)
  • removed: method Pulls.update_review_comment(_, _, _, _ = …)
  • removed: method Repositories.repo_issue_events(_, _ = …)
  • removed: method Repositories.repository_issue_events(_, _ = …)
  • removed: method Repositories.search_repos(_, _ = …)
  • removed: method Repositories.search_repositories(_, _ = …)
  • removed: method Statuses.github_status()
  • removed: method Statuses.github_status_last_message()
  • removed: method Statuses.github_status_messages()
  • removed: method Users.access_token(_, _, _, _ = …)
  • removed: method Users.search_users(_, _ = …)
  • removed: module GitHub
  • removed: module Pulls
  • changed: method Commits.commits(_, _ = …, _ = …) → method Commits.commits(*)
  • changed: method Commits.commits_before(_, _, _ = …, _ = …) → method Commits.commits_before(*)
  • changed: method Commits.commits_between(_, _, _, _ = …, _ = …) → method Commits.commits_between(*)
  • changed: method Commits.commits_on(_, _, _ = …, _ = …) → method Commits.commits_on(*)
  • changed: method Commits.commits_since(_, _, _ = …, _ = …) → method Commits.commits_since(*)
  • changed: method Commits.list_commits(_, _ = …, _ = …) → method Commits.list_commits(*)
  • changed: method Downloads.delete_download(_, _) → method Downloads.delete_download(_, _, _ = …)
  • changed: method Emojis.emojis() → method Emojis.emojis(_ = …)
  • changed: method Say.octocat(_ = …) → method Say.octocat(_ = …, _ = …)
  • changed: method Say.say(_ = …) → method Say.say(_ = …, _ = …)
  • changed: method Stats.code_frequency_stats(_) → method Stats.code_frequency_stats(_, _ = …)
  • changed: method Stats.commit_activity_stats(_) → method Stats.commit_activity_stats(_, _ = …)
  • changed: method Stats.contributor_stats(_) → method Stats.contributor_stats(_, _ = …)
  • changed: method Stats.contributors_stats(_) → method Stats.contributors_stats(_, _ = …)
  • changed: method Stats.participation_stats(_) → method Stats.participation_stats(_, _ = …)
  • changed: method Stats.punch_card(_) → method Stats.punch_card(_, _ = …)
  • changed: method Stats.punch_card_stats(_) → method Stats.punch_card_stats(_, _ = …)
  • changed: method Users.remove_email(_, _ = …) → method Users.remove_email(_)
  • changed: method Users.starred?(_, _, _ = …) → method Users.starred?(*)
  • changed: method Users.user(_ = …) → method Users.user(_ = …, _ = …)
  • added: class CONVENIENCE_HEADERS < Set.new
  • added: const ServiceStatus.STATUS_ROOT
  • added: method CommitComments.commit_comment(_, _, _ = …)
  • added: method CommitComments.commit_comments(_, _, _ = …)
  • added: method CommitComments.create_commit_comment(_, _, _, _ = …, _ = …, _ = …, _ = …)
  • added: method CommitComments.delete_commit_comment(_, _, _ = …)
  • added: method CommitComments.list_commit_comments(_, _ = …)
  • added: method CommitComments.update_commit_comment(_, _, _, _ = …)
  • added: method Commits.git_commit(_, _, _ = …)
  • added: method Events.issue_event(_, _, _ = …)
  • added: method Events.issue_events(_, _, _ = …)
  • added: method Events.repo_issue_events(_, _ = …)
  • added: method Events.repository_issue_events(_, _ = …)
  • added: method Feeds.feed(_, _ = …)
  • added: method Feeds.feeds()
  • added: method Hooks.available_hooks(_ = …)
  • added: method LegacySearch.legacy_search_issues(_, _, _ = …, _ = …)
  • added: method LegacySearch.legacy_search_repositories(_, _ = …)
  • added: method LegacySearch.legacy_search_users(_, _ = …)
  • added: method Meta.github_meta(_ = …)
  • added: method Meta.meta(_ = …)
  • added: method Organizations.org_public_members(_, _ = …)
  • added: method Organizations.organization_public_members(_, _ = …)
  • added: method Organizations.team_repo?(_, _, _ = …)
  • added: method Organizations.team_repository?(_, _, _ = …)
  • added: method Organizations.user_teams(_ = …)
  • added: method PubSubHubbub.subscribe_service_hook(_, _, _ = …)
  • added: method PubSubHubbub.unsubscribe_service_hook(_, _)
  • added: method PullRequests.close_pull_request(_, _, _ = …)
  • added: method PullRequests.create_pull_comment(_, _, _, _, _, _, _ = …)
  • added: method PullRequests.create_pull_reply(_, _, _, _, _ = …)
  • added: method PullRequests.create_pull_request(_, _, _, _, _, _ = …)
  • added: method PullRequests.create_pull_request_comment(_, _, _, _, _, _, _ = …)
  • added: method PullRequests.create_pull_request_comment_reply(_, _, _, _, _ = …)
  • added: method PullRequests.create_pull_request_for_issue(_, _, _, _, _ = …)
  • added: method PullRequests.create_review_reply(_, _, _, _, _ = …)
  • added: method PullRequests.create_view_comment(_, _, _, _, _, _, _ = …)
  • added: method PullRequests.delete_pull_comment(_, _, _ = …)
  • added: method PullRequests.delete_pull_request_comment(_, _, _ = …)
  • added: method PullRequests.delete_review_comment(_, _, _ = …)
  • added: method PullRequests.merge_pull_request(_, _, _ = …, _ = …)
  • added: method PullRequests.pull(_, _, _ = …)
  • added: method PullRequests.pull_comment(_, _, _ = …)
  • added: method PullRequests.pull_comments(_, _, _ = …)
  • added: method PullRequests.pull_commits(_, _, _ = …)
  • added: method PullRequests.pull_files(_, _, _ = …)
  • added: method PullRequests.pull_merged?(_, _, _ = …)
  • added: method PullRequests.pull_request(_, _, _ = …)
  • added: method PullRequests.pull_request_comment(_, _, _ = …)
  • added: method PullRequests.pull_request_comments(_, _, _ = …)
  • added: method PullRequests.pull_request_commits(_, _, _ = …)
  • added: method PullRequests.pull_request_files(_, _, _ = …)
  • added: method PullRequests.pull_request_merged?(_, _, _ = …)
  • added: method PullRequests.pull_requests(_, _ = …, _ = …)
  • added: method PullRequests.pull_requests_comments(_, _ = …)
  • added: method PullRequests.pulls(_, _ = …, _ = …)
  • added: method PullRequests.pulls_comments(_, _ = …)
  • added: method PullRequests.review_comment(_, _, _ = …)
  • added: method PullRequests.review_comments(_, _, _ = …)
  • added: method PullRequests.reviews_comments(_, _ = …)
  • added: method PullRequests.update_pull_comment(_, _, _, _ = …)
  • added: method PullRequests.update_pull_request(*)
  • added: method PullRequests.update_pull_request_comment(_, _, _, _ = …)
  • added: method PullRequests.update_review_comment(_, _, _, _ = …)
  • added: method RateLimit.rate_limit!(_ = …)
  • added: method RateLimit.rate_limit_remaining!(_ = …)
  • added: method RateLimit.ratelimit!(_ = …)
  • added: method RateLimit.ratelimit_remaining!(_ = …)
  • added: method Refs.delete_branch(_, _, _ = …)
  • added: method Refs.update_branch(_, _, _, _ = …, _ = …)
  • added: method Releases.create_release(_, _, _ = …)
  • added: method Releases.delete_release(_, _ = …)
  • added: method Releases.delete_release_asset(_, _ = …)
  • added: method Releases.edit_release(_, _ = …)
  • added: method Releases.edit_release_asset(_, _ = …)
  • added: method Releases.list_releases(_, _ = …)
  • added: method Releases.release(_, _ = …)
  • added: method Releases.release_asset(_, _ = …)
  • added: method Releases.release_assets(_, _ = …)
  • added: method Releases.releases(_, _ = …)
  • added: method Releases.update_release(_, _ = …)
  • added: method Releases.update_release_asset(_, _ = …)
  • added: method Releases.upload_asset(_, _, _ = …)
  • added: method Repositories.collaborator?(_, _, _ = …)
  • added: method Repositories.deploy_key(_, _, _ = …)
  • added: method Repositories.edit_deploy_key(_, _, _)
  • added: method Repositories.update_deploy_key(_, _, _)
  • added: method Search.search_code(_, _ = …)
  • added: method Search.search_issues(_, _ = …)
  • added: method Search.search_repos(_, _ = …)
  • added: method Search.search_repositories(_, _ = …)
  • added: method Search.search_users(_, _ = …)
  • added: method ServiceStatus.github_status()
  • added: method ServiceStatus.github_status_last_message()
  • added: method ServiceStatus.github_status_messages()
  • added: method Users.exchange_code_for_token(_, _ = …, _ = …, _ = …)
  • added: module CommitComments
  • added: module Feeds
  • added: module Hooks
  • added: module LegacySearch
  • added: module Meta
  • added: module PullRequests
  • added: module Releases
  • added: module Search
  • added: module ServiceStatus
  • removed: method ServiceHooks.subscribe_service_hook(_, _, _ = …)
  • removed: method ServiceHooks.unsubscribe_service_hook(_, _)
  • removed: module ServiceHooks
  • added: class MIDDLEWARE < RACK_BUILDER_CLASS.new
  • added: class FeedParser < Faraday::Response::Middleware
  • added: class RaiseError < Faraday::Response::Middleware