Repository navigation
ci: lint, typecheck, test and build the ui/ app #517
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,63 @@ | ||
| name: UI | ||
|
|
||
| # The graph debugger in ui/ had no CI at all (#452): ci.yml runs only the Python | ||
| # toolchain, so a change there could break the build and still merge green. It | ||
| # had already happened — when this job was added, main carried six eslint errors | ||
| # and two TypeScript errors that nothing had reported. | ||
| # | ||
| # Path-filtered so Python-only changes do not pay for a bun install, and the | ||
| # workflow file itself is in the filter so an edit to it runs it. | ||
| on: | ||
| push: | ||
| branches: [ main, dev, "feat/**", "fix/**", "docs/**" ] | ||
| paths: [ "ui/**", ".github/workflows/ui.yml" ] | ||
| pull_request: | ||
| branches: [ main ] | ||
| paths: [ "ui/**", ".github/workflows/ui.yml" ] | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| ui-ci: | ||
| name: UI Verification | ||
| runs-on: ubuntu-latest | ||
| defaults: | ||
| run: | ||
| working-directory: ui | ||
| steps: | ||
| - name: Checkout Code | ||
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | ||
|
|
||
| - name: Setup Bun | ||
| uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 | ||
| with: | ||
| # Pinned rather than "latest": the lockfile format moves with bun, and | ||
| # a runner picking up a new release must not be what turns this red. | ||
| bun-version: 1.3.14 | ||
|
|
||
| - name: Install Dependencies | ||
| # --frozen-lockfile fails when bun.lock is out of step with package.json, | ||
| # the job's equivalent of `uv lock --check` in ci.yml. --ignore-scripts | ||
| # because no dependency here needs an install hook — verified by running | ||
| # every step below from a clean install with it — so none gets to run | ||
| # code on the runner (Sonar githubactions:S6505). | ||
| run: bun install --frozen-lockfile --ignore-scripts | ||
|
|
||
| - name: ESLint | ||
| run: bun run lint | ||
|
|
||
| - name: TypeScript | ||
| # Vite transpiles TypeScript without type-checking it, so `build` below | ||
| # passes a type error. This is the only step that reads the types. | ||
| # Through a package script, so it runs the `typescript` pinned in | ||
| # bun.lock; `bunx tsc` could fetch an unpinned one (Sonar S8543). | ||
| run: bun run typecheck | ||
|
|
||
| - name: Tests | ||
| # vitest, not `bun test`: the native runner has no `vi.mock` hoisting, and | ||
| # component tests that use it fail under it (ui/AGENTS.md). | ||
| run: bun run test:run | ||
|
|
||
| - name: Build | ||
| run: bun run build |
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
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.