fix: allow tsci push without entrypoint when circuit.json exists#1
Open
64johnlee wants to merge 11 commits into
Open
fix: allow tsci push without entrypoint when circuit.json exists#164johnlee wants to merge 11 commits into
64johnlee wants to merge 11 commits into
Conversation
59248f3 to
8442649
Compare
…l globally which can be used (tscircuit#3100)
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
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When no tsx/ts entrypoint files are found,
getEntrypoint()now falls back to checking forcircuit.jsonfiles. This mirrors the behavior oftsci devwhich already supports circuit.json files as valid build targets.Fixes tscircuit#2797