Skip to content

fix: allow tsci push without entrypoint when circuit.json exists#1

Open
64johnlee wants to merge 11 commits into
mainfrom
fix/issue-2797
Open

fix: allow tsci push without entrypoint when circuit.json exists#1
64johnlee wants to merge 11 commits into
mainfrom
fix/issue-2797

Conversation

@64johnlee
Copy link
Copy Markdown
Owner

When no tsx/ts entrypoint files are found, getEntrypoint() now falls back to checking for circuit.json files. This mirrors the behavior of tsci dev which already supports circuit.json files as valid build targets.

Fixes tscircuit#2797

@64johnlee 64johnlee force-pushed the fix/issue-2797 branch 4 times, most recently from 59248f3 to 8442649 Compare May 11, 2026 14:00
imrishabh18 and others added 11 commits May 25, 2026 09:28
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: GitHub Actions <actions@github.com>
Closes tscircuit#2797.

When no configured `mainEntrypoint` and no standard
`index.{circuit.,}tsx` are found, fall back to using the first
discovered `circuit.json` / `*.circuit.json` file as an implicit
entrypoint. This matches `tsci dev`, which already accepts a
prebuilt circuit.json.

- lib/shared/get-entrypoint.ts: recursive circuit.json scan with the
  same depth/results/boundary guards as findEntrypointsRecursively;
  skips node_modules, dist, and dot-dirs; runs only after all
  existing entrypoint detection paths have failed
- cli/build/register.ts: when the chosen entrypoint isn't a .ts/.tsx
  file (e.g. a circuit.json), skip transpilation gracefully instead
  of failing the build
- tests/get-entrypoint.test.ts: covers circuit.json fallback and tsx
  preference over circuit.json
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.

tsci push fails when no index.circuit.tsx file and no mainEntrypoint

4 participants