Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't deploy Firebase functions (Failed to fetch Run service undefined)

Can't deploy Firebase functions. I have two project aliases, it's working fine for the first project (dev), but not for the second (prod).
Whenever I write firebase deploy --only functions I get the following message

i deploying functions
i  functions: ensuring required API cloudfunctions.googleapis.com is enabled...
i  functions: ensuring required API cloudbuild.googleapis.com is enabled...
i  artifactregistry: ensuring required API artifactregistry.googleapis.com is enabled...
+  functions: required API cloudbuild.googleapis.com is enabled
+  artifactregistry: required API artifactregistry.googleapis.com is enabled
+  functions: required API cloudfunctions.googleapis.com is enabled
i  functions: preparing codebase default for deployment
!  functions: package.json indicates an outdated version of firebase-functions. Please upgrade 
using npm install --save firebase-functions@latest in your functions directory.
!  functions: Please note that there will be breaking changes when you upgrade.
i  functions: Loaded environment variables from .env.prod.
!  functions: You are using an old version of firebase-functions SDK (3.15.7). Please update 
firebase-functions SDK to >=3.20.0
i  functions: preparing functions directory for uploading...
i  functions: packaged E:\FlutterProjects\pegasus\functions (218.61 KB) for uploading

Error: Failed to fetch Run service undefined
like image 691
Abdelrahman Avatar asked Aug 30 '25 14:08

Abdelrahman


1 Answers

I had the same issue and it was fixed for me when installed the latest firebase tools

npm install -g firebase-tools

like image 177
gfekri Avatar answered Sep 05 '25 09:09

gfekri