If response content is NULL or text, no response is set to client

Đang mở
#196 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
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
c, r
Lĩnh vực
api, backend

Hướng nghiên cứu

Start by running the two startServer examples in the issue and trace how the call callback's return value is handled. Check the response path for NULL and plain-text results; done means both cases return an HTTP 500 response instead of leaving the client without a response, and the server does not crash.

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

Mô tả

In the examples below, when a request is made, there's simply no response. I think it should probably give a 500 response.

library(httpuv)
s1 <- startServer("127.0.0.1", 5000,
  list(
    call = function(req) NULL
  )
)

s2 <- startServer("127.0.0.1", 5001,
  list(
    call = function(req) "abc"
  )
)

I tested 1.3.6.1, and it has the same behavior. With 1.3.0, the R process crashes.

Ngôn ngữ chính
C
Star
252
Fork
87
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 rstudio/httpuv

Tất cả issue của rstudio/httpuv

Issue tương tự

Thêm issue về C

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.