Skip to content

json dependency capped at ~> 2.1 blocks json 3.x #148

Description

@denysivanov

The gemspec caps the json dependency at ~> 2.1:

s.add_runtime_dependency 'json', '~> 2.1', '>= 2.1.0'

~> 2.1 means < 3.0, so any bundle containing docusign_esign is pinned to json 2.x. json 3.0.0 shipped on 2026-09-07 (3.0.2 as of today), and this is currently the only gem in our tree holding us back — sidekiq, rubocop and the rest all declare open-ended >= 2.x constraints.

The cap looks unnecessary. The gem's entire use of the json library is one call in lib/docusign_esign/client/api_client.rb:169:

data = JSON.parse("[#{body}]", :symbolize_names => true)[0]

That works unchanged on json 3.0.2:

json version: 3.0.2
parsed ok: {envelopeId: "abc-123", status: "sent", recipients: {signers: [{email: "a@b.com"}]}}
keys are symbols: true

Could the upper bound be dropped in favour of >= 2.1.0? This is the same problem as #13 (json ~> 1.8 blocking json 2.x), which was fixed in v1.0.2 by moving the cap up to ~> 2.1 — removing the bound rather than bumping it again would stop it recurring on json 4.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions