diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ad4dd426e..7e85ea7c3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,6 +24,8 @@ jobs: steps: - uses: actions/checkout@v4 + with: + persist-credentials: false - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 @@ -78,6 +80,8 @@ jobs: steps: - uses: actions/checkout@v4 + with: + persist-credentials: false - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4b54702a9..193bf6cfc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -19,6 +19,10 @@ repos: rev: v1.7.5 hooks: - id: actionlint + - repo: https://github.com/woodruffw/zizmor-pre-commit + rev: v0.8.0 + hooks: + - id: zizmor - repo: https://github.com/shellcheck-py/shellcheck-py rev: v0.10.0.1 hooks: @@ -33,7 +37,18 @@ repos: - id: ruff args: ["--exit-non-zero-on-fix", "--fix"] - id: ruff-format -exclude: ^(tests/fixtures/|tests/test_formatter/__snapshots__/) + - repo: https://github.com/sphinx-contrib/sphinx-lint + rev: v1.0.0 + hooks: + - id: sphinx-lint + args: [--enable=default-role] + files: ^docs/ + + # Should be the last: + - repo: meta + hooks: + - id: check-useless-excludes + ci: autofix_commit_msg: "[pre-commit.ci] auto fixes from pre-commit.com hooks" autofix_prs: true diff --git a/docs/pages/curry.rst b/docs/pages/curry.rst index 8661f3df0..ac8ee62b0 100644 --- a/docs/pages/curry.rst +++ b/docs/pages/curry.rst @@ -255,8 +255,8 @@ See ``Limitations`` in the API Reference. FAQ --- -Why don't you support `*` and `**` arguments? -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Why don't you support ``*`` and ``**`` arguments? +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ When you use ``partial(some, *my_args)`` or ``partial(some, **my_args)`` or both of them at the same time, diff --git a/docs/pages/future.rst b/docs/pages/future.rst index 0eb3662da..599955d69 100644 --- a/docs/pages/future.rst +++ b/docs/pages/future.rst @@ -12,7 +12,7 @@ What problems do we solve with these containers? Basically these ones: 1. You cannot call async function from a sync one 2. Any unexpectedly thrown exception can ruin your whole event loop -3. Ugly composition with lots of `await` statements +3. Ugly composition with lots of ``await`` statements Future container diff --git a/docs/pages/result.rst b/docs/pages/result.rst index 5745044d6..7d6ddcdd6 100644 --- a/docs/pages/result.rst +++ b/docs/pages/result.rst @@ -99,7 +99,7 @@ use :func:`future_safe ` instead. >>> str(divide(0)) '' -If you want to `safe` handle only a set of exceptions: +If you want ``@safe`` to handle only a set of exceptions: .. code:: python