Skip to content

[api-v3] INTER-2472: Update schema URL and harden sync script - #235

Merged
erayaydin merged 1 commit into
api-v3from
chore/openapi-repo-rename-api-v3-inter-2472
Sep 29, 2026
Merged

erayaydin merged 1 commit into
api-v3from
chore/openapi-repo-rename-api-v3-inter-2472

Conversation

@erayaydin

@erayaydin erayaydin commented Sep 24, 2026 •

Copy link
Copy Markdown
Member

GitHub redirects repository URLs after a rename but explicitly not project GitHub Pages URLs, so sync.sh will start failing after the rename. This PR changes the default OpenAPI schema URL.

curl ran without -f, which made that failure silent. With -f the same request exits 56 and leaves the existing file untouched.

Alongside the URL change, use env bash shebang, so the script picks up bash from the correct environment. Resolve paths relative to the repository root, so the script no longer writes into whatever directory it is invoked from. Collect the curl flags into CURL_OPTS, gated on TRACE and ACTIONS_STEP_DEBUG so runs can be made verbose, and add hardening to refuse redirects that leave https and bound connect and transfer time so a stalled download cannot hang CI or local. Log the download.

Inline the base URL into schemaUrl.

Update the OpenAPI schema URL.

Use an `env bash` shebang so the script picks up bash from PATH rather than
whatever sits at /bin/bash. Resolve paths relative to the repository root, so
the script no longer writes into whatever directory it is invoked from.

Collect the curl flags into `CURL_OPTS`, gated on `TRACE` and
`ACTIONS_STEP_DEBUG` so runs can be made verbose, and add hardening: refuse
redirects that leave https, and bound connect and transfer time so a stalled
download cannot hang CI or a local run. Log the download.

Inline the base URL into `schemaUrl`.

Related-Task: INTER-2472
@erayaydin
erayaydin requested a balanced review from Copilot September 24, 2026 19:55
@erayaydin erayaydin self-assigned this Sep 24, 2026
@github-actions

Copy link
Copy Markdown
Contributor

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
6299 5290 84% 0% 🟢

New Files

No new covered files...

Modified Files

No covered modified files...

updated for commit: 1fe455e by action🐍

@github-actions

Copy link
Copy Markdown
Contributor

⚠️ This PR doesn't contain any changesets. If there are user-facing changes, don't forget to run:

pnpm exec changeset

to create a changeset.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Interrupted transfers can overwrite the valid schema with partial content, and the prerequisite repository rename remains incomplete.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
What changed in this PR

Updates schema synchronization for the planned OpenAPI repository rename while improving script portability and curl safeguards.

Changes:

  • Updates the default schema URL.
  • Resolves paths from the repository root.
  • Adds curl failure handling, timeouts, retries, and configurable verbosity.
File Description
sync.sh Hardens schema downloading and updates its source URL.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread sync.sh
@erayaydin
erayaydin marked this pull request as ready for review September 25, 2026 09:05
@erayaydin erayaydin changed the title [DO NOT MERGE] [api-v3] INTER-2472: Update schema URL and harden sync script [api-v3] INTER-2472: Update schema URL and harden sync script Sep 29, 2026
@erayaydin
erayaydin merged commit eba4005 into api-v3 Sep 29, 2026
23 checks passed
@erayaydin
erayaydin deleted the chore/openapi-repo-rename-api-v3-inter-2472 branch September 29, 2026 11:05

This branch was successfully deployed

1 active deployment
test — 1fe455e8 Deployed Sep 24, 2026 by erayaydin via Functional tests for Python 3.12 #1783
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants