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

Failed to use Openapi SDK in Actix-web async handler

Đang mở
#2 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ó
4/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
rust
Lĩnh vực
api

Hướng nghiên cứu

Start by reading the SDK client’s async methods and the Actix-web handler example in the issue. Reproduce the “future cannot be sent between threads safely” error with the shown get_user call, then identify which SDK future or value triggers it. Done means documenting or implementing a compatible integration and confirming the example compiles.

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

Mô tả

Description:
Trying to call the Openapi SDK client from an Actix-web async handler:

async fn get_user() -> impl Responder {
    let client = openapi_sdk::Client::new("API_KEY");
    let user = client.get_user(123).await.unwrap();
    HttpResponse::Ok().json(user)
}

Getting: error: future cannot be sent between threads safely.
Probably related to Actix’s runtime. How should we properly integrate Openapi SDK async calls with Actix?

Ngôn ngữ chính
Rust
Star
29
Fork
3
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 openapi/openapi-rust-sdk

Tất cả issue của openapi/openapi-rust-sdk

Issue tương tự

Thêm issue về Rust

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.