-
Notifications
You must be signed in to change notification settings - Fork 3
Update github workflows & precommit to use pinned hashes instead of tags #170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
961b158
e15710e
29ea5b2
bc91b1d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,20 +10,22 @@ | |
| # add these directories to sys.path here. If the directory is relative to the | ||
| # documentation root, use os.path.abspath to make it absolute, like shown here. | ||
| # | ||
| # import os | ||
| # import sys | ||
| # sys.path.insert(0, os.path.abspath('.')) | ||
|
|
||
| import sys | ||
| from pathlib import Path | ||
|
|
||
| sys.path.insert(0, str(Path().resolve())) | ||
|
|
||
| import undate | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Check ruff config for docs/conf.py exclusions or E402 handling
rg -n "E402|docs/conf.py|exclude" pyproject.toml .ruff.toml ruff.toml 2>/dev/nullRepository: dh-tech/undate-python Length of output: 159 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n== files ==\n'
git ls-files | sed -n '1,200p'
printf '\n== lint config search ==\n'
rg -n --hidden --glob '!**/.git/**' '(^|[^A-Za-z0-9_])E402([^A-Za-z0-9_]|$)|docs/conf\.py|exclude|extend-exclude|per-file-ignores|ignore\s*=' pyproject.toml .ruff.toml ruff.toml setup.cfg tox.ini noxfile.py .pre-commit-config.yaml .github/workflows 2>/dev/null || true
printf '\n== docs/conf.py ==\n'
if [ -f docs/conf.py ]; then
cat -n docs/conf.py | sed -n '1,120p'
fi
printf '\n== ruff/flake8 related files ==\n'
fd -a 'pyproject.toml|.ruff.toml|ruff.toml|setup.cfg|tox.ini|noxfile.py|pre-commit-config.yaml' . 2>/dev/null || trueRepository: dh-tech/undate-python Length of output: 7471 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n== docs/conf.py path status ==\n'
if [ -f docs/conf.py ]; then
wc -l docs/conf.py
sed -n '1,80p' docs/conf.py | cat -n
else
echo "docs/conf.py not found"
fi
printf '\n== search for lint config and CI lint invocations ==\n'
rg -n --hidden --glob '!**/.git/**' \
'ruff|flake8|pyproject\.toml|\.ruff\.toml|ruff\.toml|E402|per-file-ignores|extend-exclude|exclude|docs/conf\.py' \
.github pyproject.toml .ruff.toml ruff.toml setup.cfg tox.ini noxfile.py pre-commit-config.yaml 2>/dev/null || trueRepository: dh-tech/undate-python Length of output: 4224 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n== docs/conf.py ==\n'
if [ -f docs/conf.py ]; then
wc -l docs/conf.py
sed -n '1,120p' docs/conf.py | cat -n
else
echo "docs/conf.py not found"
fi
printf '\n== config and CI search ==\n'
rg -n --hidden --glob '!**/.git/**' \
'ruff|flake8|E402|per-file-ignores|extend-exclude|exclude|docs/conf\.py' \
.github pyproject.toml .ruff.toml ruff.toml setup.cfg tox.ini noxfile.py .pre-commit-config.yaml 2>/dev/null || trueRepository: dh-tech/undate-python Length of output: 4675 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n== candidate config files ==\n'
git ls-files | rg '(^|/)(pyproject\.toml|\.ruff\.toml|ruff\.toml|setup\.cfg|tox\.ini|noxfile\.py|\.pre-commit-config\.yaml|\.github/workflows/.*\.(yml|yaml))$' || true
printf '\n== docs/conf.py excerpt ==\n'
if [ -f docs/conf.py ]; then
sed -n '1,80p' docs/conf.py | cat -n
fiRepository: dh-tech/undate-python Length of output: 3330 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n== pyproject.toml ruff section ==\n'
sed -n '100,170p' pyproject.toml | cat -n
printf '\n== workflow lint steps ==\n'
sed -n '1,220p' .github/workflows/check.yml | cat -n
printf '\n== pre-commit ruff entries ==\n'
sed -n '1,120p' .pre-commit-config.yaml | cat -nRepository: dh-tech/undate-python Length of output: 5062 Add an E402 exemption for this import. 🤖 Prompt for AI Agents |
||
|
|
||
| # -- Project information ----------------------------------------------------- | ||
|
|
||
| project = "undate" | ||
| copyright = "2024, DHtech" | ||
| copyright = "2026, DHtech" | ||
| author = "DHtech Community" | ||
|
|
||
| # The full version, including alpha/beta/rc tags | ||
| release = undate.__version__ | ||
| release = undate.__version__ # type: ignore[attr-defined] | ||
|
|
||
| master_doc = "index" | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: dh-tech/undate-python
Length of output: 760
Anchor the Sphinx source path to
docs/conf.pyPath().resolve()depends on the current working directory, so this can adddocs/instead of the project root when Sphinx runs from that directory. That makesimport undatefail unless the package is already installed.🛠️ Suggested fix
📝 Committable suggestion
🤖 Prompt for AI Agents