mirror of
https://github.com/ivuorinen/aeonview.git
synced 2026-03-17 16:59:57 +00:00
refactor: modernize to Python 3 with OOP structure and comprehensive tests (#2)
* feat: full upgrade to python3, tests, etc. * chore: saving the wip state * chore(lint): fixed pyright errors, tests * chore(ci): install deps * chore(lint): fix linting * chore(lint): more linting fixes * chore(ci): upgrade workflows * fix(test): fix tests, tweak editorconfig * test: add helper path test and stub requests (#4) * fix: update paths and workflow (#5) * fix: update python version and improve cross-platform paths (#6) * fix: resolve MegaLinter YAML and markdown lint failures (#7) * fix: implement all CodeRabbit review comments (#8) * fix: apply CodeRabbit auto-fixes Fixed 3 file(s) based on 3 unresolved review comments. * fix: resolve MegaLinter editorconfig and pylint/pyright failures (#9) * feat: migrate to uv-managed project (#10) * feat: migrate to uv-managed project * fix: align Python version in pyproject.toml and CI setup-uv config * fix: ignore uv.lock in editorconfig, disable PYTHON_PYLINT/PYRIGHT in mega-linter, use uv for dep install (#11) * fix: ignore uv.lock in editorconfig and disable PYTHON_PYLINT/PYRIGHT in mega-linter * fix: update outdated comment in mega-linter config * fix: use uv instead of pip to install deps in mega-linter config * chore(deps): upgrade workflows * chore(ci): mega-linter config tweaks * chore(ci): mega-linter config tweaks * feat(deps): add pyright and pylint with non-overlapping config Add pyright>=1.1.0 and pylint>=3.0.0 as dev dependencies. Configure pyright for basic type checking (py3.13) and refine pylint message disables to avoid overlap with ruff's enabled rule sets. * feat(ci): re-enable pyright and pylint in mega-linter Remove PYTHON_PYLINT and PYTHON_PYRIGHT from DISABLE_LINTERS so mega-linter runs all three linters: ruff, pyright, and pylint. * fix: resolve pyright/pylint findings and apply ruff formatting Add encoding="utf-8" to read_text() calls in tests (pylint W1514). Apply ruff-format double-quote style consistently across both files. * chore(hooks): add editorconfig-checker and fix lines exceeding 80 chars Add editorconfig-checker pre-commit hook to catch line-length violations locally. Shorten docstrings in aeonview.py and aeonview_test.py that exceeded the 80-character editorconfig limit. Remove double-quote-string-fixer hook that conflicted with ruff-format. * fix(ci): configure mega-linter to use project configs for pyright/pylint Point mega-linter at pyproject.toml for both linters so they use our config instead of mega-linter's defaults. Add venvPath/venv to pyright so it resolves imports from the uv-created .venv. Disable pylint import-error since import checking is handled by pyright.
This commit is contained in:
70
pyproject.toml
Normal file
70
pyproject.toml
Normal file
@@ -0,0 +1,70 @@
|
||||
[project]
|
||||
name = "aeonview"
|
||||
version = "0.1.0"
|
||||
description = "A simple timelapse tool using ffmpeg and Python"
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.13.2"
|
||||
license = { text = "MIT" }
|
||||
authors = [{ name = "Ismo Vuorinen" }]
|
||||
dependencies = ["requests>=2.32.3"]
|
||||
|
||||
[dependency-groups]
|
||||
dev = [
|
||||
"pre-commit>=3.5.0",
|
||||
"pylint>=3.0.0",
|
||||
"pyright>=1.1.0",
|
||||
"pytest>=8.0.0",
|
||||
"pytest-cov>=4.1.0",
|
||||
"ruff>=0.3.3",
|
||||
]
|
||||
|
||||
[tool.ruff]
|
||||
line-length = 80
|
||||
target-version = "py313"
|
||||
|
||||
[tool.ruff.lint]
|
||||
select = ["E", "F", "I", "B", "UP", "C4", "T20"]
|
||||
ignore = ["E501"]
|
||||
|
||||
[tool.ruff.lint.per-file-ignores]
|
||||
"*_test.py" = ["S101"]
|
||||
|
||||
[tool.ruff.format]
|
||||
quote-style = "double"
|
||||
indent-style = "space"
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
testpaths = ["."]
|
||||
python_files = ["*_test.py"]
|
||||
|
||||
[tool.pyright]
|
||||
pythonVersion = "3.13"
|
||||
typeCheckingMode = "basic"
|
||||
venvPath = "."
|
||||
venv = ".venv"
|
||||
|
||||
[tool.pylint.MAIN]
|
||||
ignore-patterns = ["^\\.#"]
|
||||
ignore-paths = ["^\\.#"]
|
||||
ignore = ["CVS", ".venv"]
|
||||
|
||||
[tool.pylint."messages_control"]
|
||||
disable = [
|
||||
"attribute-defined-outside-init",
|
||||
"invalid-name",
|
||||
"missing-docstring",
|
||||
"protected-access",
|
||||
"too-many-instance-attributes",
|
||||
"too-few-public-methods",
|
||||
"format",
|
||||
"line-too-long",
|
||||
"ungrouped-imports",
|
||||
"wrong-import-order",
|
||||
"unused-import",
|
||||
"reimported",
|
||||
"consider-using-f-string",
|
||||
"unnecessary-comprehension",
|
||||
"use-a-generator",
|
||||
"consider-using-with",
|
||||
"import-error",
|
||||
]
|
||||
Reference in New Issue
Block a user