Skip to content

Upgrade firebase-admin to v13 and firebase-functions to v6#293

Merged
bgoncal merged 2 commits intohome-assistant:mainfrom
rwarner:chore/upgrade-firebase-deps
Apr 28, 2026
Merged

Upgrade firebase-admin to v13 and firebase-functions to v6#293
bgoncal merged 2 commits intohome-assistant:mainfrom
rwarner:chore/upgrade-firebase-deps

Conversation

@rwarner
Copy link
Copy Markdown
Contributor

@rwarner rwarner commented Apr 23, 2026

Summary

  • Upgrades firebase-admin from ^12.1.0 to ^13.5.0 (resolves to 13.8.0)
  • Upgrades firebase-functions from ^5.0.1 to ^6.1.1 (resolves to 6.6.0)
  • Switches index.js to the firebase-functions/v1 entrypoint to maintain v1 API compatibility (functions.config(), functions.region(), functions.runWith())
  • Updates corresponding Jest mocks in tests

firebase-functions v6 is required as a peer dependency alongside firebase-admin v13 — v5 only supports firebase-admin ^11 || ^12. The v6 default export is the v2 API surface, so existing v1-based code uses the /v1 entrypoint.

This is a prerequisite for #278 which requires firebase-admin ^13.5.0 for the apns.liveActivityToken FCM field used by iOS Live Activities.

Test plan

  • Existing tests pass
  • Functions deploy successfully

🤖 Generated with Claude Code

firebase-admin v13.5.0 is required for the apns.liveActivityToken FCM
field. firebase-functions v6 is required as a peer dependency alongside
firebase-admin v13 (v5 only supports firebase-admin ^11 || ^12).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings April 23, 2026 14:39
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Upgrades Firebase Admin SDK and Firebase Functions dependencies in the functions/ package to unblock features requiring firebase-admin v13 (notably the apns.liveActivityToken field referenced by #278).

Changes:

  • Bump firebase-admin dependency to ^13.5.0.
  • Bump firebase-functions dependency to ^6.1.1 and refresh the lockfile resolution accordingly.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 3 comments.

File Description
functions/package.json Updates declared Firebase dependency ranges to Admin v13 and Functions v6.
functions/package-lock.json Updates the resolved dependency tree to versions compatible with the new Firebase dependency ranges.
Files not reviewed (1)
  • functions/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread functions/package.json
Comment thread functions/package-lock.json
Comment thread functions/package-lock.json
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.52%. Comparing base (0bcbca3) to head (87695ea).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #293   +/-   ##
=======================================
  Coverage   67.52%   67.52%           
=======================================
  Files          10       10           
  Lines         625      625           
  Branches      177      177           
=======================================
  Hits          422      422           
  Misses        158      158           
  Partials       45       45           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

firebase-functions v6 changed the default export to the v2 API surface.
The codebase uses v1-only APIs (functions.config(), functions.region(),
functions.runWith()), so switch to the firebase-functions/v1 entrypoint
to maintain compatibility without rewriting the existing function handlers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@rwarner rwarner requested a review from jpelgrom April 23, 2026 17:01
Copy link
Copy Markdown
Member

@jpelgrom jpelgrom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested originally as part of #278 and deployed again to confirm working. package-lock.json matches locally generated one.

@rwarner
Copy link
Copy Markdown
Contributor Author

rwarner commented Apr 28, 2026

Let me know if there's anything I can do beyond what's here. I think someone can merge it? Unless you guys aren't ready for that.

@bgoncal bgoncal merged commit 6c3d2b5 into home-assistant:main Apr 28, 2026
4 checks passed
@rwarner rwarner deleted the chore/upgrade-firebase-deps branch April 28, 2026 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants