[Bug] Errors fail to return all data from error object.
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- cpp, javascript
- Ambito
- authentication
Direzione di ricerca
Inizia con il progetto di esempio Firebase C++ Auth per Windows e riproduci l'accesso con email/password rispetto alla funzione beforeUserSignedIn distribuita in min-viable-blocking.js. Confronta l'errore di Windows con il comportamento descritto per Android, iOS e web, e ispeziona i C++ quickstarts se necessario. Il lavoro è completato quando il client Windows può accedere all'errore failed-precondition della funzione di blocco e ai relativi dati aggiuntivi.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
[REQUIRED] Please fill in the following fields:
- Pre-built SDK from the website or open-source from this repo: _____
- Firebase C++ SDK version: 13.0.0 (assuming flutterfire uses the latest version)
- Problematic Firebase Component: Auth (Auth, Database, etc.)
- Other Firebase Components in use: Firestore (Auth, Database, etc.)
- Platform you are using the C++ SDK on: Windows (Mac, Windows, or Linux)
- Platform you are targeting: Windows (iOS, Android, and/or desktop)
[REQUIRED] Please describe the issue here:
(Please list the full steps to reproduce the issue. Include device logs, Unity logs, and stack traces if available.)
When signing in with email and password, my project has a 'beforeUserSignIn' blocking function running before logging in that throws an HttpsError. On android/ios/web, throwing an HttpsError within the blocking function can be detected by the client attempting login, with it able to read the contents (i.e. that the HttpsError is 'failed-precondition').
On Windows, errors from the blocking function are clobbered into 'unknown-error' and any extra data in the HttpError is inaccessible.
Login when the blocking function immediately returns without error works as intended.
It may be because the firebase C++ SDK doesn’t provide any field or method for accessing additional error details. I would probably need a way to return the entire object back.
(Was redirected from https://github.com/firebase/flutterfire/issues/17592, so if I need to give you any more information please let me know (or if this issue isn't relevant to this project))
Steps to reproduce:
Have you been able to reproduce this issue with just the Firebase C++ quickstarts ?
What's the issue repro rate? (eg 100%, 1/5 etc)
I have not attempted this yet.
What happened? How can we make the problem occur?
This could be a description, log/console output, etc.
Using the example project on Windows, sign in with email and password whilst a blocking function has been configured and deployed.
You may need to configure the function in the Firebase Console at Authentication > Settings > Blocking Functions.
I was able to replicate the issue with this cloud function deployed.
If you have a downloadable sample project that reproduces the bug you're reporting, you will
likely receive a faster response on your issue.
Relevant Code:
min-viable-blocking.js
import { HttpsError, beforeUserSignedIn } from "firebase-functions/v2/identity";
import { setGlobalOptions } from 'firebase-functions/v2'
const functionConfig = {
region: "asia-south1",
concurrency: 60,
minInstances: 0,
maxInstances: 10,
cpu: 1.0,
};
setGlobalOptions(functionConfig);
export const beforeSignIn = beforeUserSignedIn( (event) => {
throw new HttpsError(
"failed-precondition",
"error message for the client to read",
{'usefulData': 'drink some water'} //<-- this is the data i want to access from the error object
);
});
- Lingua principale
- C++
- Stelle
- 326
- Fork
- 138
- Merge medio
- 2g 16h
- PR unite (30g)
- 3
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di firebase/firebase-cpp-sdk
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
firebase/firebase-cpp-sdk#1905 · 2 commenti ·
-
api: firestore
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
firebase/firebase-cpp-sdk#1920 · 3 commenti ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 70/100
firebase/firebase-cpp-sdk#1904 · 1 commento ·
-
new type: question
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
firebase/firebase-cpp-sdk#1892 · 1 commento ·
-
nightly-testing
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
firebase/firebase-cpp-sdk#1859 ·
Tutte le issue di firebase/firebase-cpp-sdk
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
ros2/message_filters#338 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
subsurface/subsurface#4984 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
flutter-webrtc/flutter-webrtc#2206 ·
-
litertlm-android AAR ships no consumer ProGuard rules → "mid == null" SIGABRT in minified apps Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
google-ai-edge/LiteRT-LM#3739 ·