Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:

full-build:
name: Full 3.13 build
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/scheduled.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Scheduled to verify that tests pass with latest requirements.

name: scheduled
on:
schedule:
- cron: "0 8 * * *"

jobs:
auth-test:
name: Pytest suite
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.13"
- name: Install package
run: |
python -m pip install --upgrade pip
pip install -r requirements/dev
pip install .
- name: Run tox evironments
run: tox
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[build-system]
requires = ["setuptools>=61.0", "wheel"]
requires = ["setuptools>=77.0", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "sphinx-codeautolink"
description = "Automatic links from code examples to reference documentation."
readme = "readme_pypi.rst"
license = {file = "LICENSE"}
license-files = ["LICENSE"]
dynamic = ["version"]

requires-python = ">=3.10"
Expand Down
2 changes: 1 addition & 1 deletion src/sphinx_codeautolink/extension/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def wrapper(*args, **kwargs):
source = doctree["source"]
msg = f"in document `{source}`"
if e.args:
e.args = (e.args[0] + f" ({msg})",) + e.args[1:]
e.args = (e.args[0] + f" ({msg})", *e.args[1:])
else:
e.args = (f"Unexpected error {msg}",)
raise
Expand Down
2 changes: 1 addition & 1 deletion src/sphinx_codeautolink/extension/block.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def _exclude_ipython_output(source: str) -> str:

def clean_ipython(source: str) -> tuple[str, str]:
"""Clean up IPython magics and console syntax to pure Python."""
from IPython.core.inputtransformer2 import TransformerManager
from IPython.core.inputtransformer2 import TransformerManager # noqa: PLC0415

clean = _exclude_ipython_output(source)
return source, TransformerManager().transform_cell(clean)
Expand Down
2 changes: 1 addition & 1 deletion tests/extension/src/future_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class Foo:
attr: str = "test"


def optional() -> Optional[Foo]: # noqa: UP007
def optional() -> Optional[Foo]: # noqa: UP045
"""Return optional type."""


Expand Down