Skip to content
Merged
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
10 changes: 8 additions & 2 deletions .github/workflows/branch-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -649,9 +649,13 @@ jobs:
- name: Reject changes to the Python SDK
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
# Compare against the PR head, not the checked-out merge commit: the
# recorded base SHA can lag main, and diffing the merge commit would
# then report main's own changes as the PR's.
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
set -euo pipefail
changed=$(git diff --name-only --diff-filter=d "${BASE_SHA}...HEAD" -- \
changed=$(git diff --name-only --diff-filter=d "${BASE_SHA}...${HEAD_SHA}" -- \
python \
tasks/scripts/generate_python_proto.py)
if [ -z "$changed" ]; then
Expand Down Expand Up @@ -695,11 +699,13 @@ jobs:
- name: Reject changes to the TypeScript SDK
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
# See the Python SDK freeze: diff the PR head, not the merge commit.
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
set -euo pipefail
# The package is a stub that re-exports @ai-openshell/sdk. Its files stay
# editable so the stub and its moved notice can be maintained.
changed=$(git diff --no-renames --name-only --diff-filter=d "${BASE_SHA}...HEAD" -- sdk/typescript \
changed=$(git diff --no-renames --name-only --diff-filter=d "${BASE_SHA}...${HEAD_SHA}" -- sdk/typescript \
':(exclude)sdk/typescript/package.json' \
':(exclude)sdk/typescript/README.md' \
':(exclude)sdk/typescript/index.js' \
Expand Down
Loading