Repository navigation
refactor(drills): decouple scenario strings into modular YAML catalog (#7) - #8
Open
celttechie wants to merge 1 commit into
Open
celttechie wants to merge 1 commit into
celttechie wants to merge 1 commit into
Conversation
…#7) - Extract 10 troubleshooting scenario definitions into scripts/drills/*.yaml - Externalize CLI diagnostic reference into scripts/drills/cheatsheet.yaml - Implement typed Scenario/TutorStep dataclasses and dynamic ${NAMESPACE} loader - Reduce drill_manager.py from 1,041 to 537 lines while preserving all CLI behavior - Add unit tests for YAML schema validation and dynamic namespace templating - Update README and architecture documentation with scripts/drills/ catalog
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Closes #7.
Refactors
scripts/drill_manager.pyby extracting all hardcoded string dictionaries (scenarios, multi-line JSON patches, tutor hints, explanations, and cheatsheet rows) into a modular YAML catalog underscripts/drills/.Key Changes
scripts/drills/using YAML literal block scalars (|) for clean multi-line shell commands.ScenarioandTutorStep@dataclassmodels indrill_manager.pywith schema validation and dynamic${NAMESPACE}parameterization.scripts/drills/cheatsheet.yaml.tests/test_drill_manager.pyvalidating that all YAML files meet schema requirements without hardcoded namespaces.Verification
python3 -m unittest discover -v -s tests(8/8 tests pass)make drill-listrenders all 10 scenarios across 5 domainsmake drill-cheatsheetrenders the 4 diagnostic reference tables