-
Notifications
You must be signed in to change notification settings - Fork 1
Feat: Unbounded Dependency Pins in requirements.txt (Closes #47)
#53
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
Merged
Merged
Changes from 3 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
dd36d08
feat: initial implement with dependabot + test + update-lock actions.
bradjin8 623370c
fix: create-pull-request v7; pillow version to 12
bradjin8 2a135d7
fix: review comments
bradjin8 c03ff00
fix issues after changing
bradjin8 7926293
refactor: eliminate remaining duplications from export pipeline
bradjin8 f8ebf5d
Revert "refactor: eliminate remaining duplications from export pipeline"
bradjin8 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| version: 2 | ||
| updates: | ||
| # Keep GitHub Actions pinned to immutable commit SHAs up-to-date. | ||
| # Dependabot opens a PR whenever a newer SHA is available for a pinned action. | ||
| - package-ecosystem: "github-actions" | ||
| directory: "/" | ||
| schedule: | ||
| interval: "weekly" | ||
| day: "monday" | ||
| labels: | ||
| - "dependencies" | ||
|
|
||
| # Keep Python runtime dependencies up-to-date within the bounded ranges in | ||
| # pyproject.toml [project.dependencies] (requirements.txt must stay in sync). | ||
| # Dependabot opens a PR when a newer version fits those bounds — it does NOT | ||
| # refresh requirements-lock.txt. CI installs from the lock, so after merging a | ||
| # Dependabot pip PR you must regenerate the lock: run the "Update dependency | ||
| # lock file" workflow (Actions tab) or pip-compile locally (see README). | ||
| - package-ecosystem: "pip" | ||
| directory: "/" | ||
| schedule: | ||
| interval: "weekly" | ||
| day: "monday" | ||
| labels: | ||
| - "dependencies" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,71 @@ | ||
| name: Update dependency lock file | ||
|
|
||
| on: | ||
| # Run every Monday at 08:00 UTC — picks up upstream patch / security | ||
| # releases that land within the bounded ranges in requirements.txt. | ||
| schedule: | ||
| - cron: "0 8 * * 1" | ||
| # Allow manual trigger from the Actions tab for ad-hoc refreshes. | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
|
|
||
| jobs: | ||
| update-lock: | ||
| name: Regenerate requirements-lock.txt | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | ||
|
|
||
| - name: Set up Python | ||
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 | ||
| with: | ||
| python-version: "3.12" | ||
|
|
||
| - name: Install pip-tools | ||
| run: python -m pip install pip-tools | ||
|
coderabbitai[bot] marked this conversation as resolved.
Outdated
|
||
|
|
||
| - name: Regenerate lock file | ||
| run: | | ||
| pip-compile requirements.txt \ | ||
| --output-file requirements-lock.txt \ | ||
| --no-header \ | ||
| --annotation-style=line \ | ||
| --allow-unsafe \ | ||
| --upgrade | ||
|
|
||
| - name: Prepend lock file header | ||
| # pip-compile --no-header strips our docs header every run; restore via | ||
| # heredoc (single-quoted HEADER=... would leave literal \n characters). | ||
| run: | | ||
| cat > /tmp/lock-header <<'EOF' | ||
| # Pinned lock file — generated by pip-compile (pip-tools). | ||
| # Install: pip install -r requirements-lock.txt | ||
| # Update: pip-compile requirements.txt --output-file requirements-lock.txt --no-header --annotation-style=line --allow-unsafe | ||
| # Run periodically (e.g. via the "Update dependency lock file" CI workflow) to pick up | ||
| # upstream patch / security releases within the bounded ranges in requirements.txt. | ||
| EOF | ||
| cat /tmp/lock-header requirements-lock.txt > /tmp/lock.tmp | ||
| mv /tmp/lock.tmp requirements-lock.txt | ||
|
|
||
| - name: Open PR if lock file changed | ||
| uses: peter-evans/create-pull-request@22a9089034f40e5a961c8808d113e2c98fb63676 # v7 | ||
| with: | ||
| commit-message: "chore: update requirements-lock.txt" | ||
| branch: "chore/update-lock-file" | ||
| delete-branch: true | ||
| title: "chore: update dependency lock file" | ||
| body: | | ||
| Automated weekly refresh of `requirements-lock.txt`. | ||
|
|
||
| Generated by `pip-compile --upgrade` from the bounded specifiers | ||
| in `requirements.txt` (must match `pyproject.toml` `[project.dependencies]`). | ||
|
|
||
| **Dependabot pip PRs** may bump bounds in `requirements.txt` / `pyproject.toml` | ||
| but do not regenerate this lock file — merge those first, then merge this PR | ||
| (or run **Actions → Update dependency lock file → Run workflow**). | ||
|
|
||
| Review the diff to confirm no unexpected major-version jumps before merging. | ||
| labels: dependencies | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| # Pinned lock file — generated by pip-compile (pip-tools). | ||
| # Install: pip install -r requirements-lock.txt | ||
| # Update: pip-compile requirements.txt --output-file requirements-lock.txt --no-header --annotation-style=line --allow-unsafe | ||
| # Run periodically (e.g. via the "Update dependency lock file" CI workflow) to pick up | ||
| # upstream patch / security releases within the bounded ranges in requirements.txt. | ||
| blinker==1.9.0 # via flask | ||
| click==8.4.0 # via flask | ||
| colorama==0.4.6 # via click | ||
| defusedxml==0.7.1 # via fpdf2 | ||
| flask==3.1.3 # via -r requirements.txt | ||
| fonttools==4.63.0 # via fpdf2 | ||
| fpdf2==2.8.7 # via -r requirements.txt | ||
| itsdangerous==2.2.0 # via flask | ||
| jinja2==3.1.6 # via flask | ||
| markupsafe==3.0.3 # via flask, jinja2, werkzeug | ||
| pillow==12.2.0 # via -r requirements.txt, fpdf2 | ||
| werkzeug==3.1.8 # via flask |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.