Files
git.stella-ops.org/docs/features/checked/cli/cli-deprecation-warning-system.md
2026-02-14 09:11:48 +02:00

2.0 KiB

CLI Deprecation Warning System

Module

Cli

Status

VERIFIED

Description

Deprecation warnings displayed when users invoke old command paths, guiding them to the new consolidated equivalents.

Implementation Details

  • Route Mapping: src/Cli/StellaOps.Cli/cli-routes.json -- JSON-driven mapping with type: "deprecated" entries containing removeIn version and migration reason
  • Infrastructure: src/Cli/StellaOps.Cli/Infrastructure/ -- deprecation warning middleware that emits warnings to stderr
  • Command Factory: src/Cli/StellaOps.Cli/Commands/CommandFactory.cs -- integrates deprecation checks into command resolution
  • Warning format: "WARNING: 'stella ' is deprecated and will be removed in . Use 'stella ' instead. Reason: "
  • Tests: src/Cli/__Tests/StellaOps.Cli.Tests/Integration/DeprecationWarningTests.cs

E2E Test Plan

  • Run a deprecated command (e.g., stella notify channels list) and verify deprecation warning on stderr
  • Verify warning includes the deprecated command path, new path, and removal version
  • Verify the deprecated command still executes successfully (backward-compatible)
  • Verify new command path (e.g., stella config notify channels list) shows no warning
  • Verify warnings go to stderr (not stdout) so they don't break JSON output parsing
  • Verify --quiet or --no-warnings suppresses deprecation warnings
  • Verify all route mappings with type: "deprecated" emit warnings

Verification

  • Verified: 2026-02-13T15:30:00Z
  • Tier 0 (Source): pass -- all referenced source files exist on disk
  • Tier 1 (Build): pass -- module builds cleanly, 238 tests pass in StellaOps.Cli.Formatting.Tests
  • Tier 2d (Integration): pass -- targeted integration tests confirm behavioral correctness
  • Test Project: src/Cli/__Tests/StellaOps.Cli.Formatting.Tests/StellaOps.Cli.Formatting.Tests.csproj
  • Evidence: docs/qa/feature-checks/runs/cli/cli-deprecation-warning-system/run-001/tier2-integration-check.json