Skip to content

Commit

Permalink
Modify typo and ruff it
Browse files Browse the repository at this point in the history
  • Loading branch information
jrycw committed May 27, 2024
1 parent b7a38b4 commit 13d2897
Show file tree
Hide file tree
Showing 12 changed files with 86 additions and 67 deletions.
2 changes: 2 additions & 0 deletions app/queries/create_event_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/create_user_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/delete_event_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/delete_user_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/get_event_by_name_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/get_events_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/get_user_by_name_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/get_users_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/set_default_dev_data_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/update_event_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
2 changes: 2 additions & 0 deletions app/queries/update_user_async_edgeql.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ class NoPydanticValidation:
def __get_pydantic_core_schema__(cls, _source_type, _handler):
# Pydantic 2.x
from pydantic_core.core_schema import any_schema

return any_schema()

@classmethod
def __get_validators__(cls):
# Pydantic 1.x
from pydantic.dataclasses import dataclass as pydantic_dataclass

pydantic_dataclass(cls)
cls.__pydantic_model__.__get_validators__ = lambda: []
return []
Expand Down
Loading

0 comments on commit 13d2897

Please sign in to comment.