Skip to content

Commit 98a7a81

Browse files
committed
chore: fix isort pre-commit
Signed-off-by: Yurii Serhiichuk <savik.ne@gmail.com>
1 parent 8b9fd96 commit 98a7a81

34 files changed

+37
-61
lines changed

cloudevents/conversion.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,13 @@
1616
import json
1717
import typing
1818

19-
from cloudevents import exceptions as cloud_exceptions
2019
from cloudevents.abstract import AnyCloudEvent
2120
from cloudevents.sdk import converters, marshaller, types
2221
from cloudevents.sdk.converters import is_binary
2322
from cloudevents.sdk.event import v1, v03
2423

24+
from cloudevents import exceptions as cloud_exceptions
25+
2526

2627
def _best_effort_serialize_to_json( # type: ignore[no-untyped-def]
2728
value: typing.Any, *args, **kwargs

cloudevents/http/event.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,10 @@
1717
import uuid
1818

1919
import cloudevents.exceptions as cloud_exceptions
20-
from cloudevents import abstract
2120
from cloudevents.sdk.event import v1, v03
2221

22+
from cloudevents import abstract
23+
2324
_required_by_version = {
2425
"1.0": v1.Event._ce_required_fields,
2526
"0.3": v03.Event._ce_required_fields,

cloudevents/http/event_type.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,9 @@
1313
# under the License.
1414
import typing
1515

16-
from deprecation import deprecated
17-
1816
from cloudevents.sdk.converters import is_binary as _moved_is_binary
1917
from cloudevents.sdk.converters import is_structured as _moved_is_structured
18+
from deprecation import deprecated
2019

2120
# THIS MODULE IS DEPRECATED, YOU SHOULD NOT ADD NEW FUNCTIONALLY HERE
2221

cloudevents/http/http_methods.py

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

1515
import typing
1616

17-
from deprecation import deprecated
18-
1917
from cloudevents.abstract import AnyCloudEvent
2018
from cloudevents.conversion import to_binary as _moved_to_binary
2119
from cloudevents.conversion import to_structured as _moved_to_structured
2220
from cloudevents.http.conversion import from_http as _moved_from_http
2321
from cloudevents.http.event import CloudEvent
2422
from cloudevents.sdk import types
23+
from deprecation import deprecated
2524

2625
# THIS MODULE IS DEPRECATED, YOU SHOULD NOT ADD NEW FUNCTIONALLY HERE
2726

cloudevents/http/json_methods.py

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

1515
import typing
1616

17-
from deprecation import deprecated
18-
1917
from cloudevents.abstract import AnyCloudEvent
2018
from cloudevents.conversion import to_json as _moved_to_json
2119
from cloudevents.http import CloudEvent
2220
from cloudevents.http.conversion import from_json as _moved_from_json
2321
from cloudevents.sdk import types
22+
from deprecation import deprecated
2423

2524
# THIS MODULE IS DEPRECATED, YOU SHOULD NOT ADD NEW FUNCTIONALLY HERE
2625

cloudevents/http/util.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@
1313
# under the License.
1414
import typing
1515

16-
from deprecation import deprecated
17-
1816
from cloudevents.conversion import (
1917
_best_effort_serialize_to_json as _moved_default_marshaller,
2018
)
19+
from deprecation import deprecated
2120

2221
# THIS MODULE IS DEPRECATED, YOU SHOULD NOT ADD NEW FUNCTIONALLY HERE
2322

cloudevents/kafka/conversion.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,13 @@
1515
import json
1616
import typing
1717

18-
from cloudevents import exceptions as cloud_exceptions
19-
from cloudevents import http
2018
from cloudevents.abstract import AnyCloudEvent
2119
from cloudevents.kafka.exceptions import KeyMapperError
2220
from cloudevents.sdk import types
2321

22+
from cloudevents import exceptions as cloud_exceptions
23+
from cloudevents import http
24+
2425
JSON_MARSHALLER: types.MarshallerType = json.dumps
2526
JSON_UNMARSHALLER: types.UnmarshallerType = json.loads
2627
IDENTITY_MARSHALLER = IDENTITY_UNMARSHALLER = lambda x: x

cloudevents/pydantic/v1/event.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,11 @@
3232
"Install it using pip install cloudevents[pydantic]"
3333
)
3434

35-
from cloudevents import abstract, conversion, http
3635
from cloudevents.exceptions import IncompatibleArgumentsError
3736
from cloudevents.sdk.event import attribute
3837

38+
from cloudevents import abstract, conversion, http
39+
3940

4041
def _ce_json_dumps( # type: ignore[no-untyped-def]
4142
obj: typing.Dict[str, typing.Any],

cloudevents/pydantic/v2/event.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,9 @@
1717
import typing
1818
from typing import Any
1919

20-
from pydantic.deprecated import parse as _deprecated_parse
21-
2220
from cloudevents.exceptions import PydanticFeatureNotInstalled
2321
from cloudevents.pydantic.fields_docs import FIELD_DESCRIPTIONS
22+
from pydantic.deprecated import parse as _deprecated_parse
2423

2524
try:
2625
from pydantic import BaseModel, ConfigDict, Field, model_serializer
@@ -30,10 +29,11 @@
3029
"Install it using pip install cloudevents[pydantic]"
3130
)
3231

33-
from cloudevents import abstract, conversion
3432
from cloudevents.exceptions import IncompatibleArgumentsError
3533
from cloudevents.sdk.event import attribute
3634

35+
from cloudevents import abstract, conversion
36+
3737

3838
class CloudEvent(abstract.CloudEvent, BaseModel): # type: ignore
3939
"""

cloudevents/tests/test_backwards_compatability.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414
import pytest
15-
1615
from cloudevents.conversion import _best_effort_serialize_to_json
1716
from cloudevents.http import CloudEvent
1817

0 commit comments

Comments
 (0)