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

[Report & Block] Map report response/error outcomes

Đang mở
#112 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
Nửa ngày
Mức phù hợp với người mới
45/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
dart, flutter, typescript
Lĩnh vực
backend, mobile

Hướng nghiên cứu

Start in lib/moderation/report_client.dart, where reportErrorMessage(int status, String? code) is to be added, and check the Supabase function handler it is modeled on. Confirm that prerequisite #34 is merged first, since this extends its file. Done means the status-to-message mapping in the steps passes test/moderation/report_client_dp_r01_2_test.dart, and flutter analyze is clean.

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

Mô tả

moderation

What to build

Turn reporting failures into safe messages students can act on. A received-report confirmation must appear only after the service accepts the report, not after a failed or limited request.

Files

  • lib/moderation/report_client.dart (extend the prerequisite’s file)
  • Starting example: supabase/functions/report/handler.ts
    Code to add or extend: String reportErrorMessage(int status,String? code).

Steps

  1. Map401→Sign in again.;403→Reports are unavailable for this account.;404→This content is unavailable.;429→Please wait before reporting again.;502/503→Reporting is temporarily unavailable.
  2. 400 self-report/invalid input yields readable validation error, unknown generic fallback.
  3. Keep form input on every failure; no raw secret/error body.

Example

429 does not claim receipt;201 only means an accepted report, not moderation action.

Check it works

In test/moderation/report_client_dp_r01_2_test.dart, check the example above and the failure or limit described in the steps. Run flutter test test/moderation/report_client_dp_r01_2_test.dart and flutter analyze.

Before starting

  • #34 — Send reports through DogPack report function

References

Assign yourself before starting, or comment to claim the issue. Project setup.

Ngôn ngữ chính
PLpgSQL
Star
0
Fork
0
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 DevDogsUGA/DogPack

Tất cả issue của DevDogsUGA/DogPack

Issue tương tự

Thêm issue về Backend & API Design

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.