Skip to content

fix: resolve Lint & Format and Type Check CI failures#103

Merged
kayodebristol merged 3 commits intomainfrom
copilot/fix-ci-failures-pr-93
Mar 25, 2026
Merged

fix: resolve Lint & Format and Type Check CI failures#103
kayodebristol merged 3 commits intomainfrom
copilot/fix-ci-failures-pr-93

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 25, 2026

Two CI jobs introduced in PR #93 were failing: Lint & Format (ESLint couldn't load its config) and Type Check (missing type declarations for .praxis).

Lint & Format — missing ESLint plugin source

packages/eslint-plugin-design-dojo had a package.json declaring "main": "src/index.js" but no src/ directory existed. ESLint crashed at config load time before linting any file.

  • Created packages/eslint-plugin-design-dojo/src/index.js implementing both rules referenced in eslint.config.js:
    • no-local-primitives — errors on raw HTML primitives (<button>, <input>, <select>, <textarea>) that have design-dojo equivalents
    • prefer-design-dojo-imports — warns when design-dojo components are imported from relative paths instead of @plures/design-dojo
  • Added .gitignore exception for packages/eslint-plugin-design-dojo/src/**/*.js — the existing rule packages/**/src/**/*.js was silently excluding the file (intended to block compiled TS output; this package is plain CommonJS with JS source)

Type Check — .praxis not built before svelte-check

src/lib/praxis/lifecycle.ts imports from @financialadvisor/praxis/lifecycle, resolving to .praxis/dist/lifecycle.d.ts. The typecheck CI job ran svelte-check without building packages first, so dist/ didn't exist — producing 1 module-not-found error and 5 downstream implicit-any errors from the unresolved DataEventCallbacks type.

  • Added npm run build:packages step to the typecheck CI job before svelte-kit sync and svelte-check
Original prompt

This section details on the original issue you should resolve

<issue_title>[ci-feedback] Fix CI failures on PR #93</issue_title>
<issue_description>PR #93 has failing CI checks: Lint & Format, Type Check

Please fix the failures and push to the PR branch.

@copilot</issue_description>

Comments on the Issue (you are @copilot in this section)

@kayodebristol @copilot Please fix this issue.

📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.

@github-actions github-actions Bot marked this pull request as ready for review March 25, 2026 06:57
Copilot AI review requested due to automatic review settings March 25, 2026 06:57
Copilot AI review requested due to automatic review settings March 25, 2026 06:57
…uild praxis before type check

Co-authored-by: kayodebristol <3579196+kayodebristol@users.noreply.github.com>
Agent-Logs-Url: https://github.com/plures/FinancialAdvisor/sessions/ec766f1d-2d18-43db-b28d-f07461d301fc
Copilot AI requested review from Copilot and removed request for Copilot March 25, 2026 07:07
…d plugin source

Co-authored-by: kayodebristol <3579196+kayodebristol@users.noreply.github.com>
Agent-Logs-Url: https://github.com/plures/FinancialAdvisor/sessions/ec766f1d-2d18-43db-b28d-f07461d301fc
Copilot AI requested review from Copilot and removed request for Copilot March 25, 2026 07:08
Copilot AI changed the title [WIP] Fix CI failures on PR #93 fix: resolve Lint & Format and Type Check CI failures Mar 25, 2026
Copilot AI requested a review from kayodebristol March 25, 2026 07:11
@kayodebristol kayodebristol requested a review from Copilot March 25, 2026 07:27
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes CI failures introduced in earlier changes by making the custom ESLint plugin loadable and ensuring .praxis type declarations exist before running Svelte type checking.

Changes:

  • Added the missing @plures/eslint-plugin-design-dojo implementation (src/index.js) with the two rules referenced by eslint.config.js.
  • Updated .gitignore to ensure the plugin’s JS source under packages/eslint-plugin-design-dojo/src/ is not ignored.
  • Updated CI typecheck workflow to run npm run build:packages before svelte-check for .praxis/dist/*.d.ts resolution.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
packages/eslint-plugin-design-dojo/src/index.js Adds the ESLint plugin entrypoint and rule implementations used by the repo’s flat ESLint config.
.gitignore Un-ignores the plugin’s JS source so it’s included in git (and thus available to ESLint in CI).
.github/workflows/ci.yml Builds workspace packages (including .praxis) before running npm run check in the Type Check job.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +36 to +39
messages: {
useDesignDojo:
'Use the <{{ component }}> component from @plures/design-dojo instead of a raw <{{ tag }}> element.',
},
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ESLint message templates use placeholders like {{name}}. The current strings include spaces ({{ component }} / {{ tag }}), which prevents interpolation and will show the raw template text in lint output. Remove the spaces so data.component and data.tag are substituted correctly.

Copilot uses AI. Check for mistakes.
schema: [],
messages: {
preferPackageImport:
"'{{ name }}' should be imported from '@plures/design-dojo', not from a local path.",
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same interpolation issue here: {{ name }} includes spaces, so ESLint likely won’t substitute the data.name value. Use {{name}} to ensure the reported message includes the imported symbol name.

Suggested change
"'{{ name }}' should be imported from '@plures/design-dojo', not from a local path.",
"'{{name}}' should be imported from '@plures/design-dojo', not from a local path.",

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor

@kayodebristol kayodebristol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Auto-approved: CI green + Copilot code review complete.

@kayodebristol kayodebristol merged commit 063633d into main Mar 25, 2026
11 checks passed
@kayodebristol kayodebristol deleted the copilot/fix-ci-failures-pr-93 branch March 25, 2026 07:52
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.

[ci-feedback] Fix CI failures on PR #93

3 participants