Skip to content

pre-commit: Add ty for Python type hints #1

pre-commit: Add ty for Python type hints

pre-commit: Add ty for Python type hints #1

Triggered via pull request September 3, 2026 18:01
Status Failure
Total duration 15s
Artifacts

ruff_and_ty.yml

on: pull_request
ruff_and_ty
11s
ruff_and_ty
Fit to window
Zoom out
Zoom in

Annotations

10 errors
ty (unresolved-import): web_programming/co2_emission.py#L14
web_programming/co2_emission.py:14:8: unresolved-import: Cannot resolve imported module `httpx` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-attribute): scripts/validate_solutions.py#L34
scripts/validate_solutions.py:34:5: unresolved-attribute: Attribute `loader` is not defined on `None` in union `ModuleSpec | None`
ty (unresolved-attribute): scripts/validate_solutions.py#L34
scripts/validate_solutions.py:34:5: unresolved-attribute: Attribute `exec_module` is not defined on `None` in union `Loader | None`
ty (invalid-argument-type): scripts/validate_solutions.py#L33
scripts/validate_solutions.py:33:46: invalid-argument-type: Argument to function `module_from_spec` is incorrect: Expected `ModuleSpec`, found `ModuleSpec | None` info: element `None` of union `ModuleSpec | None` is not assignable to `ModuleSpec` stdlib/_frozen_importlib.pyi:45:5: info: Function defined here stdlib/_frozen_importlib.pyi:45:22: Parameter declared here
ty (unresolved-import): scripts/validate_solutions.py#L19
scripts/validate_solutions.py:19:8: unresolved-import: Cannot resolve imported module `pytest` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-import): scripts/validate_solutions.py#L18
scripts/validate_solutions.py:18:8: unresolved-import: Cannot resolve imported module `httpx` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-import): maths/test_factorial.py#L10
maths/test_factorial.py:10:6: unresolved-import: Cannot resolve imported module `maths.factorial` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-import): maths/test_factorial.py#L8
maths/test_factorial.py:8:8: unresolved-import: Cannot resolve imported module `pytest` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-import): machine_learning/linear_regression.py#L20
machine_learning/linear_regression.py:20:8: unresolved-import: Cannot resolve imported module `numpy` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment
ty (unresolved-import): machine_learning/linear_regression.py#L19
machine_learning/linear_regression.py:19:8: unresolved-import: Cannot resolve imported module `httpx` info: Searched in the following paths during module resolution: info: 1. vendored://stdlib (stdlib typeshed stubs vendored by ty) info: 2. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib/python3.12/site-packages (site-packages) info: 3. /home/runner/work/_temp/setup-uv-cache/archive-v0/KXNLqH_nw6tc5Kh-/lib64/python3.12/site-packages (site-packages) info: make sure your Python environment is properly configured: https://docs.astral.sh/ty/modules/#python-environment