Skip to content

web-e2e: discover the delayed proxy package with Refresh from upstream, so the proxy-delay spec passes again - #860

Merged
schmitch merged 1 commit into
mainfrom
claude/vibrant-darwin-hugiot
Nov 3, 2026
Merged

schmitch merged 1 commit into
mainfrom
claude/vibrant-darwin-hugiot

Conversation

@schmitch

@schmitch schmitch commented Nov 3, 2026

Copy link
Copy Markdown
Member

Fixes #858

Problem

Since #841 (#836), a proxy's package page answers from what the proxy has cached and asks no upstream: GET /browse/packages/{repo}/{id} of a package the proxy holds nothing of is a 404, and looking no longer discovers it. The proxy-delay spec discovered the upstream's Sample.Lib through that GET, so it failed on every main run since 28f7b14:

Error: GET package detail dlyproxy1793731283761/Sample.Lib -> 404
   at fetchPackageDetail (web/e2e/helpers.ts:120:22)
   at web/e2e/specs/proxy-delay.spec.ts:59:18

Change

The spec now follows the page's own flow, which #841 added:

  1. it opens /packages/<proxy>/sample.lib and sees Package not cached (looking does not discover the package). This first check waits up to 15 s, because the detail query retries the 404 twice before the page shows it;
  2. it clicks Refresh from upstream (POST …/refresh), which asks the upstream as a client's install does and stamps the version's first_seen_at;
  3. it finds the 1.2.3 row with the delayed badge, and the detail API, from the cache now, surfaces the version as delayed_until;
  4. the browse checks (the delay-gated version is absent from search) are unchanged.

fetchPackageDetail's comment in web/e2e/helpers.ts no longer says the read discovers a proxy's package.

Test-only, so no changelog fragment, as in #783.

Testing

web-e2e runs on main and in the merge queue only, not on pull requests, so this ran locally the way CI runs it (CI=1 pnpm exec playwright test, Postgres 18 and versitygw through mirror.gcr.io, the debug forge-server):

  • proxy-delay.spec.ts: passes (5.1 s), no retry;
  • the whole suite: 22 passed, with retries off.

Generated by Claude Code

Since #841 (#836), a proxy's package page answers from what the proxy
has cached and asks no upstream: GET /browse/packages/{repo}/{id} of a
package the proxy holds nothing of is a 404, and looking no longer
discovers it. The proxy-delay spec discovered the upstream's Sample.Lib
by that GET, so it failed with a 404 and web-e2e failed on main.

The spec now follows the page's own flow: it opens the package page,
sees Package not cached, clicks Refresh from upstream, and finds the
version row with the delayed badge; the detail API, from the cache now,
surfaces the version as delayed_until. The first look waits out the
detail query's two retries of the 404. fetchPackageDetail's comment no
longer says the read discovers a proxy's package.

Fixes #858

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012e6DJbCpYhgvM3SxcYuMD1
@schmitch
schmitch added this pull request to the merge queue Nov 3, 2026
Merged via the queue into main with commit 8c05683 Nov 3, 2026
19 checks passed
@schmitch
schmitch deleted the claude/vibrant-darwin-hugiot branch November 3, 2026 20:21
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.

CI: web-e2e proxy-delay spec fails on main since #841, the package page no longer discovers a proxy's package by looking

2 participants