Skip to content

Commit

Permalink
Update requirements (#214)
Browse files Browse the repository at this point in the history
  • Loading branch information
tarsil authored Nov 27, 2023
2 parents b2fe23f + 27096ba commit 64de447
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 18 deletions.
15 changes: 0 additions & 15 deletions esmerald/params.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ def __init__(
required: bool = True,
title: Optional[str] = None,
description: Optional[str] = None,
const: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
lt: Optional[float] = None,
Expand All @@ -56,7 +55,6 @@ def __init__(
self.deprecated = deprecated
self.examples = examples
self.include_in_schema = include_in_schema
self.const = const
self.allow_none = allow_none

extra: Dict[str, Any] = {}
Expand All @@ -70,7 +68,6 @@ def __init__(
extra.update(examples=self.examples)
extra.update(deprecated=self.deprecated)
extra.update(include_in_schema=self.include_in_schema)
extra.update(const=self.const)
extra.update(allow_none=self.allow_none)

super().__init__(
Expand All @@ -81,7 +78,6 @@ def __init__(
alias_priority=alias_priority,
title=title,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand All @@ -93,7 +89,6 @@ def __init__(
examples=examples,
allow_inf_nan=allow_inf_nan,
json_schema_extra=extra,
include=include_in_schema,
validate_default=validate_default,
validation_alias=validation_alias,
discriminator=discriminator,
Expand Down Expand Up @@ -126,7 +121,6 @@ def __init__(
required: bool = True,
title: Optional[str] = None,
description: Optional[str] = None,
const: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
lt: Optional[float] = None,
Expand Down Expand Up @@ -158,7 +152,6 @@ def __init__(
alias_priority=alias_priority,
title=title,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand Down Expand Up @@ -203,7 +196,6 @@ def __init__(
required: bool = True,
title: Optional[str] = None,
description: Optional[str] = None,
const: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
lt: Optional[float] = None,
Expand Down Expand Up @@ -235,7 +227,6 @@ def __init__(
alias_priority=alias_priority,
title=title,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand Down Expand Up @@ -280,7 +271,6 @@ def __init__(
required: bool = True,
title: Optional[str] = None,
description: Optional[str] = None,
const: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
lt: Optional[float] = None,
Expand Down Expand Up @@ -312,7 +302,6 @@ def __init__(
alias_priority=alias_priority,
title=title,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand Down Expand Up @@ -354,7 +343,6 @@ def __init__(
required: bool = True,
title: Optional[str] = None,
description: Optional[str] = None,
const: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
lt: Optional[float] = None,
Expand All @@ -381,7 +369,6 @@ def __init__(
annotation=annotation,
title=title,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand Down Expand Up @@ -420,7 +407,6 @@ def __init__(
alias: Optional[str] = None,
alias_priority: Optional[int] = _PyUndefined,
description: Optional[str] = None,
const: Optional[bool] = None,
embed: Optional[bool] = None,
gt: Optional[float] = None,
ge: Optional[float] = None,
Expand Down Expand Up @@ -462,7 +448,6 @@ def __init__(
alias=alias,
alias_priority=alias_priority,
description=description,
const=const,
gt=gt,
ge=ge,
lt=lt,
Expand Down
2 changes: 1 addition & 1 deletion esmerald/utils/sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def __init__(self, fn: Callable[P, T]):
if is_async_callable(fn):
self.fn = fn
else:
self.fn = partial(run_sync, fn) # type:ignore[assignment]
self.fn = partial(run_sync, fn)

async def __call__(self, *args: P.args, **kwargs: P.kwargs) -> T:
return await self.fn(*args, **kwargs)
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ dependencies = [
"itsdangerous>=2.1.2,<3.0.0",
"jinja2>=3.1.2,<4.0.0",
"loguru>=0.7.0,<0.8.0",
"pydantic>=2.5.1,<3.0.0",
"pydantic>=2.5.2,<3.0.0",
"pydantic-settings>=2.0.0,<3.0.0",
"python-multipart>=0.0.5,<0.0.7",
"openapi-schemas-pydantic>=3.0.0",
Expand Down Expand Up @@ -96,7 +96,7 @@ test = [
"pytest>=7.4.0,<8.0.0",
"pytest-cov>=4.1.0,<5.0.0",
"pytest-asyncio>=0.20.0",
"mypy==1.6.1",
"mypy==1.7.1",
"flake8>=5.0.4",
"black==23.11.0",
"isort>=5.0.6,<6.0.0",
Expand Down

0 comments on commit 64de447

Please sign in to comment.