Skip to content

fix(cli): ignore comments in payment config summary - #980

Open
WNZhao wants to merge 1 commit into
profullstack:masterfrom
WNZhao:fix/config-payments-ignore-comments
Open

fix(cli): ignore comments in payment config summary#980
WNZhao wants to merge 1 commit into
profullstack:masterfrom
WNZhao:fix/config-payments-ignore-comments

Conversation

@WNZhao

@WNZhao WNZhao commented Aug 24, 2026

Copy link
Copy Markdown

Summary

  • mask line and block comments before parsing the payments configuration summary
  • preserve quoted comment markers and source structure while scanning
  • add regressions for comment-only examples and a commented example before the real block

Bug

sh1pt config payments parsed the first text matching payments: {, including examples inside // or /* */ comments. A commented sample could therefore produce a fake provider summary or shadow the live configuration.

Validation

  • pnpm exec vitest run packages/cli/src/commands/config.test.ts --reporter=dot (6/6)
  • standalone TypeScript check for config-payments.ts
  • git diff --check

The workspace-wide CLI typecheck currently requires generated/built internal packages and fails on missing upstream workspace module declarations; the focused file check and repository CI cover this patch.

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.

1 participant