Skip to content

Light edit pass for style and link fixing. #158

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

Merged
merged 1 commit into from
Nov 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/firebase_functions/alerts_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class AlertEvent(_CloudEvent[T]):
app_id: str | None
"""
The Firebase App ID that's associated with the alert. This is optional,
and only present when the alert is targeting at a specific Firebase App.
and only present when the alert is targeting a specific Firebase App.
"""


Expand All @@ -66,7 +66,7 @@ def on_alert_published(
**kwargs
) -> _typing.Callable[[OnAlertPublishedCallable], OnAlertPublishedCallable]:
"""
Event handler which triggers when a Firebase Alerts event is published.
Event handler that triggers when a Firebase Alerts event is published.

Example:

Expand Down
2 changes: 1 addition & 1 deletion src/firebase_functions/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
class CloudEvent(_typing.Generic[T]):
"""
A CloudEvent is the base of a cross-platform format for encoding a serverless event.
More information can be found at https://github.com/cloudevents/spec
More information can be found at https://github.com/cloudevents/spec.
"""

specversion: str
Expand Down
10 changes: 5 additions & 5 deletions src/firebase_functions/db_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class Event(_core.CloudEvent[T]):

params: dict[str, str]
"""
An dict containing the values of the path patterns.
A dict containing the values of the path patterns.
Only named capture groups are populated - {key}, {key=*}, {key=**}
"""

Expand Down Expand Up @@ -125,7 +125,7 @@ def _db_endpoint_handler(
@_util.copy_func_kwargs(DatabaseOptions)
def on_value_written(**kwargs) -> _typing.Callable[[_C1], _C1]:
"""
Event handler which triggers when data is created, updated, or deleted in Realtime Database.
Event handler that triggers when data is created, updated, or deleted in Realtime Database.

Example:

Expand Down Expand Up @@ -175,7 +175,7 @@ def on_value_written_wrapped(raw: _ce.CloudEvent):
@_util.copy_func_kwargs(DatabaseOptions)
def on_value_updated(**kwargs) -> _typing.Callable[[_C1], _C1]:
"""
Event handler which triggers when data is updated in Realtime Database.
Event handler that triggers when data is updated in Realtime Database.

Example:

Expand Down Expand Up @@ -225,7 +225,7 @@ def on_value_updated_wrapped(raw: _ce.CloudEvent):
@_util.copy_func_kwargs(DatabaseOptions)
def on_value_created(**kwargs) -> _typing.Callable[[_C2], _C2]:
"""
Event handler which triggers when data is created in Realtime Database.
Event handler that triggers when data is created in Realtime Database.

Example:

Expand Down Expand Up @@ -275,7 +275,7 @@ def on_value_created_wrapped(raw: _ce.CloudEvent):
@_util.copy_func_kwargs(DatabaseOptions)
def on_value_deleted(**kwargs) -> _typing.Callable[[_C2], _C2]:
"""
Event handler which triggers when data is deleted in Realtime Database.
Event handler that triggers when data is deleted in Realtime Database.

Example:

Expand Down
4 changes: 2 additions & 2 deletions src/firebase_functions/https_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,9 @@ class FunctionsErrorCode(str, _enum.Enum):

INTERNAL = "internal"
"""
Internal errors. Means some invariants expected by
Internal errors. Means some invariants expected by the
underlying system have been broken. If you see one of these errors,
something is very broken.
something is severely broken.
"""

UNAVAILABLE = "unavailable"
Expand Down
8 changes: 4 additions & 4 deletions src/firebase_functions/identity_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class AuthUserInfo:
"""The user identifier for the linked provider."""

provider_id: str
"""The linked provider ID (e.g., "google.com" for the Google provider)."""
"""The linked provider ID (such as "google.com" for the Google provider)."""

display_name: str | None = None
"""The display name for the linked provider."""
Expand Down Expand Up @@ -110,7 +110,7 @@ class AuthMultiFactorSettings:
@_dataclasses.dataclass(frozen=True)
class AuthUserRecord:
"""
The UserRecord passed to auth blocking Cloud Functions from the identity platform.
The UserRecord passed to auth blocking functions from the identity platform.
"""

uid: str
Expand Down Expand Up @@ -155,7 +155,7 @@ class AuthUserRecord:

provider_data: list[AuthUserInfo]
"""
An array of providers (e.g., Google, Facebook) linked to the user.
An array of providers (such as Google or Facebook) linked to the user.
"""

password_hash: str | None
Expand Down Expand Up @@ -243,7 +243,7 @@ class AuthBlockingEvent:

data: AuthUserRecord
"""
The UserRecord passed to auth blocking Cloud Functions from the identity platform.
The UserRecord passed to auth blocking functions from the identity platform.
"""

locale: str | None
Expand Down
4 changes: 2 additions & 2 deletions src/firebase_functions/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
class LogSeverity(str, _enum.Enum):
"""
`LogSeverity` indicates the detailed severity of the log entry. See
[LogSeverity](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry#logseverity).
`LogSeverity <https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry#logseverity>`_.
"""

DEBUG = "DEBUG"
Expand All @@ -28,7 +28,7 @@ class LogSeverity(str, _enum.Enum):
class LogEntry(_typing.TypedDict):
"""
`LogEntry` represents a log entry.
See [LogEntry](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry).
See `LogEntry <https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry>`_.
"""

severity: _typing_extensions.Required[LogSeverity]
Expand Down
6 changes: 3 additions & 3 deletions src/firebase_functions/params.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,18 +144,18 @@ class TextInput:
"""
Specifies that a Param's value should be determined by prompting the user
to type it in interactively at deploy-time. Input that does not match the provided
validation_regex, if present, will be retried.
validation_regex, if present, is retried.
"""

example: str | None = None
"""
An example of the input required that will be displayed alongside the input prompt.
An example of the input required that is displayed alongside the input prompt.
"""

validation_regex: str | None = None
"""
Validation regex for the input.
Input that does not match this regex, if present, will be retried.
Input that does not match this regex, if present, is retried.
"""

validation_error_message: str | None = None
Expand Down
2 changes: 1 addition & 1 deletion src/firebase_functions/pubsub_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ def _message_handler(
@_util.copy_func_kwargs(PubSubOptions)
def on_message_published(**kwargs) -> _typing.Callable[[_C1], _C1]:
"""
Event handler which triggers on a message being published to a Pub/Sub topic.
Event handler that triggers on a message being published to a Pub/Sub topic.

Example:

Expand Down
4 changes: 2 additions & 2 deletions src/firebase_functions/remote_config_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,8 @@ class ConfigUpdateData:

rollback_source: int | None = None
"""
Only present if this version is the result of a rollback, and will be
the version number of the Remote Config template that was rolled-back to.
Only present if this version is the result of a rollback, and is
the version number of the Remote Config template that was rolled back to.
"""


Expand Down
2 changes: 1 addition & 1 deletion src/firebase_functions/storage_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
"""
Cloud functions to handle events from Google Cloud Storage.
Functions to handle events from Google Cloud Storage.
"""
# pylint: disable=protected-access
import dataclasses as _dataclasses
Expand Down
2 changes: 1 addition & 1 deletion src/firebase_functions/tasks_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Cloud functions to handle Tasks enqueued with Google Cloud Tasks."""
"""Functions to handle Tasks enqueued with Google Cloud Tasks."""

# pylint: disable=protected-access
import typing as _typing
Expand Down