Skip to content

Make the site deployable, and finish the OpenRouter migration - #8

Merged
chrisschouk merged 3 commits into
mainfrom
fix/deploy-web-from-workspace
Aug 13, 2026
Merged

Make the site deployable, and finish the OpenRouter migration#8
chrisschouk merged 3 commits into
mainfrom
fix/deploy-web-from-workspace

Conversation

@chrisschouk

Copy link
Copy Markdown
Owner

The headline

podflow.cc has served a 404 since 27 June, the day it was first deployed. Both production deployments before today reported READY with zero output files, so nothing ever flagged it.

Four separate problems were stacked on top of each other.

1. Vercel was building the CLI, not the site

The project had no Root Directory set, so it built the repo root — whose build script is tsup src/cli.ts. That produces a Node bundle, not a website. Vercel shipped an empty deployment and marked it READY.

Root Directory is now set to web (changed in the Vercel dashboard, not in this PR).

2. The site depended on a directory outside the repo

web/package.json declared:

"@totalaudiopromo/ui": "file:../../newsjack/packages/ui"

That is a path to a sibling checkout. It resolves on the machine that has newsjack cloned next to podflow, and nowhere else — including CI and Vercel.

web/ was also the only directory missing from pnpm-workspace.yaml, which is why it reached outside instead of using the workspace. Both fixed: web is now a workspace member and the dependency is workspace:*. web/package-lock.json is removed so pnpm owns the install.

3. packages/ui had never been built

It declared "build": "tsup" with no config and no entry, so dist/ did not exist — and the exports map pointed at ./dist/index.js. Anything importing the package failed to resolve it, including apps/web.

Added tsup.config.ts with the two entries the exports map already promised, split so that only the client barrel carries the 'use client' banner and ./app stays RSC-safe.

4. The package had diverged into two copies

newsjack and podflow both contained @totalaudiopromo/ui@0.1.0 with different contents and the same version number. Every shared file differed, and newsjack had five components podflow did not.

newsjack's is the superset and is what web/ was written against, so podflow is synced up to it. That required migrating apps/web to the newer component APIs:

Component Before After
PageHeader subtitle, action, badge description, actions; badge becomes a SectionLabel above
StatCard title/subtitle, icon element, change/trend label/value, LucideIcon component, delta folded into limit
ActionTile description, badge subtitle

No content is dropped — the badges and deltas are preserved in the nearest equivalent slot.

Also fixed along the way

  • pnpm-workspace.yaml had two literal set this to true or false placeholders for core-js and sharp. pnpm treated the decision as unmade and failed every install. Resolved: sharp needs its native build, core-js does not.
  • react and react-dom resolved to 19.2.4 and 19.2.8, which React refuses to run. Pinned together via workspace overrides. (Note for future: pnpm 11 no longer reads the pnpm field from package.json — overrides belong in pnpm-workspace.yaml.)
  • Finished the 27 July OpenRouter migration. It landed in the other seven repos but was left uncommitted here. Default provider and model move to openrouter / deepseek/deepseek-v4-flash. Both that slug and inclusionai/ling-2.6-flash were verified live against the OpenRouter /models API today, per the standing rule about not trusting a model slug from memory.

Verification

  • packages/ui builds — dist/index.js, dist/app.js and both .d.ts files emitted.
  • web builds — 6 HTML pages, 700K of output.
  • apps/web builds — Next.js compiles and prerenders.
  • Root pnpm typecheck clean.
  • pnpm test — 39 passing.

Follow-up worth doing separately

The two @totalaudiopromo/ui copies will drift again. The real fix is publishing it once and depending on the published version, rather than keeping a copy per repo. Out of scope here.

Also: web/index.html references %VITE_GA_MEASUREMENT_ID%, which is not defined in any env file, so the analytics tag renders with a literal placeholder.

🤖 Generated with Claude Code

https://claude.ai/code/session_01AeYoJmE6BUfw9AZJxoK9Fx

…ration

podflow.cc has served a 404 since the day it was first deployed on 27 June.
Both production deployments before today reported READY with zero output files,
so nothing ever flagged it. The cause was a chain of four separate problems.

Vercel was building the wrong thing
- The project had no Root Directory set, so it built the repo root, whose build
  script compiles the CLI. No website was produced, an empty deployment shipped,
  and Vercel called it READY. Root Directory is now set to `web`.

The site depended on a directory outside the repo
- web/package.json declared "@totalaudiopromo/ui": "file:../../newsjack/packages/ui",
  a path to a sibling checkout. It resolved on one machine and nowhere else.
  web/ was also the only directory missing from pnpm-workspace.yaml, which is
  why it reached outside instead of using the workspace. Both fixed: web is a
  workspace member and the dependency is workspace:*.

packages/ui had never been built
- It declared "build": "tsup" with no config and no entry, so dist/ did not
  exist and nothing importing the package could resolve it. Added a tsup config
  with the two entries the exports map already promised, splitting them so only
  the client barrel carries the 'use client' banner and ./app stays RSC-safe.

The package had diverged into two copies
- newsjack and podflow both contained @totalaudiopromo/ui@0.1.0 with different
  contents. newsjack's is the superset (GlassCard, GradientButton, PricingTable,
  CrossSell, LeadCaptureForm) and is what web/ was written against. Synced
  podflow up to it and migrated apps/web to the newer component APIs:
  PageHeader's subtitle/action/badge became description/actions plus a
  SectionLabel, StatCard takes a LucideIcon rather than an element and folds its
  delta into the limit line, ActionTile's description became subtitle.

Also
- pnpm-workspace.yaml carried two literal "set this to true or false"
  placeholders for core-js and sharp, so pnpm treated the decision as unmade and
  failed every install. Resolved: sharp needs its native build, core-js does not.
- react and react-dom resolved to 19.2.4 and 19.2.8, which React refuses to run.
  Pinned together via workspace overrides.
- Finished the 27 July OpenRouter migration, which landed in the other seven
  repos but never got committed here: default provider and model move to
  openrouter and deepseek/deepseek-v4-flash. Both slugs verified live against
  the OpenRouter /models API today.

Verified: packages/ui, web and apps/web all build; root typecheck clean; 39
tests pass.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AeYoJmE6BUfw9AZJxoK9Fx
@vercel

vercel Bot commented Aug 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
podflow Ready Ready Preview Aug 13, 2026 2:32pm

CI pinned pnpm 9 while the repo is developed on pnpm 11. pnpm 9 reads overrides
from package.json; pnpm 10+ reads them from pnpm-workspace.yaml. A lockfile
written by 11 therefore looked like a config mismatch to 9 and failed the frozen
install.

pnpm-workspace.yaml already used pnpm 10+ syntax (allowBuilds), so CI was
running an older resolver than the repo was written for. Pin the version in
packageManager and let action-setup follow it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AeYoJmE6BUfw9AZJxoK9Fx
pnpm 11 requires the node:sqlite builtin, which Node 20 does not provide, so it
cannot run on the CI matrix. pnpm 10 reads overrides from pnpm-workspace.yaml
like 11 does, supports allowBuilds, writes the same lockfile format, and is
already what Vercel uses for this project.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AeYoJmE6BUfw9AZJxoK9Fx
@chrisschouk
chrisschouk merged commit 8d572ca into main Aug 13, 2026
6 checks passed
@chrisschouk
chrisschouk deleted the fix/deploy-web-from-workspace branch August 13, 2026 14:33
chrisschouk added a commit that referenced this pull request Sep 5, 2026
The OpenRouter migration landed in #8 but the README still documented
Anthropic as the default provider and model. Config example, provider
table, and the --provider flag list now match src/config/index.ts and
src/ai/extractor.ts. Adds the ui and import commands and the --rss flag,
which were registered in the CLI but absent from the docs.


Claude-Session: https://claude.ai/code/session_01P6r6zJqVcZR61FeWH7ZvGi

Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
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