Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Relax jwt dependency to support ruby-jwt 3.x (>= 2.0, < 4.0)

Đang mở
#215 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
72/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
ruby
Lĩnh vực
api

Hướng nghiên cứu

Bắt đầu từ runtime dependency trong gemspec và kiểm tra các entry point hiện có cho encode/decode, xác minh chữ ký webhook và việc tạo token nội bộ. Nới lỏng ràng buộc của jwt, sau đó xác minh SDK với jwt 2.10.x và 3.1.x, đồng thời bảo đảm các hành vi đó hoạt động trên cả hai phiên bản.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Summary

getstream-ruby 6.1.1 pins jwt (~> 2.0), which blocks applications from upgrading to ruby-jwt 3.x. Bundler cannot resolve a single bundle when the app (or other gems) require jwt 3.x.

Current behavior

From the published gem (6.1.1):

jwt (~> 2.0)   # resolves to 2.x only (e.g. 2.10.2)

Other common dependencies already allow jwt 3, e.g. googleauth uses jwt (>= 1.4, < 4.0). The blocker for a unified bundle is specifically getstream-ruby's upper bound.

Problem

  • We cannot bundle update jwt to 3.x while using getstream-ruby.
  • Ruby loads one jwt version per process; there is no supported way for the SDK to stay on 2.x while the host app uses 3.x.
  • Workarounds (forking the gemspec, hand-editing Gemfile.lock) are fragile and unsupported.

Use case

We use getstream-ruby for Stream Chat (API client, webhooks, user upsert) and also use jwt directly elsewhere in the app (user tokens, CDN auth, etc.). We want to upgrade to jwt 3.x for security/maintenance alignment with the rest of the ecosystem, without dropping the official SDK.

Requested change

Relax the runtime dependency, for example:

# gemspec
s.add_runtime_dependency "jwt", ">= 2.0", "< 4.0"

Then verify the SDK against jwt 2.10.x and 3.1.x (encode/decode, webhook signature verification, any internal token generation).

Environment

  • getstream-ruby: 6.1.1
  • Ruby: 3.x (Rails 7.2 app)
  • Current resolved jwt: 2.10.2 (due to ~> 2.0 constraint)
Ngôn ngữ chính
Ruby
Star
32
Fork
23
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của GetStream/stream-chat-ruby

Tất cả issue của GetStream/stream-chat-ruby

Issue tương tự

Thêm issue về Ruby

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.