Skip to content

Fix JetBrains Runtime release pagination - #1218

Merged
brunoborges merged 3 commits into
actions:mainfrom
jdubois:jdubois-fix-jetbrains-pagination
Aug 5, 2026
Merged

brunoborges merged 3 commits into
actions:mainfrom
jdubois:jdubois-fix-jetbrains-pagination

Conversation

@jdubois

@jdubois jdubois commented Aug 5, 2026 •

Copy link
Copy Markdown
Contributor

Description:
Fix JetBrains Runtime release pagination so client-side stable/EA filtering cannot be mistaken for the end of the GitHub result set.

  • Follow GitHub's validated rel="next" link and stop only when the raw page is empty or GitHub provides no next page.
  • Continue after non-empty pages containing only the opposite release class.
  • Bound requests with MAX_PAGINATION_PAGES and warn if the limit is reached.
  • Preserve the existing stable/EA filter, hidden legacy releases, GITHUB_TOKEN behavior, asset probing, and platform/architecture mapping.
  • Add stable and EA regression cases plus raw-page termination, pagination-cap, and unexpected-origin coverage.
  • Regenerate dist/setup from the fork workflow's uploaded build artifact.

Related issue:
Closes #1215

Validation:

Check list:

  • Ran npm run check locally (format, lint, build, test) and all checks pass. (Blocked by the configured package proxy; equivalent validation passed on GitHub-hosted runners.)
  • Documentation changes are not required.
  • Tests were added or updated to cover the changes.
jdubois and others added 2 commits August 5, 2026 15:35
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@jdubois
jdubois requested a review from a team as a code owner August 5, 2026 13:37
Copilot AI lite review requested due to automatic review settings August 5, 2026 13:37

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.

Pull request overview

Fixes JetBrains Runtime release pagination so that stable/EA filtering does not incorrectly terminate pagination when a non-empty GitHub releases page contains only the opposite release class.

Changes:

  • Switch JetBrainsRuntime release listing to follow GitHub’s Link: rel="next" pagination instead of page= indexing, terminating only on an empty raw page or missing next link.
  • Add origin validation for pagination links and a MAX_PAGINATION_PAGES safeguard warning/termination.
  • Add regression tests covering stable-after-prerelease, EA-after-stable, raw empty-page termination, safeguard limit, and unexpected-origin pagination links; regenerate dist/setup.
Show a summary per file
File Description
src/distributions/jetbrains/installer.ts Implements rel="next"-driven pagination with origin validation and a page-count safeguard while preserving stable/EA filtering behavior.
tests/distributors/jetbrains-installer.test.ts Adds targeted regression tests to ensure pagination continues across non-matching pages and terminates only on true end-of-pagination conditions/safeguards.
dist/setup/282.index.js Regenerated build output reflecting the updated JetBrains pagination logic.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 2/3 changed files
  • Comments generated: 0
  • Review effort level: Lite
@brunoborges
brunoborges merged commit fb58a66 into actions:main Aug 5, 2026
84 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants