Skip to content

Commit

Permalink
Dev (#176)
Browse files Browse the repository at this point in the history
- Added `tox` for local testing
- Updated dependencies
- Updated ruff (Hence, every file has been touched)
  • Loading branch information
Buried-In-Code committed Mar 16, 2024
1 parent 0d530cc commit 7398bc0
Show file tree
Hide file tree
Showing 38 changed files with 345 additions and 366 deletions.
9 changes: 3 additions & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.292
rev: v0.3.2
hooks:
- id: ruff-format
- id: ruff
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
Expand All @@ -14,7 +15,7 @@ repos:
- --number
- --wrap=keep
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.5.0
hooks:
- id: check-ast
- id: check-builtin-literals
Expand All @@ -38,10 +39,6 @@ repos:
- id: trailing-whitespace
args:
- --markdown-linebreak-ext=md
- repo: https://github.com/psf/black
rev: 23.9.1
hooks:
- id: black
- repo: https://github.com/pappasam/toml-sort
rev: v0.23.1
hooks:
Expand Down
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ version: 2
build:
os: ubuntu-22.04
tools:
python: "3.11"
python: "3.12"

mkdocs:
configuration: mkdocs.yaml
Expand Down
File renamed without changes.
56 changes: 31 additions & 25 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ classifiers = [
"Typing :: Typed"
]
dependencies = [
"pydantic >= 2.4.2",
"eval-type-backport >= 0.1.3; python_version < \"3.10\"",
"pydantic >= 2.6.4",
"ratelimit >= 2.2.1",
"requests >= 2.31.0"
]
Expand All @@ -42,18 +43,18 @@ requires-python = ">= 3.8"

[project.optional-dependencies]
dev = [
"pre-commit >= 3.4.0"
"pre-commit >= 3.5.0"
]
docs = [
"mkdocs >= 1.5.3",
"mkdocs-include-markdown-plugin >= 6.0.1",
"mkdocs-material >= 9.4.4",
"mkdocstrings[python] >= 0.23.0"
"mkdocs-include-markdown-plugin >= 6.0.4",
"mkdocs-material >= 9.5.13",
"mkdocstrings[python] >= 0.24.1"
]
test = [
"pytest >= 7.4.2",
"pytest >= 8.1.1",
"pytest-cov >= 4.1.0",
"pytest-pretty >= 1.2.0"
"tox >= 4.14.1"
]

[project.urls]
Expand All @@ -62,10 +63,6 @@ Homepage = "https://pypi.org/project/Simyan"
Issues = "https://github.com/Metron-Project/Simyan/issues"
Source = "https://github.com/Metron-Project/Simyan"

[tool.black]
line-length = 100
target-version = ["py310", "py311", "py312", "py38", "py39"]

[tool.coverage.report]
show_missing = true

Expand All @@ -80,38 +77,47 @@ addopts = ["--cov"]

[tool.ruff]
fix = true
line-length = 100
output-format = "grouped"
show-fixes = true
unsafe-fixes = true

[tool.ruff.format]
docstring-code-format = true
line-ending = "native"
skip-magic-trailing-comma = true

[tool.ruff.lint]
ignore = [
"COM812",
"D107",
"EXE",
"FBT",
"PLR2004",
"TCH"
]
line-length = 100
output-format = "grouped"
ignore-init-module-imports = true
select = ["ALL"]
show-fixes = true
target-version = "py38"

[tool.ruff.flake8-annotations]
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true
mypy-init-return = true

[tool.ruff.flake8-tidy-imports]
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"

[tool.ruff.isort]
combine-as-imports = true
[tool.ruff.lint.flake8-unused-arguments]
ignore-variadic-names = true

[tool.ruff.mccabe]
max-complexity = 18
[tool.ruff.lint.isort]
combine-as-imports = true
split-on-trailing-comma = false

[tool.ruff.pep8-naming]
[tool.ruff.lint.pep8-naming]
classmethod-decorators = ["classmethod", "pydantic.field_validator"]

[tool.ruff.per-file-ignores]
"simyan/schemas/*.py" = ["FA100"]
[tool.ruff.lint.per-file-ignores]
"tests/test_*.py" = ["S101"]

[tool.ruff.pydocstyle]
[tool.ruff.lint.pydocstyle]
convention = "google"
3 changes: 2 additions & 1 deletion simyan/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""simyan package entry file."""
__version__ = "1.2.0"

__all__ = ["__version__", "get_cache_root"]
__version__ = "1.2.1"

import os
from pathlib import Path
Expand Down

0 comments on commit 7398bc0

Please sign in to comment.