Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

FileUploader should surface why an upload failed instead of returning a bare bool

オープン
#5,732 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
dart
領域
backend

調査の方向性

Start by locating the FileUploader.upload entry point and tracing how it handles HTTP responses and exceptions. Review the upload behavior introduced by #5722 and the related context in #981; the issue does not identify files or tests. Done means callers can distinguish upload failure reasons while existing bool methods retain their behavior, with the proposed result-versus-exception design resolved.

索引モデルが issue の本文から書いたものです。

説明

Problem to Solve

FileUploader.upload returns Future<bool>. On failure it drops the HTTP status and swallows every exception, so app code cannot tell a file that was too large from an expired upload description or a network error.

Since #5722 the server answers every rejected upload with a distinct status and a reason, and S3 / GCS already return their own 4xx. See #981.

Proposal

Add a method that returns the outcome, e.g. FileUploadResult with success, statusCode, reason (the response body) and error, and keep the existing bool methods as wrappers. Alternatively throw a FileUploadException, but that changes behavior for existing callers.

Use Case

An app uploads a camera photo and wants to tell the user "file too large" and retry smaller, instead of a generic error.

主要言語
Dart
スター
3.3k
フォーク
382
平均マージ
2日 10時間
マージ済み PR(30日)
55

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

serverpod/serverpod のほかの issue

serverpod/serverpod の issue をすべて見る

似ている issue

Dart の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。