Skip to content

Commit 9a783d7

Browse files
committed
fixed lint
1 parent 9cdb8c9 commit 9a783d7

File tree

5 files changed

+5
-15
lines changed

5 files changed

+5
-15
lines changed

google/cloud/firestore_v1/base_pipeline.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ def sample(self, limit_or_options: int | SampleOptions) -> "_BasePipeline":
357357
"""
358358
return self._append(stages.Sample(limit_or_options))
359359

360-
def union(self, other: Self) -> "_BasePipeline":
360+
def union(self, other: "_BasePipeline") -> "_BasePipeline":
361361
"""
362362
Performs a union of all documents from this pipeline and another pipeline,
363363
including duplicates.
@@ -384,7 +384,7 @@ def unnest(
384384
self,
385385
field: str | Selectable,
386386
alias: str | Field | None = None,
387-
options: Optional[stages.UnnestOptions] = None,
387+
options: stages.UnnestOptions | None = None,
388388
) -> "_BasePipeline":
389389
"""
390390
Produces a document for each element in an array field from the previous stage document.

google/cloud/firestore_v1/pipeline_expressions.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,16 @@
1515
from __future__ import annotations
1616
from typing import (
1717
Any,
18-
Iterable,
1918
List,
20-
Mapping,
21-
Union,
2219
Generic,
2320
TypeVar,
24-
List,
2521
Dict,
26-
Tuple,
2722
Sequence,
2823
)
2924
from abc import ABC
3025
from abc import abstractmethod
3126
from enum import Enum
32-
from enum import auto
3327
import datetime
34-
from dataclasses import dataclass
3528
from google.cloud.firestore_v1.types.document import Value
3629
from google.cloud.firestore_v1.types.query import StructuredQuery as Query_pb
3730
from google.cloud.firestore_v1.vector import Vector

google/cloud/firestore_v1/pipeline_source.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,4 +82,4 @@ def documents(self, *docs: "BaseDocumentReference") -> PipelineType:
8282
Returns:
8383
a new pipeline instance targeting the specified documents
8484
"""
85-
return self._create_pipeline(stages.Documents.of(*docs))
85+
return self._create_pipeline(stages.Documents.of(*docs))

google/cloud/firestore_v1/pipeline_stages.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
)
3434

3535
if TYPE_CHECKING:
36-
from google.cloud.firestore_v1.pipeline import Pipeline
36+
from google.cloud.firestore_v1.base_pipeline import _BasePipeline
3737
from google.cloud.firestore_v1.base_document import BaseDocumentReference
3838

3939

@@ -369,7 +369,7 @@ def _pb_args(self):
369369
class Union(Stage):
370370
"""Performs a union of documents from two pipelines."""
371371

372-
def __init__(self, other: Pipeline):
372+
def __init__(self, other: _BasePipeline):
373373
super().__init__()
374374
self.other = other
375375

tests/system/test_pipeline_acceptance.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,17 @@
1313
# limitations under the License.
1414

1515
from __future__ import annotations
16-
import sys
1716
import os
1817
import pytest
1918
import yaml
2019
import re
2120
from typing import Any
22-
from contextlib import nullcontext
2321

2422
from google.protobuf.json_format import MessageToDict
2523

2624
# from google.cloud.firestore_v1.pipeline_stages import *
2725
from google.cloud.firestore_v1 import pipeline_stages
2826
from google.cloud.firestore_v1 import pipeline_expressions
29-
from google.cloud.firestore_v1.pipeline import Pipeline
3027
from google.api_core.exceptions import GoogleAPIError
3128

3229
from google.cloud.firestore import Client, AsyncClient

0 commit comments

Comments
 (0)