Skip to content

Commit

Permalink
Revert "uprev dependencies"
Browse files Browse the repository at this point in the history
This reverts commit 55f7883.
  • Loading branch information
samuelcolvin committed Aug 13, 2024
1 parent 55f7883 commit 2b7c8fa
Show file tree
Hide file tree
Showing 13 changed files with 91 additions and 94 deletions.
6 changes: 4 additions & 2 deletions dirty_equals/_dict.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ class IsDict(DirtyEquals[Dict[Any, Any]]):
"""

@overload
def __init__(self, expected: dict[Any, Any]): ...
def __init__(self, expected: dict[Any, Any]):
...

@overload
def __init__(self, **expected: Any): ...
def __init__(self, **expected: Any):
...

def __init__(self, *expected_args: dict[Any, Any], **expected_kwargs: Any):
"""
Expand Down
6 changes: 4 additions & 2 deletions dirty_equals/_inspection.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,12 @@ class HasAttributes(DirtyEquals[Any]):
"""

@overload
def __init__(self, expected: Dict[Any, Any]): ...
def __init__(self, expected: Dict[Any, Any]):
...

@overload
def __init__(self, **expected: Any): ...
def __init__(self, **expected: Any):
...

def __init__(self, *expected_args: Dict[Any, Any], **expected_kwargs: Any):
"""
Expand Down
2 changes: 1 addition & 1 deletion dirty_equals/_numeric.py
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ def __init__(self) -> None:

class IsNegativeFloat(IsFloat):
"""
Like [`IsNegative`][dirty_equals.IsNegative] but only for `float`s.
Like [`IsNegative`](#isnegative) but only for `float`s.
```py title="IsNegativeFloat"
from decimal import Decimal
Expand Down
6 changes: 4 additions & 2 deletions dirty_equals/_other.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,12 @@ class IsJson(DirtyEquals[JsonType]):
"""

@overload
def __init__(self, expected_value: JsonType = AnyJson): ...
def __init__(self, expected_value: JsonType = AnyJson):
...

@overload
def __init__(self, **expected_kwargs: Any): ...
def __init__(self, **expected_kwargs: Any):
...

def __init__(self, expected_value: JsonType = AnyJson, **expected_kwargs: Any):
"""
Expand Down
14 changes: 9 additions & 5 deletions dirty_equals/_sequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ class HasLen(DirtyEquals[Sized]):
"""

@overload
def __init__(self, length: int): ...
def __init__(self, length: int):
...

@overload
def __init__(self, min_length: int, max_length: Union[int, Any]): ...
def __init__(self, min_length: int, max_length: Union[int, Any]):
...

def __init__(self, min_length: int, max_length: Union[None, int, Any] = None): # type: ignore[misc]
"""
Expand All @@ -43,7 +45,7 @@ def __init__(self, min_length: int, max_length: Union[None, int, Any] = None):
4. Length is required but can take any value.
"""
if max_length is None:
self.length: LengthType = min_length
self.length: 'LengthType' = min_length
super().__init__(self.length)
else:
self.length = (min_length, max_length)
Expand Down Expand Up @@ -90,10 +92,12 @@ class IsListOrTuple(DirtyEquals[T]):
allowed_type: Union[Type[T], Tuple[Type[List[Any]], Type[Tuple[Any, ...]]]] = (list, tuple)

@overload
def __init__(self, *items: Any, check_order: bool = True, length: 'LengthType' = None): ...
def __init__(self, *items: Any, check_order: bool = True, length: 'LengthType' = None):
...

@overload
def __init__(self, positions: Dict[int, Any], length: 'LengthType' = None): ...
def __init__(self, positions: Dict[int, Any], length: 'LengthType' = None):
...

def __init__(
self,
Expand Down
4 changes: 0 additions & 4 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,6 @@ plugins:
merge_init_into_class: true
show_signature_annotations: true
separate_signature: true
signature_crossrefs: true
import:
- url: https://docs.python.org/3/objects.inv
- url: https://docs.pydantic.dev/latest/objects.inv
- mkdocs-simple-hooks:
hooks:
on_pre_build: 'docs.plugins:on_pre_build'
Expand Down
12 changes: 7 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,16 @@ Changelog = 'https://github.com/samuelcolvin/dirty-equals/releases'

[tool.ruff]
line-length = 120
lint.extend-select = ['Q', 'RUF100', 'C90', 'UP', 'I']
lint.ignore = ['E721']
lint.flake8-quotes = {inline-quotes = 'single', multiline-quotes = 'double'}
lint.mccabe = { max-complexity = 14 }
lint.pydocstyle = { convention = 'google' }
extend-select = ['Q', 'RUF100', 'C90', 'UP', 'I']
flake8-quotes = {inline-quotes = 'single', multiline-quotes = 'double'}
mccabe = { max-complexity = 14 }
isort = { known-first-party = ['tests'] }
format.quote-style = 'single'
target-version = 'py38'

[tool.ruff.pydocstyle]
convention = 'google'

[tool.pytest.ini_options]
testpaths = "tests"
filterwarnings = "error"
Expand Down
76 changes: 33 additions & 43 deletions requirements/docs.txt
Original file line number Diff line number Diff line change
@@ -1,132 +1,122 @@
#
# This file is autogenerated by pip-compile with Python 3.12
# This file is autogenerated by pip-compile with Python 3.11
# by the following command:
#
# pip-compile --constraint=requirements/linting.txt --constraint=requirements/tests.txt --output-file=requirements/docs.txt requirements/docs.in
#
babel==2.16.0
babel==2.13.1
# via mkdocs-material
certifi==2024.7.4
certifi==2023.7.22
# via requests
charset-normalizer==3.3.2
# via requests
click==8.1.7
# via
# -c requirements/tests.txt
# mkdocs
# mkdocstrings
colorama==0.4.6
# via
# griffe
# mkdocs-material
ghp-import==2.1.0
# via mkdocs
griffe==0.48.0
griffe==0.38.0
# via mkdocstrings-python
idna==3.7
idna==3.4
# via requests
importlib-metadata==8.2.0
importlib-metadata==6.8.0
# via mike
importlib-resources==6.4.0
importlib-resources==6.1.1
# via mike
jinja2==3.1.4
jinja2==3.1.2
# via
# mike
# mkdocs
# mkdocs-material
# mkdocstrings
markdown==3.6
markdown==3.5.1
# via
# mkdocs
# mkdocs-autorefs
# mkdocs-material
# mkdocstrings
# pymdown-extensions
markupsafe==2.1.5
markupsafe==2.1.3
# via
# jinja2
# mkdocs
# mkdocs-autorefs
# mkdocstrings
mergedeep==1.3.4
# via
# mkdocs
# mkdocs-get-deps
mike==2.1.3
# via mkdocs
mike==2.0.0
# via -r requirements/docs.in
mkdocs==1.6.0
mkdocs==1.5.3
# via
# -r requirements/docs.in
# mike
# mkdocs-autorefs
# mkdocs-material
# mkdocs-simple-hooks
# mkdocstrings
mkdocs-autorefs==1.0.1
mkdocs-autorefs==0.5.0
# via mkdocstrings
mkdocs-get-deps==0.2.0
# via mkdocs
mkdocs-material==9.5.31
mkdocs-material==9.4.8
# via -r requirements/docs.in
mkdocs-material-extensions==1.3.1
mkdocs-material-extensions==1.3
# via mkdocs-material
mkdocs-simple-hooks==0.1.5
# via -r requirements/docs.in
mkdocstrings[python]==0.25.2
mkdocstrings[python]==0.23.0
# via
# -r requirements/docs.in
# mkdocstrings-python
mkdocstrings-python==1.10.7
mkdocstrings-python==1.7.4
# via mkdocstrings
packaging==24.1
packaging==23.2
# via
# -c requirements/tests.txt
# mkdocs
paginate==0.5.6
# via mkdocs-material
pathspec==0.12.1
pathspec==0.11.2
# via
# -c requirements/tests.txt
# mkdocs
platformdirs==4.2.2
platformdirs==4.0.0
# via
# -c requirements/tests.txt
# mkdocs-get-deps
# mkdocstrings
pygments==2.18.0
# mkdocs
pygments==2.16.1
# via
# -c requirements/tests.txt
# mkdocs-material
pymdown-extensions==10.9
pymdown-extensions==10.4
# via
# mkdocs-material
# mkdocstrings
pyparsing==3.1.2
pyparsing==3.1.1
# via mike
python-dateutil==2.9.0.post0
python-dateutil==2.8.2
# via ghp-import
pyyaml==6.0.2
pyyaml==6.0.1
# via
# mike
# mkdocs
# mkdocs-get-deps
# pymdown-extensions
# pyyaml-env-tag
pyyaml-env-tag==0.1
# via
# mike
# mkdocs
regex==2024.7.24
# via mkdocs
regex==2023.10.3
# via mkdocs-material
requests==2.32.3
requests==2.31.0
# via mkdocs-material
six==1.16.0
# via python-dateutil
urllib3==2.2.2
urllib3==2.1.0
# via requests
verspec==0.1.0
# via mike
watchdog==4.0.2
watchdog==3.0.0
# via mkdocs
zipp==3.20.0
zipp==3.17.0
# via importlib-metadata
16 changes: 8 additions & 8 deletions requirements/linting.txt
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
#
# This file is autogenerated by pip-compile with Python 3.12
# This file is autogenerated by pip-compile with Python 3.11
# by the following command:
#
# pip-compile --output-file=requirements/linting.txt requirements/linting.in
#
annotated-types==0.7.0
annotated-types==0.6.0
# via pydantic
mypy==1.11.1
mypy==1.7.0
# via -r requirements/linting.in
mypy-extensions==1.0.0
# via mypy
pydantic==2.8.2
pydantic==2.4.2
# via -r requirements/linting.in
pydantic-core==2.20.1
pydantic-core==2.10.1
# via pydantic
ruff==0.5.7
ruff==0.1.5
# via -r requirements/linting.in
types-pytz==2024.1.0.20240417
types-pytz==2023.3.1.1
# via -r requirements/linting.in
typing-extensions==4.12.2
typing-extensions==4.8.0
# via
# mypy
# pydantic
Expand Down
10 changes: 5 additions & 5 deletions requirements/pyproject.txt
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
#
# This file is autogenerated by pip-compile with Python 3.12
# This file is autogenerated by pip-compile with Python 3.11
# by the following command:
#
# pip-compile --constraint=requirements/docs.txt --constraint=requirements/linting.txt --constraint=requirements/tests.txt --extra=pydantic --output-file=requirements/pyproject.txt pyproject.toml
#
annotated-types==0.7.0
annotated-types==0.6.0
# via
# -c requirements/linting.txt
# pydantic
pydantic==2.8.2
pydantic==2.4.2
# via
# -c requirements/linting.txt
# dirty-equals (pyproject.toml)
pydantic-core==2.20.1
pydantic-core==2.10.1
# via
# -c requirements/linting.txt
# pydantic
typing-extensions==4.12.2
typing-extensions==4.8.0
# via
# -c requirements/linting.txt
# pydantic
Expand Down
Loading

0 comments on commit 2b7c8fa

Please sign in to comment.