Skip to content

fix: resolve CI workflow failures and add Cloudflare Worker deploy pipeline - #253

Open
circleci-app[bot] wants to merge 1 commit into
mainfrom
chunk/fix-workflows-and-deploy-worker
Open

circleci-app[bot] wants to merge 1 commit into
mainfrom
chunk/fix-workflows-and-deploy-worker

Conversation

@circleci-app

@circleci-app circleci-app Bot commented Oct 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Root package.json: Removed duplicate circletui dependency key that caused a pnpm install warning on every CI run.
  • functions/package.json: Removed duplicate firebase-admin key (kept ^13.9.0); removed misplaced lint package from runtime dependencies.
  • app/wrangler.jsonc: Replaced placeholder strings <WORKER_NAME> and <COMPATIBILITY_DATE> with real values (ytstudio-app, 2025-01-01).
  • .circleci/config.yml — three changes:
    1. Fixed node-checks job: added npm ci step inside functions/ before running ESLint and tsc. The job was previously failing because functions/ has its own package-lock.json but its deps were never installed (only root pnpm deps were installed).
    2. New worker-build job: installs root pnpm deps and runs tsc --noEmit to validate that src/youtube-worker.ts (the YouTube API v3 Cloudflare Worker) compiles cleanly.
    3. New deploy-worker job + deploy workflow: deploys the YouTube API v3 worker to Cloudflare Workers via wrangler deploy on every push to main. Requires CLOUDFLARE_API_TOKEN to be set as a CircleCI environment variable.

The YouTube API v3 Worker

src/youtube-worker.ts already implements full YouTube Data API v3 integration for channel UCrjJP_SHUeCmqpTSHJCXkdA with endpoints:

Endpoint Description
GET / or /health Health check + endpoint listing
GET /api/channel Channel statistics & metadata
GET /api/videos Upload playlist with pagination
GET /api/search?q=<query> Channel-scoped video search

All endpoints fall back to demo data when YOUTUBE_API_KEY is not set.

Test plan

  • Confirm pnpm install at root completes without duplicate-key warnings
  • Confirm npm ci in functions/ installs deps cleanly
  • Confirm node-checks job passes lint and tsc on the next CI run
  • Confirm worker-build job passes TypeScript check for the worker
  • Set CLOUDFLARE_API_TOKEN in CircleCI project env vars to enable deploy-worker

https://app.circleci.com/agents/gh/ruhdevops/chat/9fd9419e-e1b5-4310-8b3e-45941eac5624

- Remove duplicate 'circletui' key from root package.json (caused pnpm install warning)
- Fix functions/package.json: remove duplicate 'firebase-admin' key, remove misplaced 'lint' runtime dep
- Fix app/wrangler.jsonc: replace placeholder <WORKER_NAME>/<COMPATIBILITY_DATE> with real values
- Fix .circleci/config.yml node-checks job: add 'npm ci' in functions/ before lint/tsc (was failing because npm deps were never installed in that subdirectory)
- Add worker-build job: validates TypeScript compilation of src/youtube-worker.ts
- Add deploy-worker job: deploys YouTube API v3 Cloudflare Worker via wrangler (requires CLOUDFLARE_API_TOKEN secret)
- Add 'deploy' workflow that runs worker-build + deploy-worker on main branch only

AI-Generated: true
@bolt-new-by-stackblitz

Copy link
Copy Markdown

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@vercel

vercel Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
yt-studio Error Error Oct 18, 2026 12:25am UTC
yt-studio-production Error Error Oct 18, 2026 12:25am UTC

@cloudflare-workers-and-pages

Copy link
Copy Markdown
Contributor

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
❌ Deployment failed
View logs
ytstudio 5a1caaf Oct 18 2026, 12:25 AM

@cloudflare-workers-and-pages

Copy link
Copy Markdown
Contributor

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
❌ Deployment failed
View logs
ytstudio 5a1caaf Oct 18 2026, 12:25 AM

@netlify

netlify Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

❌ Deploy Preview for ytr-studio failed.

Name Link
🔨 Latest commit 5a1caaf
🔍 Latest deploy log https://app.netlify.com/projects/ytr-studio/deploys/6ad41200d0d0f83a9fd22def

@netlify

netlify Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for elegant-seahorse-d9d460 ready!

Name Link
🔨 Latest commit 5a1caaf
🔍 Latest deploy log https://app.netlify.com/projects/elegant-seahorse-d9d460/deploys/6ad4120043409751d6411568
😎 Deploy Preview https://deploy-preview-253--elegant-seahorse-d9d460.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

This branch had an error being deployed

2 failed deployments
Preview – yt-studio — 5a1caaf2 Deployed Oct 18, 2026 by vercel[bot]
Preview – yt-studio-production — 5a1caaf2 Deployed Oct 18, 2026 by vercel[bot]
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.

0 participants