-
Notifications
You must be signed in to change notification settings - Fork 371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FIREBASE WARNING: wss:// URL used, but browser isn't known to support websockets. #1487
Comments
I found a few problems with this issue:
|
I have the same problem, but using Typescript: import * as functions from 'firebase-functions';
import {initializeApp, cert, getApp} from 'firebase-admin/app';
import {getAuth} from 'firebase-admin/auth';
import {getDatabase, getDatabaseWithUrl} from 'firebase-admin/database';
import {getStorage} from 'firebase-admin/storage';
import {getMessaging} from 'firebase-admin/messaging';
const config = functions.config().env;
const serviceAccount =
config.production === 'true'
? require('../service-credential-prod.json')
: require('../service-credential-staged.json');
initializeApp({
credential: cert(serviceAccount, ),
databaseURL: config.dbUrl,
});
export const app = getApp();
export const auth = getAuth();
export const db = getDatabase();
export const medicalDb = getDatabaseWithUrl(config.dbMedicalUrl);
export const storage = getStorage();
export const messaging = getMessaging(); "engines": {
"node": "14"
},
"main": "build/index.js",
"dependencies": {
"ajv": "^8.6.3",
"date-fns": "^2.25.0",
"firebase-admin": "^10.0.0",
"firebase-functions": "^3.16.0"
},
"devDependencies": {
"firebase-functions-test": "^0.3.3",
"firebase-tools": "^9.22.0",
"typescript": "^4.4.4"
}, |
Hi @arnav-kr, Thank you for reporting this issue! @jsdt I can reproduce the issue with the following dependencies.
Seems to be working fine with Any thoughts on what could be wrong? |
Some functions with the warning mentioned in this issue time out. Is this also your case? |
Same issue here +1 started last night, first error 2021-11-04 19:09:57 Seems to be working also with @firebase/database-compat@0.1.2 and firebase-admin@10.0.0. |
+1 same issue. i had to revert cloud run to an older revision to get it working And, using that same exact codebase on a new deploy (same cloud run environment)- i see this error as well.
|
I also faced the same issue with firebase-admin version |
Thank you for your patience! Our team has identified the root cause and currently working on a fix.
We will update here as soon as a fix is ready. |
I am getting the same error/warning when trying to change/access something in realtime database,I tried the above solution but they didn't work. |
I tried using this fix but it is still giving me the same warning/error. |
To force pin a specific version of "resolutions": {
"@firebase/database-compat": "0.1.2"
}, |
still getting the same warning/error |
This isn't working for me - even if it's added to |
@ayyysh04 @acoyfellow Did you rebuild your package-lock.json or yarn.lock after updating the package.json file? |
no,i only edited the package.json but didn't rebuild the package-lock.json. |
A simple way is to delete |
Yes, I did. I'm only seeing this in a Cloud Run environment. I've been unable to replicate in my local/dev environment. |
thanks it worked ,but for rebuilding the package lock file i have to use |
I also faced the problem with "@firebase/database-compat": "0.1.2" and firebase-admin@10.0.0 |
I'm using "firebase-admin": "9.7.0" and am also facing this issue. This seems to have suddenly started happening a couple days ago because it didn't happen last week. I didn't change / update any code and this bug started to happen. Is this the experience others have had too? |
Same issues here, with runtime "firebase-admin": "10.0.0",
"@firebase/database-compat": "0.1.2" |
I found the solution by using the resolutions for the database-compat and using yarn instead of npm. |
Found a solution, downgrading to |
This worked for me as well. |
@Feiyang1 why did you close this issue? Is this fixed now? I've just tried and it still doesn't seem to work. |
I've upgraded from |
This issue is now fixed in |
Do we still need to add database-compat as a dependency and in resollutions? |
No, you should be able to npm install with latest firebase deps
|
I can confirm that using the latest dependencies fixes the problem. |
Yesterday afternoon my functions were still throwing errors, but in the evening - without upgrading any packages or doing npm install - suddenly the functions started to work again. It seems like the fix was purely on firebase's end and does not require any updates. Can someone confirm this is the case? |
@JCsplash this is interesting. Once the functions are deployed it should not pull dependencies unless the function is re-created or updated. Do you by any chance have a mechanism to update the functions in your setup? |
constantly getting this message in the console and also unable to read and write to the database, I have another project running with the same version but that one is working correctly
logs:
dependencies:
code:
The text was updated successfully, but these errors were encountered: