Skip to content

fix: unbreak GH Pages build (linkHealth dynamic import) - #6

Merged
NooRotic merged 3 commits into
mainfrom
fix/gh-pages-link-health
May 19, 2026
Merged

fix: unbreak GH Pages build (linkHealth dynamic import)#6
NooRotic merged 3 commits into
mainfrom
fix/gh-pages-link-health

Conversation

@NooRotic

Copy link
Copy Markdown
Owner

Summary

Two commits, both targeting main:

  1. `fix(linkhealth): use import.meta.glob so build passes when generated/ is empty` (the actual hotfix)

    • GH Pages CI has been failing since 2026-04-27 because Rollup statically tries to resolve `./generated/link-health.json` even though the existing import was wrapped in a try/catch. The `generated/` dir is gitignored, so the file is never present in CI.
    • Replaces the bare dynamic `import()` with `import.meta.glob`, which evaluates to `{}` at build time when no files match — restoring the optional-load semantics the try/catch was originally trying to express.
    • Verified locally: `bun run build` passes both with and without `src/lib/data/generated/link-health.json` present.
  2. `feat(dashboard): sort leads and Up Next by source date, then priority` (carryover, pre-existing local WIP)

    • Walter's pre-recruiters-view local edits. Sorts dashboard leads + Up Next by date first, priority second. Adds `sourceDate` tracking. Removes a duplicate Up Next + Recent Applications grid section.
    • Was committed locally on 2026-05-19 and never pushed until now. Bundling with the hotfix because both touched main locally before the push.

If you'd rather review/merge these separately, just say — happy to split.

Verification

  • `bun run build` passes locally with and without the generated file
  • CI passes on this branch (will see after push)
  • No regression to `/` (dashboard) or `/applications` from the sort refactor — Walter authored this, so confirming it works as intended is his call

🤖 Note: GH Pages was already broken on `main` since commit `1e6c0d7` (2026-04-27), pre-dating PR #5. The recruiters PR did not introduce the regression.

NooRotic added 3 commits May 19, 2026 11:59
Pre-recruiters-view WIP: improves dashboard sort behavior by date-first,
priority-second. Adds sourceDate tracking on leads so the home page shows
most-recent searches at the top regardless of P-tier within a session.
Removes the duplicate Up Next + Recent Applications grid section that was
already represented elsewhere.
… is empty

GH Pages CI was failing because Rollup statically tried to resolve
./generated/link-health.json even though the existing import was wrapped
in a try/catch. The generated/ dir is intentionally gitignored, so the
file is never present in CI, and the static analysis blocks the build
before the catch can run.

Replace bare dynamic import() with import.meta.glob, which evaluates to
{} at build time when no files match — restoring the optional-load
semantics the try/catch was originally trying to express.

Verified locally with bun run build both WITH and WITHOUT the generated
file present.
Same pattern as linkHealth fix. The 10 try/catch-wrapped dynamic imports
of ./personal/* files were failing Rollup's static resolution at build
time even though the catch was meant to make them optional. CI deploys
don't have the gitignored personal/ files, so the build broke after the
linkHealth fix removed the first failure.

Replace bare dynamic imports with a single import.meta.glob lookup. If
the file isn't present, the glob entry is undefined and we skip cleanly.

Verified locally with bun run build both WITH and WITHOUT
src/lib/data/personal/ present.
@NooRotic
NooRotic merged commit e5d1bca into main May 19, 2026
1 of 2 checks passed
@NooRotic
NooRotic deleted the fix/gh-pages-link-health branch May 19, 2026 18:46
NooRotic added a commit that referenced this pull request May 21, 2026
fix: unbreak GH Pages build (linkHealth dynamic import)
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.

1 participant