Skip to content

[pull] master from firebase:master#1

Open
pull[bot] wants to merge 114 commits intomajacQ:masterfrom
firebase:master
Open

[pull] master from firebase:master#1
pull[bot] wants to merge 114 commits intomajacQ:masterfrom
firebase:master

Conversation

@pull
Copy link

@pull pull bot commented Jun 19, 2021

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

@atomist atomist bot added auto-branch-delete:on-close Delete branch when pull request gets closed auto-merge-method:merge Auto-merge with merge commit auto-merge:on-bpr-success Auto-merge on passed branch protection rule labels Jun 19, 2021
@pull pull bot added ⤵️ pull and removed auto-branch-delete:on-close Delete branch when pull request gets closed auto-merge-method:merge Auto-merge with merge commit auto-merge:on-bpr-success Auto-merge on passed branch protection rule labels Jun 19, 2021
hiranya911 and others added 22 commits June 25, 2021 12:05
…558)

* fix(fcm): FA workaround for the concurrency issues in googleapiclient

* fix: Added test case
* fix(auth): check if user disabled on check_revoked

When `verify_session_cookie` or `verify_id_token` is called with
`check_revoked` set to `True` we should also check if the user is
disabled.

If disabled the `UserDisabledError` is raised.
The `firebase_admin.auth.list_users().iterate_all()` method uses a sub-class
of PageIterator, which happens to access the .items computed property more
than once for every page of results. This has been changed so we take care
not to access the `self.items` property more than once per page.

This is a lot faster.
* [add] ability to delete provider in auth

* [fix] pylint

* [fix] tests

* [fix] tests

* fix comments

* fix tests

* fix lint

* [fix] address comments
* fix: Fixing a broken integration test

* fix: Fixing another typo
Bumped version to 5.1.0
Provides an option for developers to specify the OAuth response type for their OIDC provider (either one of these can be set:):
- id_token
- code (if set, must also set the client secret)

RELEASE NOTES: Added support for configuring the authorization code flow for OIDC providers.
Co-authored-by: Ryan Kohler <ryankohler@google.com>
* Add delayed response message for holidays

* Remove the table from the markdown
* chore: Update Node.js version in CI workflow

- Firebase CLI dropped support for Node.js 10. Updating the Node.js version to 12 for emulator test setup.

* Update ci.yml

Update the version to current LTS 16
* feat(firestore): Expose Async Firestore Client. (#621)

* feat(firestore): Expose Async Firestore Client.

* fix: Added type hints and defintion wording changes

* fix: removed future annotations until Python 3.6 is depreciated.

* fix: added missed type and clarifying comment for Python 3.6 type hinting.

* fix: lint

* Adds integration tests for the Async Firstore module (#623)

* Add integration tests for async firstore module

* fix: made pytest Python 3.6 compatible

* Trigger Integration Tests

* fix: correct copyright year

* Add code snippets for firestore modules. (#628)

* Add code snippets for firestore modules.

* fix: clarified snippet names and fixed newline.

* fix: Removed var tags. These won't work as I intended it to since html is escaped when using includecode.

Co-authored-by: Lahiru Maramba <llahiru@gmail.com>
aiueo-1234 and others added 28 commits January 13, 2025 15:15
* chore: Add unit tests for `Reference.listen()`

* Integration test for rtdb listeners

* fix lint
* feat(fcm): Support `proxy` field in FCM `AndroidNotification`

* fix lint

* fix: Update `proxy` and `visibility` doc string with TW suggestion
…873)

Updated the 'Supported Python Versions' section in README.md to indicate that Python 3.7 and Python 3.8 support is deprecated, advising users to use Python 3.9 or higher.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
… tests (#881)

* Fix(tests): Use mock time for consistent token generation and verification tests

Patches time.time and google.auth.jwt._helpers.utcnow to use a fixed
timestamp (MOCK_CURRENT_TIME) throughout tests/test_token_gen.py.

This addresses test flakiness and inconsistencies by ensuring that:
1. Tokens and cookies are generated with predictable `iat` and `exp` claims
   based on MOCK_CURRENT_TIME.
2. The verification logic within the Firebase Admin SDK and the underlying
   google-auth library also uses MOCK_CURRENT_TIME.

Helper functions _get_id_token and _get_session_cookie were updated to
default to using MOCK_CURRENT_TIME for their internal time calculations,
simplifying test code.

Relevant fixtures and token definitions were updated to rely on these
new defaults and the fixed timestamp.

The setup_method in TestVerifyIdToken, TestVerifySessionCookie,
TestCertificateCaching, and TestCertificateFetchTimeout now mock
time.time and google.auth.jwt._helpers.utcnow to ensure that all
time-sensitive operations during testing use the MOCK_CURRENT_TIME.

* Fix(tests): Apply time mocking to test_tenant_mgt.py

Extends the time mocking strategy (using a fixed MOCK_CURRENT_TIME)
to tests in `tests/test_tenant_mgt.py` to ensure consistency with
changes previously made in `tests/test_token_gen.py`.

Specifically:
- Imported `MOCK_CURRENT_TIME` from `tests.test_token_gen`.
- Added `setup_method` (and `teardown_method`) to the
  `TestVerifyIdToken` and `TestCreateCustomToken` classes.
- These setup methods patch `time.time` and
  `google.auth.jwt._helpers.utcnow` to return `MOCK_CURRENT_TIME`
  (or its datetime equivalent).

This ensures that token generation (for custom tokens) and token
verification within `test_tenant_mgt.py` align with the mocked
timeline, preventing potential flakiness or failures due to
time inconsistencies. All tests in `test_tenant_mgt.py` pass
with these changes.

* fix lint and refactor

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
* Add live_activity_token to `APNSConfig`, allowing you to specify this token for APNS messages.

This change introduces:
- Adding the `live_activity_token` field to the `APNSConfig` class
- Updated unit test to verify that the `live_activity_token` is correctly included in the encoded message

* Refactor and edit doc string

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Lahiru Maramba <llahiru@gmail.com>
Co-authored-by: Jonathan Edey <145066863+jonathanedey@users.noreply.github.com>
…or FCM async and HTTP/2 support (#882)

* Added minimal support for sending FCM messages in async using HTTP/2 (#870)

* httpx async_send_each prototype

* Clean up code and lint

* fix: Add extra dependancy for http2

* fix: reset message batch limit to 500

* fix: Add new import to `setup.py`

* Refactored retry config into `_retry.py` and added support for exponential backoff and `Retry-After` header (#871)

* Refactored retry config to `_retry.py` and added support for backoff and Retry-After

* Added unit tests for `_retry.py`

* Updated unit tests for HTTPX request errors

* Address review comments

* Added `HttpxAsyncClient` wrapper for `httpx.AsyncClient` and support for `send_each_for_multicast_async()` (#878)

* Refactored retry config to `_retry.py` and added support for backoff and Retry-After

* Added unit tests for `_retry.py`

* Updated unit tests for HTTPX request errors

* Add HttpxAsyncClient to wrap httpx.AsyncClient

* Added forced refresh to google auth credential flow and fixed lint

* Added unit tests for `GoogleAuthCredentialFlow` and `HttpxAsyncClient`

* Removed duplicate export

* Added support for `send_each_for_multicast_async()` and updated doc string and type hints

* Remove duplicate auth class

* Cover auth request error case when `requests` request fails in HTTPX auth flow

* Update test for `send_each_for_multicast_async()`

* Address review comments

* fix lint and some types

* Address review comments and removed unused code

* Update metric header test logic for `TestHttpxAsyncClient`

* Add `send_each_for_multicast_async` to `__all__`

* Apply suggestions from TW review
* change(fcm): Remove deprecated FCM APIs (#890)

* chore(deps): Bump minimum supported Python version to 3.9 and add 3.13 to CIs (#892)

* chore(deps): Bump minimum supported Python version to 3.9 and add 3.13 to CIs

* fix deprecation warnings

* fix GHA build status svg

* fix: Correctly scope async eventloop

* fix: Bump pylint to v2.7.4 and astroid to v2.5.8 to fix lint issues

* fix ml tests

* fix lint

* fix: remove commented code

* change(ml): Drop AutoML model support (#894)

* chore: Bump `pylint` to v3.3.7 and `astroid` to v3.3.10 (#895)

* chore: Bump pylint to v3

* chore: fix src lint

* chore: fix unit test lint

* chore: fix integration test lint

* chore: fix snippets lint

* chore: 2nd pass for errors

* fix: corrected use of the `bad-functions` config

* fix: add EoF newline

* chore: Upgraded Google API Core, Cloud Firestore, and Cloud Storage dependencies (#897)

* chore: Bump dependencies

* fix: Also update setup.py

* fix(functions): Remove usage of deprecated `datetime.utcnow() and fix flaky unit test` (#896)
…eprecate `dynamic_link_domain` (#884)

* Add link_domain to ActionCodeSettings; update encode_action_code_settings to handle link_domain

* Add handling for InvalidHostingLinkDomainError

* Add deprecation warning for dynamic_link_domain

* Update error message for InvalidHostingLinkDomainError

* Fix lint

* Add type hints to ActionCodeSettings

* Fix f-string lint
* fix(functions): Refresh credentials before enqueueing task

This change addresses an issue where enqueueing a task from a Cloud Function would fail with a InvalidArgumentError error. This was caused by uninitialized credentials being used to in the task payload.

The fix explicitly refreshes the credential before accessing the credential, ensuring a valid token or service account email is used in the in the task payload.

This also includes a correction for an f-string typo in the Authorization header construction.

* fix(functions): Move credential refresh to functions service init

* fix(functions): Moved credential refresh to run on task payload update with freshness guard

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
* feat(functions): Enable Cloud Task Queue Emulator support

* fix: lint

* fix: Resolved issues from gemini review

* chore: Added basic integration tests for task enqueue and delete

* chore: Setup emulator testing for Functions integration tests

* fix: Re-added accidentally removed lint

* fix: integration test default apps

* fix: lint
@lahirumaramba lahirumaramba deleted the branch majacQ:master December 12, 2025 18:36
@lahirumaramba lahirumaramba deleted the master branch December 12, 2025 18:36
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.