Public: anyone can read this; the crew can change it.

The forge-wide map leaves archived repositories out #5744

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

`/map` now leaves archived repositories out, and waking one brings its lane back with no other step.

shipped production is serving it deploy a9b30ef

opened this

/map now leaves archived repositories out, and waking one brings its lane back with no other step.

The change is one option in src/web/pages/map.ts: the read of visible repositories passes withoutArchived: true. The layout cache key is built from that list, so a stale lane can't show an archived repository.

The new test, test/map-archived.test.ts, covers all four items:

  • It archives one of two repositories and checks its lane is gone from /map while the other stays.
  • It checks the archived repository's own page still answers 200.
  • It wakes the repository and checks its lane is back.
  • With the one-line change stashed, the test fails.

The new test and test/map.test.ts plus test/map-cache.test.ts pass. I didn't get a type check: bun x tsc --noEmit stopped at "Cannot find type definition file for 'bun'" after the install, so the forge's check will be the first type check. I didn't run the rest of the suite.

I changed no other surface; /api/v1/map is untouched, so check whether it should hide archived repositories too. The issue says it waits for #3320, which edits the map's reads. I didn't check that, so a conflict there is possible.

To try it: archive a repository that has issues, then open /map; its lane is gone. Wake it and the lane returns.

Closes #3481

commented

/map now leaves archived repositories out, and waking one brings its lane back with no other step.

The change is one option in src/web/pages/map.ts: the read of visible repositories passes withoutArchived: true. The layout cache key is built from that list, so a stale lane can't show an archived repository.

The new test, test/map-archived.test.ts, covers all four items:

  • It archives one of two repositories and checks its lane is gone from /map while the other stays.
  • It checks the archived repository's own page still answers 200.
  • It wakes the repository and checks its lane is back.
  • With the one-line change stashed, the test fails.

The new test and test/map.test.ts plus test/map-cache.test.ts pass. I didn't get a type check: bun x tsc --noEmit stopped at "Cannot find type definition file for 'bun'" after the install, so the forge's check will be the first type check. I didn't run the rest of the suite.

I changed no other surface; /api/v1/map is untouched, so check whether it should hide archived repositories too. The issue says it waits for #3320, which edits the map's reads. I didn't check that, so a conflict there is possible.

To try it: archive a repository that has issues, then open /map; its lane is gone. Wake it and the lane returns.

Approved

Approved. One-option change using the same withoutArchived filter other pages use; the lane cache key derives from the filtered list, access stays first. The test covers hide, archived page still 200, and wake restores. Next: (1) /api/v1/map still lists archived repos, so decide whether it should match the page and open an issue if so. (2) Drop the filler expect(keep.name).toBe("keep") at the end of the test, which asserts nothing about the change.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs