8000 chore(deps): update dependency ruff to >=0.2,<0.4 by renovate[bot] · Pull Request #983 · openapi-generators/openapi-python-client · GitHub
[go: up one dir, main page]

Skip to content

chore(deps): update dependency ruff to >=0.2,<0.4 #983

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 2 commits into from
Mar 2, 2024
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
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API """
"""Contains methods for accessing the API"""

from typing import Type

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains methods for accessing the API Endpoints """
"""Contains methods for accessing the API Endpoints"""

import types

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" A client library for accessing My Test API """
"""A client library for accessing My Test API"""

from .client import AuthenticatedClient, Client

__all__ = (
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
""" Contains methods for accessing the API """
"""Contains methods for accessing the API"""
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains shared errors types that can be raised from API functions """
"""Contains shared errors types that can be raised from API functions"""


class UnexpectedStatus(Exception):
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains all the data models used in inputs/outputs """
"""Contains all the data models used in inputs/outputs"""

from .a_discriminated_union_type_1 import ADiscriminatedUnionType1
from .a_discriminated_union_type_2 import ADiscriminatedUnionType2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
class AnArrayWithACircularRefInItemsObjectAdditionalPropertiesAItem:
""" """

additional_properties: Dict[
str, List["AnArrayWithACircularRefInItemsObjectAdditionalPropertiesBItem"]
] = _attrs_field(init=False, factory=dict)
additional_properties: Dict[str, List["AnArrayWithACircularRefInItemsObjectAdditionalPropertiesBItem"]] = (
_attrs_field(init=False, factory=dict)
)

def to_dict(self) -> Dict[str, Any]:
field_dict: Dict[str, Any] = {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
class AnArrayWithACircularRefInItemsObjectAdditionalPropertiesBItem:
""" """

additional_properties: Dict[
str, List["AnArrayWithACircularRefInItemsObjectAdditionalPropertiesAItem"]
] = _attrs_field(init=False, factory=dict)
additional_properties: Dict[str, List["AnArrayWithACircularRefInItemsObjectAdditionalPropertiesAItem"]] = (
_attrs_field(init=False, factory=dict)
)

def to_dict(self) -> Dict[str, Any]:
field_dict: Dict[str, Any] = {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
class AnArrayWithARecursiveRefInItemsObjectAdditionalPropertiesItem:
""" """

additional_properties: Dict[
str, List["AnArrayWithARecursiveRefInItemsObjectAdditionalPropertiesItem"]
] = _attrs_field(init=False, factory=dict)
additional_properties: Dict[str, List["AnArrayWithARecursiveRefInItemsObjectAdditionalPropertiesItem"]] = (
_attrs_field(init=False, factory=dict)
)

def to_dict(self) -> Dict[str, Any]:
field_dict: Dict[str, Any] = {}
Expand Down
3 changes: 2 additions & 1 deletion end_to_end_tests/golden-record/my_test_api_client/types.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" Contains some shared types for properties """
"""Contains some shared types for properties"""

from http import HTTPStatus
from typing import BinaryIO, Generic, Literal, MutableMapping, Optional, Tuple, TypeVar

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" A client library for accessing Test 3.1 Features """
"""A client library for accessing Test 3.1 Features"""

from .client import AuthenticatedClient, Client

__all__ = (
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
""" Contains methods for accessing the API """
"""Contains methods for accessing the API"""
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains shared errors types that can be raised from API functions """
"""Contains shared errors types that can be raised from API functions"""


class UnexpectedStatus(Exception):
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains all the data models used in inputs/outputs """
"""Contains all the data models used in inputs/outputs"""

from .post_const_path_body import PostConstPathBody

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" Contains some shared types for properties """
"""Contains some shared types for properties"""

from http import HTTPStatus
from typing import BinaryIO, Generic, Literal, MutableMapping, Optional, Tuple, TypeVar

Expand Down
3 changes: 2 additions & 1 deletion integration-tests/integration_tests/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" A client library for accessing OpenAPI Test Server """
"""A client library for accessing OpenAPI Test Server"""

from .client import AuthenticatedClient, Client

__all__ = (
Expand Down
2 changes: 1 addition & 1 deletion integration-tests/integration_tests/api/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
""" Contains methods for accessing the API """
"""Contains methods for accessing the API"""
2 changes: 1 addition & 1 deletion integration-tests/integration_tests/errors.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains shared errors types that can be raised from API functions """
"""Contains shared errors types that can be raised from API functions"""


class UnexpectedStatus(Exception):
Expand Down
2 changes: 1 addition & 1 deletion integration-tests/integration_tests/models/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Contains all the data models used in inputs/outputs """
"""Contains all the data models used in inputs/outputs"""

from .post_body_multipart_body import PostBodyMultipartBody
from .post_body_multipart_response_200 import PostBodyMultipartResponse200
Expand Down
3 changes: 2 additions & 1 deletion integration-tests/integration_tests/types.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
""" Contains some shared types for properties """
"""Contains some shared types for properties"""

from http import HTTPStatus
from typing import BinaryIO, Generic, Literal, MutableMapping, Optional, Tuple, TypeVar

Expand Down
2 changes: 1 addition & 1 deletion openapi_python_client/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Generate modern Python clients from OpenAPI """
"""Generate modern Python clients from OpenAPI"""

import json
import mimetypes
Expand Down
2 changes: 1 addition & 1 deletion openapi_python_client/parser/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" Classes representing the data in the OpenAPI schema """
"""Classes representing the data in the OpenAPI schema"""

__all__ = ["GeneratorData", "import_string_from_class"]

Expand Down
3 changes: 1 addition & 2 deletions openapi_python_client/parser/openapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ class RequestBodyParser(Protocol):

def __call__(
self, *, body: oai.RequestBody, schemas: Schemas, parent_name: str, config: Config
) -> Tuple[Union[Property, PropertyError, None], Schemas]:
... # pragma: no cover
) -> Tuple[Union[Property, PropertyError, None], Schemas]: ... # pragma: no cover


@dataclass
Expand Down
3 changes: 1 addition & 2 deletions openapi_python_client/parser/properties/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ def _convert_value(value: None) -> None: # type: ignore[misc]

@staticmethod
@overload
def _convert_value(value: Any) -> Value:
... # pragma: no cover
def _convert_value(value: Any) -> Value: ... # pragma: no cover

@staticmethod
def _convert_value(value: Any) -> Value | None:
Expand Down
3 changes: 1 addition & 2 deletions openapi_python_client/parser/properties/string.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,7 @@ def convert_value(cls, value: None) -> None: # type: ignore[misc]

@classmethod
@overload
def convert_value(cls, value: Any) -> Value:
... # pragma: no cover
def convert_value(cls, value: Any) -> Value: ... # pragma: no cover

@classmethod
def convert_value(cls, value: Any) -> Value | None:
Expand Down
38 changes: 19 additions & 19 deletions pdm.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ dependencies = [
"python-dateutil>=2.8.1,<3.0.0",
"httpx>=0.20.0,<0.28.0",
"PyYAML>=6.0,<7.0",
"ruff>=0.2,<0.3",
"ruff>=0.2,<0.4",
"typing-extensions>=4.8.0,<5.0.0",
]
name = "openapi-python-client"
Expand Down
0