mirror of
https://github.com/Comfy-Org/comfy-typescript-sdk.git
synced 2026-11-04 23:47:27 +00:00
[PR #1] [MERGED] Add CI (oxlint, oxfmt, vitest, tsc) and a dormant npm publish workflow #13
Labels
No labels
audit:ai-readiness
audit:community
audit:github
audit:health-scoring
audit:policy
audit:release
audit:supply-chain
bug
cursor-review-pin
effort:medium
effort:small
effort:trivial
priority:nice-to-have
priority:recommended
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Comfy-Org/comfy-typescript-sdk#13
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Comfy-Org/comfy-typescript-sdk/pull/1
Author: @wei-hai
Created: 7/15/2026
Status: ✅ Merged
Merged: 7/15/2026
Merged by: @wei-hai
Base:
main← Head:ci/github-actions📝 Commits (2)
2a4141bAdd CI pipeline, source stub, and a dormant npm publish workflowa84c400CI: drop Node 20 from the test matrix, require Node >=22📊 Changes
7 files changed (+203 additions, -12 deletions)
View changed files
➕
.github/workflows/ci.yml(+53 -0)➕
.github/workflows/publish.yml(+75 -0)➕
.oxlintrc.json(+4 -0)📝
README.md(+3 -3)📝
package.json(+9 -9)➕
src/index.test.ts(+15 -0)➕
src/index.ts(+44 -0)📄 Description
Summary
.github/workflows/ci.yml: runs on pull requests and pushes tomain, across a Node 20/22/24 matrix, usingpnpmwith a frozen lockfile install. Each run runsoxlint(lint),oxfmt --check(formatting),tsc --noEmit(type check),vitest run(test), andtsc(build).src/index.ts: a smallComfyclient stub whose shape mirrors the Python SDK (constructor takes a base URL and an optional API key).run()currently throws"not implemented yet"— this repo's first job is getting CI and the package shape right; the real submit/poll/download logic is a follow-up.src/index.test.tswith two small passingvitesttests (construction, and thatrun()rejects with the expected message) so CI has something real to exercise..oxlintrc.json(minimal, just ignoresdist/coverage/node_modules)..github/workflows/publish.ymlscaffold, mirroring the Python SDK's PR: it only triggers on manualworkflow_dispatch, the job carriesif: false, and it's gated behind a GitHubenvironment: npmfor a future manual-approval step. ATODOblock at the top spells out what's needed to turn it on (reserve the@comfyorg/sdkpackage on npm, set up npm's OIDC "Trusted Publishing" for this repo, create thenpmenvironment with reviewers) — flippingif: falsetotrueis the only change needed once that's done.Tooling choices (and why)
This repo started completely empty, so the base commit on
main(just before this PR) bootstraps a minimal skeleton:README.md,.gitignore,package.json,tsconfig.json,pnpm-lock.yaml.For the package manager and linter/formatter, I checked the two closest sibling repos in the org:
Comfy-Org/ComfyUI_frontenduses pnpm (pinned viapackageManager) and oxlint + oxfmt instead of a plain ESLint/Prettier setup (ESLint is layered on top for a few rules, but oxlint/oxfmt do the bulk of lint+format), plus vitest for unit tests.Comfy-Org/comfy-cloud-mcp-server(closest small-package precedent by size) usesnpmrather thanpnpm, but the same oxlint + oxfmt + vitest + plaintsccombination, with dependency versions very close to what's pinned here (oxlint ^1.62,oxfmt ^0.45,vitest ^4.1,typescript ^5.8).Since the task asked to prefer
pnpm(the org's newer/larger-repo standard) while using the mcp-server repo as the nearest small-package precedent for everything else, this PR usespnpm+oxlint+oxfmt+vitest+ plaintscfor the build (notsup— nothing in the org's repos currently uses it, and a stub package doesn't need dual ESM/CJS output;"type": "module"+ plaintscis enough and keeps the dependency list small).Test plan
pnpm lint— passespnpm format:check— passespnpm typecheck— passespnpm test— 2 passedpnpm build— producesdist/index.js+dist/index.d.tsyaml.safe_load)🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.