v1.8.2 — rate-limit auto-retry + release workflow improvements#104
v1.8.2 — rate-limit auto-retry + release workflow improvements#104
Conversation
|
Coverage after merging release/1.8.2 into main will be
Coverage Report
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
🔦 Lighthouse Report
|
There was a problem hiding this comment.
Pull request overview
Prepares the v1.8.2 release by bumping the package version, adding release documentation (blog/changelog), and updating release workflow guidance (avoid bun pm version, require interactive user input before drafting blog posts).
Changes:
- Bump
package.jsonversion to1.8.2. - Add v1.8.2 release blog post and link it from the blog index + changelog.
- Update release/process instructions to avoid
bun pm versionand to require interactive user confirmation before writing blog posts.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
| package.json | Version bump to 1.8.2. |
| docs/blog/release-v1-8-2.md | New release post describing the v1.8.2 changes. |
| docs/blog/index.md | Adds v1.8.2 row linking to the new post. |
| CHANGELOG.md | Adds v1.8.2 row pointing to the blog post. |
| AGENTS.md | Updates release steps (manual version edit) + blog-post interaction requirement. |
| .github/skills/release.md | Documents version bump approach + blog-post interaction requirement. |
| .github/instructions/release.instructions.md | Updates Copilot release instructions (manual version edit + interaction requirement). |
| .github/instructions/implement-feature.instructions.md | Updates post-merge release guidance (manual version edit + interaction requirement). |
| .github/instructions/bug-fixing.instructions.md | Updates patch release guidance (manual version edit + interaction requirement). |
| # automatically, which conflicts with the release workflow below. | ||
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json |
There was a problem hiding this comment.
sed -i '' is BSD/macOS-specific and fails on GNU sed (common on Linux CI/dev machines). Consider documenting a cross-platform version bump command (e.g. use sed -i.bak … and remove the backup, or use a small Node/Bun script), or explicitly provide both macOS and Linux variants.
| # automatically, which conflicts with the release workflow below. | |
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json | |
| # automatically, which conflicts with the release workflow below. | |
| # macOS (BSD sed) | |
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json | |
| # Linux (GNU sed) | |
| sed -i 's/"version": ".*"/"version": "X.Y.Z"/' package.json |
| # Option A — in-place sed (reliable, no interactive editor needed) | ||
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json |
There was a problem hiding this comment.
This in-place sed -i '' example is macOS/BSD-specific and will break on GNU sed. Since this is meant to be “reliable”, it should either be made portable or split into explicit macOS and Linux instructions.
| # Option A — in-place sed (reliable, no interactive editor needed) | |
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json | |
| # Option A — non-interactive sed (no editor needed) | |
| # macOS / BSD sed: | |
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json | |
| # GNU sed (Linux): | |
| sed -i 's/"version": ".*"/"version": "X.Y.Z"/' package.json |
| # or | ||
| bun pm version major # breaking change: 1.2.4 → 2.0.0 | ||
|
|
||
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json # bump directly — do NOT use bun pm version |
There was a problem hiding this comment.
The documented version bump command uses sed -i '', which is not portable to GNU sed (Linux). Please adjust the instructions to a cross-platform approach or provide OS-specific variants.
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json # bump directly — do NOT use bun pm version | |
| jq '.version = "X.Y.Z"' package.json > package.tmp.json && mv package.tmp.json package.json # bump directly — do NOT use bun pm version |
|
|
||
| ```bash | ||
| bun pm version patch # bumps package.json: 1.2.4 → 1.2.5 | ||
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json # bump directly — do NOT use bun pm version |
There was a problem hiding this comment.
The release command uses sed -i '', which is BSD/macOS-specific and can fail on GNU sed. Please provide a portable alternative or separate commands for macOS vs Linux.
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json # bump directly — do NOT use bun pm version | |
| tmpfile="$(mktemp)" | |
| jq '.version = "X.Y.Z"' package.json > "$tmpfile" && mv "$tmpfile" package.json # bump directly — do NOT use bun pm version |
| - **Auto-wait with visible feedback.** When a rate-limit response is received | ||
| during pagination, the CLI now prints a message, waits for the exact duration | ||
| indicated by GitHub (`x-ratelimit-reset` or `Retry-After` + 1 s clock-skew | ||
| buffer), and resumes automatically — no retry counting, no data lost: |
There was a problem hiding this comment.
The release notes claim multi-page searches now auto-wait and resume on long rate-limit delays, but the current implementation of fetchWithRetry still throws when the computed delay exceeds MAX_AUTO_RETRY_WAIT_MS (10s) and there is no onRateLimit callback support in the codebase. Either include the rate-limit retry implementation changes in this PR, or adjust the release post to match the actual shipped behavior.
| ``` | ||
| Fetching results from GitHub… ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░░ page 9/10 | ||
| error: GitHub API rate limit exceeded. Please retry in 53 seconds. | ||
| ``` |
There was a problem hiding this comment.
This fenced code block is missing a language identifier. The docs guidelines for this repo require every code block to declare its language (e.g. text for CLI output).
| ``` | ||
| Fetching results from GitHub… ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░░ page 9/10 | ||
| Rate limited — waiting 53 seconds, resuming automatically… | ||
| Fetching results from GitHub… ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ page 10/10 | ||
| ``` |
There was a problem hiding this comment.
This fenced code block is missing a language identifier. Please add one (likely text) so the docs conform to the repo convention of language-tagged code fences.
| { | ||
| "name": "github-code-search", | ||
| "version": "1.8.1", | ||
| "version": "1.8.2", |
There was a problem hiding this comment.
The version is bumped to v1.8.2 here, but the PR description/release notes mention rate-limit auto-retry changes (e.g. onRateLimit callback, secondary rate-limit detection) that are not present in the current source (src/api-utils.ts still throws for waits > 10s). Either include the implementation changes in this PR, or delay the version bump/release artifacts until the code changes are actually included.
| ```bash | ||
| # Bump directly in package.json | ||
| sed -i '' 's/"version": ".*"/"version": "X.Y.Z"/' package.json | ||
|
|
||
| # Verify | ||
| jq -r .version package.json | ||
| ``` |
There was a problem hiding this comment.
The suggested sed -i '' command is not portable (GNU sed on Linux treats '' differently and often errors). Please update this section to include a cross-platform approach or separate macOS vs Linux commands.
Patch release for #102: rate-limit errors aborting multi-page searches. Also: - Add docs/blog/release-v1-8-2.md and update docs/blog/index.md - Replace \`bun pm version\` with direct package.json editing across all release instructions, skills and AGENTS.md (\`bun pm version\` auto-creates a git commit and tag, which conflicts with the release workflow) - Add explicit "ask the user interactively" requirement before writing any release blog post in AGENTS.md, release.instructions.md, skills/release.md, bug-fixing.instructions.md and implement-feature.instructions.md
|
Coverage after merging release/1.8.2 into main will be
Coverage Report
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
What's in this release
Patch: fix rate-limit errors aborting multi-page searches (closes #102)
See #103 for the detailed root cause. Three fixes:
fetchWithRetrynow calls anonRateLimitcallback (instead of throwing) when a long wait is needed during pagination — the search pauses with a visible message and resumes automatically.403 + Retry-After) are now detected and retried.fetchAllResultsto prevent the422 Cannot access beyond the first 1000 resultserror when results hit exactly 1 000.Release workflow improvements
Replace
bun pm versionwith directpackage.jsonediting across all release instructions, skills andAGENTS.md.bun pm versionautomatically creates both a git commit and a git tag in one shot, which conflicts with the workflow (tag must be pushed from the release branch after blog post and CHANGELOG are ready).Add "ask the user interactively" requirement before writing any release blog post in
AGENTS.md,release.instructions.md,skills/release.md,bug-fixing.instructions.md, andimplement-feature.instructions.md.Docs
docs/blog/release-v1-8-2.md— patch release notes.docs/blog/index.md— new row for v1.8.2.CHANGELOG.md— new row for v1.8.2.Post-merge
The tag push triggers
cd.yaml(build + GitHub Release).