Skip to content

[REQ][Ruby] Add support for faraday 2.x #12074

@ykitamura-mdsol

Description

@ykitamura-mdsol

Is your feature request related to a problem? Please describe.

Faraday 2.x is released: lostisland/faraday#1358

Describe the solution you'd like

Based on the UPGRADING guide, we need to make changes to the following files:

gemspec.mustache

Relax Faraday dependency and add s.add_runtime_dependency 'faraday-multipart'

{{#isFaraday}}
s.add_runtime_dependency 'faraday', '~> 1.0', '>= 1.0.1'
{{/isFaraday}}

api_client.mustache

Add require 'faraday/multipart' if Gem::Version.new(Faraday::VERSION) >= Gem::Version.new('2.0')

{{#isFaraday}}
require 'faraday'
{{/isFaraday}}

api_client_faraday_partial.mustache

Handle basic_auth like this to support both Faraday 1.x and 2.x.

I'm going to work on this if no one has already started.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions