Skip to content

Add snow dcm analyze-errors command with severity-driven output#3070

Draft
sfc-gh-jsommerfeld wants to merge 4 commits into
feature/dcm-deploy-live-progressfrom
feature/dcm-analyze-improvements
Draft

Add snow dcm analyze-errors command with severity-driven output#3070
sfc-gh-jsommerfeld wants to merge 4 commits into
feature/dcm-deploy-live-progressfrom
feature/dcm-analyze-improvements

Conversation

@sfc-gh-jsommerfeld

@sfc-gh-jsommerfeld sfc-gh-jsommerfeld commented May 31, 2026

Copy link
Copy Markdown

Adds a user-facing snow dcm analyze-errors command (hidden without the early-access feature flag) that runs EXECUTE DCM PROJECT ANALYZE and formats the findings by file and severity. (The next PR in the stack, #3082, renames this command to compile.)

  • AnalyzeErrorsReporter: groups findings by source file, renders each file path in bold-blue, then lists errors/warnings/infos with colored severity labels and the line/column position of each finding; exits non-zero when errors are found
  • Severity enum (ERROR/WARNING/INFO) with color mapping via styles.py
  • Summary line: "Static analysis of DCM Project files found N error(s), M warning(s)." printed after the per-file details
  • analyze-errors command: wraps sync_local_files + raw_analyze inside a DeployProgressTracker session, showing UPLOAD → RENDER → COMPILE (the server-side ANALYZE is an implementation detail and is not shown as a phase)
  • raw_analyze gains a command_name parameter for artifact collection
  • styles.py: add WARNING_STYLE, INFO_STYLE, FILE_PATH_STYLE

Pre-review checklist

  • If my changes add or modify user-facing interface (commands, flags, output formats), I consulted maintainers and got sign-off beforehand (how).
  • I've confirmed that instructions included in README.md are still correct after my changes in the codebase.
  • I've added or updated unit tests to verify correctness of my new code.
  • I've added or updated integration tests to verify correctness of my new code.
  • Manually tested on macOS
  • Manually tested on Windows
  • I've confirmed my changes are up-to-date with the target branch.
  • I've described my changes in RELEASE-NOTES.md (see when and how).
  • I've updated documentation if behavior changed.

Changes description

...

@sfc-gh-jsommerfeld sfc-gh-jsommerfeld requested a review from a team as a code owner May 31, 2026 20:33
@sfc-gh-jsommerfeld sfc-gh-jsommerfeld marked this pull request as draft May 31, 2026 20:33
@sfc-gh-jsommerfeld sfc-gh-jsommerfeld force-pushed the feature/dcm-analyze-improvements branch from cdc8d95 to 342b87c Compare June 3, 2026 23:45
sfc-gh-jsommerfeld and others added 3 commits June 8, 2026 21:41
Adds a user-facing `snow dcm analyze` command (hidden without the
early-access feature flag) that runs EXECUTE DCM PROJECT ANALYZE and
formats the findings by file and severity.

- AnalyzeErrorsReporter: groups findings by source file, renders each
  file path in bold-blue, then lists errors/warnings/infos with colored
  severity labels; exits non-zero when errors are found
- Severity enum (ERROR/WARNING/INFO) with color mapping via styles.py
- Summary line: "Static analysis of DCM Project files found N error(s),
  M warning(s)." printed after per-file details
- analyze command: wraps sync_local_files + raw_analyze inside a
  DeployProgressTracker session (UPLOAD + ANALYZE phases)
- raw_analyze gains a command_name parameter for artifact collection
- styles.py: add WARNING_STYLE, INFO_STYLE, FILE_PATH_STYLE

Co-authored-by: Cursor <cursoragent@cursor.com>
Rename the `snow dcm analyze` command to `snow dcm analyze-errors` and
prefix each finding with its `line:column` position so users can jump
directly to the offending location.

Co-authored-by: Cursor <cursoragent@cursor.com>
Align the analyze-errors command with the unified phase model: drive the
tracker with the "compile" operation and show RENDER -> COMPILE instead of a
visible ANALYZE phase (ANALYZE remains the server-side implementation detail).

Co-authored-by: Cursor <cursoragent@cursor.com>
@sfc-gh-jsommerfeld sfc-gh-jsommerfeld force-pushed the feature/dcm-analyze-improvements branch from 342b87c to cad1115 Compare June 8, 2026 19:53
@sfc-gh-jsommerfeld sfc-gh-jsommerfeld changed the base branch from feature/dcm-upload-progress to feature/dcm-deploy-live-progress June 8, 2026 19:53
@sfc-gh-jsommerfeld sfc-gh-jsommerfeld changed the title Add snow dcm analyze command with severity-driven output Add snow dcm analyze-errors command with severity-driven output Jun 8, 2026
Collapse the two divergent blues — the periwinkle hex #a0a8fe (refresh
status / unknown rows) and the terminal-default named "blue" (running
phase, progress bar/spinner, analyze INFO findings / file headers) —
onto one BLUE constant in styles.py, and route progress.py's hardcoded
style="blue" literals through it, so every blue in DCM output renders
the same hue.

Co-authored-by: Cursor <cursoragent@cursor.com>
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