Repository navigation
Closed
SharezoneApp/sharezone-app
#1851Description
[REQUIRED] Environment info
firebase-tools: v14.0.0
Platform: ubuntu (github action)
[REQUIRED] Test case
npx firebase-tools@latest hosting:channel:deploy <channel> --only production --expires 7d --project <my-gcloud-project> --json
or
npx firebase-tools@latest deploy --only hosting:production --project <my-gcloud-project> --json
[REQUIRED] Steps to reproduce
- Next.js 15 project, pages router, use the command above
[REQUIRED] Expected behavior
Project deploys (still happens with v13.35.1)
[REQUIRED] Actual behavior
Initial run:
functions: No cleanup policy detected for repositories in us-central1. This may result in a small monthly bill as container images accumulate over time.
Error: Functions successfully deployed but could not set up cleanup policy in location us-central1. Pass the --force option to automatically set up a cleanup policy or run 'firebase functions:artifacts:setpolicy' to manually set up a cleanup policy.
After adjusting the settings:
[2025-03-27T20:18:38.469Z] Functions deploy failed.
[2025-03-27T20:18:38.470Z] ***
[2025-03-27T20:18:38.470Z] TypeError: Cannot read properties of null (reading 'length')
at Object.formatServiceAccount (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/gcp/proto.js:95:24)
at /home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/gcp/cloudfunctionsv2.js:196:122
at Object.convertIfPresent (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/gcp/proto.js:45:25)
at Object.functionFromEndpoint (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/gcp/cloudfunctionsv2.js:196:11)
at Fabricator.updateV2Function (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:384:35)
at Fabricator.updateEndpoint (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:155:24)
at /home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:110:71
at handle (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:89:23)
at Fabricator.applyChangeset (/home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:110:26)
at /home/runner/.npm/_npx/ba4f1959e38407b5/node_modules/firebase-tools/lib/deploy/functions/release/fabricator.js:69:40
Error: There was an error deploying functions
The process '/usr/local/bin/npx' failed with exit code 2
Reacted by Tyler Church, Roger Karlsen, ywc8891, JB Nizet, Alex Suzuki, OutdatedGuy, m-j-g, Alexander Sazanovich, Alexandre Paradis, Vamshi Rajarikam and 3 more
Activity
nvzoll commentedon Mar 27, 2025
Github action:
FirebaseExtended/action-hosting-deploy@v0LucianoGanga commentedon Mar 27, 2025
Hello! I'm having the exact same issue. And I imagine a lot more people will have it soon. By default my deploy script installs the latest firebase-tool package. I was fighting for the last 2 and a half hours with our code until I saw that the version 14 of this package was published ~3h ago.
The only breaking change I see in the release notes, related to cloud functions is this:
Anyhow, the fix that worked for us:
Thanks!
OutdatedGuy commentedon Mar 27, 2025
I think the issue is related to the above warning we used to get in
firebase-tools@13. For more informations.nvzoll commentedon Mar 27, 2025
@OutdatedGuy actually,
FirebaseExtended/action-hosting-deploy@v0I referred above does useGOOGLE_APPLICATION_CREDENTIALShttps://github.com/FirebaseExtended/action-hosting-deploy/blob/main/src/deploy.ts#L102
OutdatedGuy commentedon Mar 27, 2025
Can you give details about how your
FirebaseExtended/action-hosting-deploy@v0step is configured for actions?nvzoll commentedon Mar 27, 2025
Sure
haggbart commentedon Mar 27, 2025
I'm experiencing the exact same issue with Firebase CLI v14.0.0. The error occurs even on a fresh project.
Fix #8378 (comment) works
sufyankhatri commentedon Mar 27, 2025
I'm experiencing the exact same issue with Firebase CLI v14.0.0. The error occurs even on a fresh project
service-paradis commentedon Mar 28, 2025
I though I was crazy! Similar problems here with
FirebaseExtended/[email protected]which installed[email protected]ph360 commentedon Mar 28, 2025
When I deploy my functions since github show me the same error.
redian commentedon Mar 28, 2025
If you are using
FirebaseExtended/action-hosting-deploy@v0action and facing this issue, you can force firebase-tools version using thefirebaseToolsVersionconfig on the GA job.Something like this would work:
nvzoll commentedon Mar 28, 2025
@redian that's exactly what we did, thanks
taeold commentedon Mar 28, 2025
We've released a new version with a fix (14.0.1). Sorry for the confusion everyone.
nvzoll commentedon Mar 28, 2025
Thank you! I guess we'll stick to v13 for a week just in case...
ph360 commentedon Mar 29, 2025
Already is ready this version npm install -g [email protected]
fivecar commentedon Mar 29, 2025
@taeold : I still get this on 14.0.1, as recent as an hour ago running
npx firebase-tools deploy --token "$FIREBASE_TOKEN" --project MY-PROJ --only functionsin a GitHub action on the server. Are there potentially still cases where 14.0.1 still fails in this way?ph360 commentedon Mar 29, 2025
in github all ok with version 14.0.1
fivecar commentedon Mar 29, 2025
FWIW, 14.0.1 still not ok in my case.

ph360 commentedon Mar 29, 2025
ph360 commentedon Mar 29, 2025
I believe that message is for other reason. I see that see the policy
vamshiOmniWorks commentedon Mar 29, 2025
This worked for me
with:
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.xxx }}"
channelId: live
projectId: xxx
expires: 30d
firebaseToolsVersion: 13.35.1
gtp-1385 Bumping version up as there's a bug in firebase CLI 14.0.0 f…
Upgrade Firebase CLI to v14.1.0 (#1851)
nilsreichardt commentedon Apr 16, 2025
I am using Firebase CLI v14.1.0 and still get the error.
Here you see that I'm using v14.1.0
Error:
Logs: https://github.com/SharezoneApp/sharezone-app/actions/runs/14430710787/job/40465822063?pr=1849
Downgrade Firebase CLI from v14 to v13 (#1853)
revert to 13.35 firebase/firebase-tools#8378