Repository navigation
Closed
Labels
Description
[REQUIRED] Environment info
nodejs: 20.19.5
export FIREBASE_DATACONNECT_POSTGRESQL_STRING=postgres://localhost:5432/postgres?sslmode=disable
export DATA_CONNECT_EMULATOR_HOST='127.0.0.1:9399'
firebase-tools:
14.25.1 & 14.26.0
Platform:
MacOS
[REQUIRED] Test case
# UserProfile extends User with additional profile information and 2FA settings
type UserProfile @table(key: "uid") {
# Links to Firebase Auth UID - this is the primary key
uid: String! @default(expr: "auth.uid")
email: String! @col(dataType: "varchar(255)")
firstName: String @col(dataType: "varchar(50)")
lastName: String @col(dataType: "varchar(50)")
phoneNumber: String @col(dataType: "varchar(20)")
photoURL: String @col(dataType: "varchar(500)")
role: String @col(dataType: "varchar(50)")
# 2FA related fields
twoFactorEnabled: Boolean! @default(value: false)
twoFactorSecret: String @col(dataType: "varchar(32)") # Base32 encoded secret for authenticator apps
backupCodes: [String!] # Array of backup codes for 2FA recovery
# Profile metadata
createdAt: Timestamp! @default(expr: "request.time")
updatedAt: Timestamp! @default(expr: "request.time")
lastLoginAt: Timestamp
# User preferences
language: String @col(dataType: "varchar(10)") @default(value: "en")
timezone: String @col(dataType: "varchar(50)")
# Account status - 'pending' (not signed in yet), 'active', 'inactive', 'suspended'
status: String! @col(dataType: "varchar(20)") @default(value: "pending")
isDeleted: Boolean! @default(value: false)
}
# Get current user's profile based on their auth.uid
query GetUserProfile @auth(level: USER_EMAIL_VERIFIED) {
userProfile(key: { uid_expr: "auth.uid" }) {
uid
email
firstName
lastName
phoneNumber
photoURL
role
twoFactorEnabled
language
timezone
status
createdAt
updatedAt
lastLoginAt
}
}
import {
getUserProfile,
} from '@dataconnect/generated';
async getUserProfile(): Promise<GetUserProfileData> {
if (this.userProfileData) {
return this.userProfileData;
}
this.userProfileData = (await getUserProfile(this.dataConnect as any)).data;
return this.userProfileData;
}
on the emulators side when use firebase tools 14.25.1
I1122 11:33:21.301175 39652 engine.go:172] [/emulator/xxx-xxxon-development 6489] ExecuteGraphql : succeeded.
I1122 11:33:22.347075 39652 prepare.go:158] [operation "GetUserProfile" attempt 1] preparePlan succeeded
I1122 11:33:22.347103 39652 prepare.go:145] [operation "GetUserProfile" attempt 1] DBStats beforePrepare: sql.DBStats{MaxOpenConnections:1, OpenConnections:1, InUse:0, Idle:1, WaitCount:0, WaitDuration:0, MaxIdleClosed:0, MaxIdleTimeClosed:0, MaxLifetimeClosed:0}, afterPrepare: sql.DBStats{MaxOpenConnections:1, OpenConnections:1, InUse:0, Idle:1, WaitCount:0, WaitDuration:0, MaxIdleClosed:0, MaxIdleTimeClosed:0, MaxLifetimeClosed:0}
I1122 11:33:22.363611 39652 executor.go:92] [operation "GetUserProfile" attempt 1] DBStats beforeRun: sql.DBStats{MaxOpenConnections:1, OpenConnections:1, InUse:0, Idle:1, WaitCount:0, WaitDuration:0, MaxIdleClosed:0, MaxIdleTimeClosed:0, MaxLifetimeClosed:0}, afterRun: sql.DBStats{MaxOpenConnections:1, OpenConnections:1, InUse:0, Idle:1, WaitCount:0, WaitDuration:0, MaxIdleClosed:0, MaxIdleTimeClosed:0, MaxLifetimeClosed:0}
I1122 11:33:22.363677 39652 engine.go:172] [/emulator/xxx-xxxon-development 6489] ExecuteQuery GetUserProfile: succeeded. Connector: xxx-xxxon
And when update to firebase tools 14.26.0
I1122 11:47:11.653282 48808 engine.go:179] [/emulator/xxx-xxxon-development 7898] ExecuteGraphql : succeeded.
W1122 11:47:12.688665 48808 engine.go:177] [/emulator/xxx-xxxon-development 7898] ExecuteQuery GetUserProfile: failed with explicit status error: rpc error: code = Internal desc = internal error: unexpected internal error has occurred. Connector: xxx-xxxon
Auth: user of {"UID":"HAe54sikpSjT5bvmRyIAzWjPlGhM","Token":{"aud":"XXX-XXXon","auth_time":1763830031,"email":"[email protected]","email_verified":true,"exp":1763833631,"firebase":{"identities":{"email":["[email protected]"]},"sign_in_provider":"password"},"iat":1763830031,"iss":"https://securetoken.google.com/xxx-xxxon","name":"","picture":"","role":"admin","sub":"HAe54sikpSjT5bvmRyIAzWjPlGhM","user_id":"HAe54sikpSjT5bvmRyIAzWjPlGhM"}}
Status: rpc error: code = Internal desc = internal error: unexpected internal error has occurred
sources: xxx/mutations.gql [30226B] xxx/queries.gql [27779B]
[REQUIRED] Steps to reproduce
see above
run generated function getUserProfile from a browser and emulators can't finish the graphQl execution
[REQUIRED] Expected behavior
do not crush
[REQUIRED] Actual behavior
crushing
Activity
[-]emulators data-connect issue after upgrade 14.25.1 -> 14.26.0[/-][+]emulators, dataconnect, local postgres, graphql issue after upgrade 14.25.1 -> 14.26.0[/+]fredzqm commentedon Dec 2, 2025
@portah
Sorry to hear you are experiencing issues with the Data Connect emulator.
I tried to reproduce the bug in my mac, but couldn't get
GetUserProfileto fail. It could be something transient related to setup.While debugging this, I realized that we have been swallowing the underlying debug details in some cases. Let me fix that in future releases, hopefully the root cause will be apparent with extra information.
Thanks for reporting the bug!
fredzqm commentedon Dec 5, 2025
Let me know if the issue still persists~ If so, what logs are emitted in the new release~
Would be happy to look into them more~ Meanwhile, close this issue.
Glad that we found the "swallowed log" bug!
portah commentedon Jan 8, 2026
@fredzqm sorry did not get earlier to you. updated to the latest 15.2.0 and still can't execute graphql query, that were okey with 14.25.1
In the browser also not much:
portah commentedon Jan 21, 2026
Sorry for opening new issue.
I'm here to help to debug what is different between 14.25.1 and other versions.
fredzqm commentedon Jan 22, 2026
@portah
Sorry about the delay~
Based on bug you reported. I recently did some internal clean up and replaced "not supported" with more descriptive error messages.
Can you help check what's the behavior in the latest version? Last week at 15.3.1
Thanks a lot! Appreciate the eager to help!
portah commentedon Jan 23, 2026
Okey and now magic happened
% firebase --version
15.4.0
Everything works just fine. Will check with 15.3.1 out of curiosity.
Big magic: 15.3.1 also works fine
Then I went back into commits of 1, 2, 3 weeks ago all are working with the latest 15.4.0
fredzqm commentedon Jan 23, 2026
Sweet. Thanks for confirming!