Skip to content

Commit f4ab5b8

Browse files
committed
run nox -s format
1 parent 36a098e commit f4ab5b8

54 files changed

Lines changed: 331 additions & 390 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

packages/google-cloud-error-reporting/docs/conf.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import os
2929
import shlex
3030
import sys
31-
import logging
3231
from typing import Any
3332

3433
# If extensions (or modules to document with autodoc) are in another directory,

packages/google-cloud-error-reporting/google/cloud/error_reporting/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,11 @@
1414

1515
"""Client library for Error Reporting"""
1616

17-
1817
from google.cloud.error_reporting import gapic_version as package_version
1918

2019
__version__ = package_version.__version__
2120

22-
from google.cloud.error_reporting.client import Client
23-
from google.cloud.error_reporting.client import HTTPContext
21+
from google.cloud.error_reporting.client import Client, HTTPContext
2422
from google.cloud.error_reporting.util import build_flask_context
2523

2624
__all__ = ["__version__", "Client", "HTTPContext", "build_flask_context"]

packages/google-cloud-error-reporting/google/cloud/error_reporting/_gapic.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
# limitations under the License.
1414

1515
"""GAX wrapper for Error Reporting API requests."""
16+
1617
import json
1718

1819
import google.cloud.errorreporting_v1beta1

packages/google-cloud-error-reporting/google/cloud/error_reporting/client.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,10 @@
2929
_HAVE_GRPC = True
3030

3131
from google.cloud.client import ClientWithProject
32+
from google.cloud.environment_vars import DISABLE_GRPC
33+
3234
from google.cloud.error_reporting import gapic_version
3335
from google.cloud.error_reporting._logging import _ErrorReportingLoggingAPI
34-
from google.cloud.environment_vars import DISABLE_GRPC
3536

3637
__version__ = gapic_version.__version__
3738

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/__init__.py

Lines changed: 46 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
16+
import sys
1717

1818
import google.api_core as api_core
19-
import sys
19+
20+
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
2021

2122
__version__ = package_version.__version__
2223

@@ -28,38 +29,48 @@
2829
import importlib_metadata as metadata
2930

3031

31-
from .services.error_group_service import ErrorGroupServiceClient
32-
from .services.error_group_service import ErrorGroupServiceAsyncClient
33-
from .services.error_stats_service import ErrorStatsServiceClient
34-
from .services.error_stats_service import ErrorStatsServiceAsyncClient
35-
from .services.report_errors_service import ReportErrorsServiceClient
36-
from .services.report_errors_service import ReportErrorsServiceAsyncClient
37-
38-
from .types.common import ErrorContext
39-
from .types.common import ErrorEvent
40-
from .types.common import ErrorGroup
41-
from .types.common import HttpRequestContext
42-
from .types.common import ServiceContext
43-
from .types.common import SourceLocation
44-
from .types.common import TrackingIssue
45-
from .types.common import ResolutionStatus
46-
from .types.error_group_service import GetGroupRequest
47-
from .types.error_group_service import UpdateGroupRequest
48-
from .types.error_stats_service import DeleteEventsRequest
49-
from .types.error_stats_service import DeleteEventsResponse
50-
from .types.error_stats_service import ErrorGroupStats
51-
from .types.error_stats_service import ListEventsRequest
52-
from .types.error_stats_service import ListEventsResponse
53-
from .types.error_stats_service import ListGroupStatsRequest
54-
from .types.error_stats_service import ListGroupStatsResponse
55-
from .types.error_stats_service import QueryTimeRange
56-
from .types.error_stats_service import ServiceContextFilter
57-
from .types.error_stats_service import TimedCount
58-
from .types.error_stats_service import ErrorGroupOrder
59-
from .types.error_stats_service import TimedCountAlignment
60-
from .types.report_errors_service import ReportedErrorEvent
61-
from .types.report_errors_service import ReportErrorEventRequest
62-
from .types.report_errors_service import ReportErrorEventResponse
32+
from .services.error_group_service import (
33+
ErrorGroupServiceAsyncClient,
34+
ErrorGroupServiceClient,
35+
)
36+
from .services.error_stats_service import (
37+
ErrorStatsServiceAsyncClient,
38+
ErrorStatsServiceClient,
39+
)
40+
from .services.report_errors_service import (
41+
ReportErrorsServiceAsyncClient,
42+
ReportErrorsServiceClient,
43+
)
44+
from .types.common import (
45+
ErrorContext,
46+
ErrorEvent,
47+
ErrorGroup,
48+
HttpRequestContext,
49+
ResolutionStatus,
50+
ServiceContext,
51+
SourceLocation,
52+
TrackingIssue,
53+
)
54+
from .types.error_group_service import GetGroupRequest, UpdateGroupRequest
55+
from .types.error_stats_service import (
56+
DeleteEventsRequest,
57+
DeleteEventsResponse,
58+
ErrorGroupOrder,
59+
ErrorGroupStats,
60+
ListEventsRequest,
61+
ListEventsResponse,
62+
ListGroupStatsRequest,
63+
ListGroupStatsResponse,
64+
QueryTimeRange,
65+
ServiceContextFilter,
66+
TimedCount,
67+
TimedCountAlignment,
68+
)
69+
from .types.report_errors_service import (
70+
ReportedErrorEvent,
71+
ReportErrorEventRequest,
72+
ReportErrorEventResponse,
73+
)
6374

6475
if hasattr(api_core, "check_python_version") and hasattr(
6576
api_core, "check_dependency_versions"
@@ -70,8 +81,8 @@
7081
# An older version of api_core is installed which does not define the
7182
# functions above. We do equivalent checks manually.
7283
try:
73-
import warnings
7484
import sys
85+
import warnings
7586

7687
_py_version_str = sys.version.split()[0]
7788
_package_label = "google.cloud.errorreporting_v1beta1"

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/services/error_group_service/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
from .client import ErrorGroupServiceClient
1716
from .async_client import ErrorGroupServiceAsyncClient
17+
from .client import ErrorGroupServiceClient
1818

1919
__all__ = (
2020
"ErrorGroupServiceClient",

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/services/error_group_service/async_client.py

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@
1414
# limitations under the License.
1515
#
1616
import logging as std_logging
17-
from collections import OrderedDict
1817
import re
18+
from collections import OrderedDict
1919
from typing import (
20-
Dict,
2120
Callable,
21+
Dict,
2222
Mapping,
2323
MutableMapping,
2424
MutableSequence,
@@ -29,27 +29,26 @@
2929
Union,
3030
)
3131

32-
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
33-
34-
from google.api_core.client_options import ClientOptions
32+
import google.protobuf
3533
from google.api_core import exceptions as core_exceptions
3634
from google.api_core import gapic_v1
3735
from google.api_core import retry_async as retries
36+
from google.api_core.client_options import ClientOptions
3837
from google.auth import credentials as ga_credentials # type: ignore
3938
from google.oauth2 import service_account # type: ignore
40-
import google.protobuf
4139

40+
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
4241

4342
try:
4443
OptionalRetry = Union[retries.AsyncRetry, gapic_v1.method._MethodDefault, None]
4544
except AttributeError: # pragma: NO COVER
4645
OptionalRetry = Union[retries.AsyncRetry, object, None] # type: ignore
4746

48-
from google.cloud.errorreporting_v1beta1.types import common
49-
from google.cloud.errorreporting_v1beta1.types import error_group_service
50-
from .transports.base import ErrorGroupServiceTransport, DEFAULT_CLIENT_INFO
51-
from .transports.grpc_asyncio import ErrorGroupServiceGrpcAsyncIOTransport
47+
from google.cloud.errorreporting_v1beta1.types import common, error_group_service
48+
5249
from .client import ErrorGroupServiceClient
50+
from .transports.base import DEFAULT_CLIENT_INFO, ErrorGroupServiceTransport
51+
from .transports.grpc_asyncio import ErrorGroupServiceGrpcAsyncIOTransport
5352

5453
try:
5554
from google.api_core import client_logging # type: ignore

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/services/error_group_service/client.py

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,16 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
from collections import OrderedDict
17-
from http import HTTPStatus
1816
import json
1917
import logging as std_logging
2018
import os
2119
import re
20+
import warnings
21+
from collections import OrderedDict
22+
from http import HTTPStatus
2223
from typing import (
23-
Dict,
2424
Callable,
25+
Dict,
2526
Mapping,
2627
MutableMapping,
2728
MutableSequence,
@@ -32,20 +33,19 @@
3233
Union,
3334
cast,
3435
)
35-
import warnings
36-
37-
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
3836

37+
import google.protobuf
3938
from google.api_core import client_options as client_options_lib
4039
from google.api_core import exceptions as core_exceptions
4140
from google.api_core import gapic_v1
4241
from google.api_core import retry as retries
4342
from google.auth import credentials as ga_credentials # type: ignore
43+
from google.auth.exceptions import MutualTLSChannelError # type: ignore
4444
from google.auth.transport import mtls # type: ignore
4545
from google.auth.transport.grpc import SslCredentials # type: ignore
46-
from google.auth.exceptions import MutualTLSChannelError # type: ignore
4746
from google.oauth2 import service_account # type: ignore
48-
import google.protobuf
47+
48+
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
4949

5050
try:
5151
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault, None]
@@ -61,9 +61,9 @@
6161

6262
_LOGGER = std_logging.getLogger(__name__)
6363

64-
from google.cloud.errorreporting_v1beta1.types import common
65-
from google.cloud.errorreporting_v1beta1.types import error_group_service
66-
from .transports.base import ErrorGroupServiceTransport, DEFAULT_CLIENT_INFO
64+
from google.cloud.errorreporting_v1beta1.types import common, error_group_service
65+
66+
from .transports.base import DEFAULT_CLIENT_INFO, ErrorGroupServiceTransport
6767
from .transports.grpc import ErrorGroupServiceGrpcTransport
6868
from .transports.grpc_asyncio import ErrorGroupServiceGrpcAsyncIOTransport
6969
from .transports.rest import ErrorGroupServiceRestTransport
@@ -77,9 +77,7 @@ class ErrorGroupServiceClientMeta(type):
7777
objects.
7878
"""
7979

80-
_transport_registry = (
81-
OrderedDict()
82-
) # type: Dict[str, Type[ErrorGroupServiceTransport]]
80+
_transport_registry = OrderedDict() # type: Dict[str, Type[ErrorGroupServiceTransport]]
8381
_transport_registry["grpc"] = ErrorGroupServiceGrpcTransport
8482
_transport_registry["grpc_asyncio"] = ErrorGroupServiceGrpcAsyncIOTransport
8583
_transport_registry["rest"] = ErrorGroupServiceRestTransport
@@ -657,8 +655,7 @@ def __init__(
657655
)
658656
if self._client_options.scopes:
659657
raise ValueError(
660-
"When providing a transport instance, provide its scopes "
661-
"directly."
658+
"When providing a transport instance, provide its scopes directly."
662659
)
663660
self._transport = cast(ErrorGroupServiceTransport, transport)
664661
self._api_endpoint = self._transport.host

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/services/error_group_service/transports/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@
1919
from .base import ErrorGroupServiceTransport
2020
from .grpc import ErrorGroupServiceGrpcTransport
2121
from .grpc_asyncio import ErrorGroupServiceGrpcAsyncIOTransport
22-
from .rest import ErrorGroupServiceRestTransport
23-
from .rest import ErrorGroupServiceRestInterceptor
24-
22+
from .rest import ErrorGroupServiceRestInterceptor, ErrorGroupServiceRestTransport
2523

2624
# Compile a registry of transports.
2725
_transport_registry = OrderedDict() # type: Dict[str, Type[ErrorGroupServiceTransport]]

packages/google-cloud-error-reporting/google/cloud/errorreporting_v1beta1/services/error_group_service/transports/base.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,17 @@
1616
import abc
1717
from typing import Awaitable, Callable, Dict, Optional, Sequence, Union
1818

19-
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
20-
21-
import google.auth # type: ignore
2219
import google.api_core
20+
import google.auth # type: ignore
21+
import google.protobuf
2322
from google.api_core import exceptions as core_exceptions
2423
from google.api_core import gapic_v1
2524
from google.api_core import retry as retries
2625
from google.auth import credentials as ga_credentials # type: ignore
2726
from google.oauth2 import service_account # type: ignore
28-
import google.protobuf
2927

30-
from google.cloud.errorreporting_v1beta1.types import common
31-
from google.cloud.errorreporting_v1beta1.types import error_group_service
28+
from google.cloud.errorreporting_v1beta1 import gapic_version as package_version
29+
from google.cloud.errorreporting_v1beta1.types import common, error_group_service
3230

3331
DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo(
3432
gapic_version=package_version.__version__

0 commit comments

Comments
 (0)