firebase / firebase/firebase-admin-node
[FR] Include raw HTTPS responses in errors
- 主要言語
- TypeScript
- スター
- 1.7k
- フォーク
- 419
- 平均マージ
- 3日 10時間
- マージ済み PR(30日)
- 16
説明
**Is your feature request related to a problem? Please describe.**
I am converting APNs tokens to Firebase registration tokens ("FRTs") on-the-fly in a backend push service. Many converted FRTs fail with the error `messaging/invalid-argument`, with no clues of what's going on. Through some fairly time consuming debugging using the Google API Explorer I was able to get some more details on what was happening, but it's a frustrating process.
**Describe the solution you'd like**
Provide the raw HTTPS response in the thrown `FirebaseMessagingError`. The python SDK [has this](https://firebase.google.com/docs/reference/admin/python/firebase_admin.exceptions), so I think it makes sense that the Node one would too. It would be especially helpful in cases like this where the error code doesn't make much sense.
**Describe alternatives you've considered**
The only real option to attain more info would be to use the REST API directly, but that feels a little over the top.
**Additional context**
There's definitely a possibility that the server or app is misconfigured somehow. Fixing the error is not the point here, though!
コントリビューションガイド
調査の方向性
まず Node.js SDK 内の FirebaseMessagingError と messaging/invalid-argument パスを追跡し、次に issue にリンクされている Python SDK の例外リファレンスと比較します。現在 HTTPS レスポンスがどのように処理されているかを確認し、Firebase Messaging エラーを対象とするテストを特定します。スローされたエラーが既存のエラーコードやメッセージを不明瞭にすることなく、HTTPS レスポンスの生データを公開すれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- firebase, nodejs, typescript
- 領域
- api, backend
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100