SetContentType middleware breaks Content-Type detection for requests
まだ誰も着手していません。
評価
調査の方向性
まず SetContentType、GetRequestContentType、DefaultDecoder の場所を特定し、共有コンテキストキーが request の Content-Type 検出のためにどのように読み取られているかを追跡します。既存の middleware と decoder の動作を確認し、焦点を絞った回帰テストの場所を特定して、issue で提案されているコンテキスト状態の分離を検討します。response の処理が request の検出に干渉しなくなれば完了です。
索引モデルが issue の本文から書いたものです。
説明
The documentation for SetContentType only mentions responses and says nothing of requests:
SetContentType is a middleware that forces response Content-Type.
However, this breaks Content-Type detection for requests in the DefaultDecoder because SetContentType and GetRequestContentType share the same context key.
It's not obvious to me why GetRequestContentType even looks at the context, as that seems to betray the function name. But if that behavior is going to stay, I suggest using a separate context key so that SetContentType does not interfere.
- 主要言語
- Go
- スター
- 340
- フォーク
- 69
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
go-chi/render のほかの issue
-
Render and Bind panic on unexported nested interface fields対応中かも @duongynhi000005-oss が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
Channel response appends JSON null after context timeout対応中かも @awais-ur-rehman が 1 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
-
難易度 5/5 1週間以上 初心者へのやさしさ 10/100
-
Any concern render.JSON() can leak internal errors to outside?対応中かも @team-humaki が 50 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 30/100
似ている issue
-
area/docs framework/hugo help wanted language/markdown
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
clawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:other issue-rating: 🦞 diamond lobster no-stale P2
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
openclaw/crabbox#3060 · コメント 1 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
kubeflow/semantic-operator#52 ·
メンテナーはふだん 10 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
enhancement help wanted
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
PramodBasavarajMenasi/siftwise#52 ·
メンテナーはふだん 1 日以内に返信