jettypod 4.1.2 → 4.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.nvmrc +1 -0
- package/docs/COMPLETE-TESTING-STRATEGY.md +970 -0
- package/docs/DECISIONS.md +10 -12
- package/docs/NODE_VERSION.md +83 -0
- package/docs/TDD-INFRASTRUCTURE-STRATEGY.md +1374 -0
- package/docs/TESTING-FOR-NON-ENGINEERS.md +1588 -0
- package/docs/TESTING-STRATEGY-AUDIT.md +698 -0
- package/hooks/post-checkout +17 -0
- package/hooks/post-merge +17 -0
- package/hooks/pre-commit +30 -0
- package/jettypod.js +259 -120
- package/lib/coverage-tracker.js +218 -0
- package/lib/database.js +2 -0
- package/lib/db-export.js +192 -0
- package/lib/db-import.js +193 -0
- package/lib/external-transition-handler.js +32 -0
- package/lib/git-hook-helpers.js +174 -0
- package/lib/git-root.js +90 -0
- package/lib/infrastructure-chore-generator.js +45 -0
- package/lib/install-hooks.js +52 -0
- package/lib/jettypod-backup.js +238 -0
- package/lib/merge-lock.js +193 -0
- package/lib/migrations/012-add-worktree-path.js +38 -0
- package/lib/migrations/013-worktrees-table.js +86 -0
- package/lib/migrations/014-migrate-worktree-data.js +161 -0
- package/lib/migrations/015-merge-locks-table.js +67 -0
- package/lib/pattern-finder.js +152 -0
- package/lib/process-manager.js +140 -0
- package/lib/production-standards-reader.js +13 -2
- package/lib/production-standards-writer.js +85 -0
- package/lib/skills/feature-planning/dry-run-validator.js +135 -0
- package/lib/skills/feature-planning/validation-formatter.js +160 -0
- package/lib/smart-conflict-detection.js +168 -0
- package/lib/smart-fetch-rebase.js +614 -0
- package/lib/step-definition-parser.js +76 -0
- package/lib/unit-test-generator.js +232 -0
- package/lib/verification-command-generator.js +66 -0
- package/lib/worktree-diagnostics.js +413 -0
- package/lib/worktree-facade.js +174 -0
- package/lib/worktree-manager.js +636 -0
- package/lib/worktree-reconciler.js +429 -0
- package/package.json +30 -3
- package/skills-templates/external-transition/SKILL.md +34 -3
- package/skills-templates/feature-planning/SKILL.md +190 -24
- package/skills-templates/production-mode/SKILL.md +127 -9
- package/skills-templates/speed-mode/SKILL.md +454 -51
- package/skills-templates/stable-mode/SKILL.md +285 -76
- package/.claude/PROTECT_SKILLS.md +0 -28
- package/.claude/settings.json +0 -24
- package/.claude/settings.local.json +0 -16
- package/.claude/skills/epic-planning/SKILL.md +0 -297
- package/.claude/skills/external-transition/SKILL.md +0 -384
- package/.claude/skills/feature-planning/SKILL.md +0 -464
- package/.claude/skills/production-mode/SKILL.md +0 -369
- package/.claude/skills/speed-mode/SKILL.md +0 -481
- package/.claude/skills/stable-mode/SKILL.md +0 -713
- package/.claude/skills.backup-2025-11-10T23-33-09-368Z/epic-planning/SKILL.md +0 -297
- package/.claude/skills.backup-2025-11-10T23-33-09-368Z/feature-planning/SKILL.md +0 -464
- package/.claude/skills.backup-2025-11-10T23-33-09-368Z/speed-mode/SKILL.md +0 -467
- package/.claude/skills.backup-2025-11-10T23-33-09-368Z/stable-mode/SKILL.md +0 -673
- package/.claude/skills.backup-2025-11-11T16-15-10-070Z/epic-discover/SKILL.md +0 -297
- package/.claude/skills.backup-2025-11-11T16-42-43-212Z/epic-planning/SKILL.md +0 -297
- package/.claude/skills.backup-2025-11-11T16-42-43-212Z/feature-planning/SKILL.md +0 -464
- package/.claude/skills.backup-2025-11-11T16-42-43-212Z/speed-mode/SKILL.md +0 -467
- package/.claude/skills.backup-2025-11-11T16-42-43-212Z/stable-mode/SKILL.md +0 -673
- package/.claude/skills.backup-2025-11-11T17-06-09-783Z/epic-planning/SKILL.md +0 -297
- package/.claude/skills.backup-2025-11-11T17-06-09-783Z/feature-planning/SKILL.md +0 -464
- package/.claude/skills.backup-2025-11-11T17-06-09-783Z/speed-mode/SKILL.md +0 -467
- package/.claude/skills.backup-2025-11-11T17-06-09-783Z/stable-mode/SKILL.md +0 -673
- package/.devpod/current-work.json +0 -10
- package/.devpod/work.db +0 -0
- package/.github/workflows/test-safety.yml +0 -85
- package/.jettypod/config.json +0 -5
- package/.jettypod/current-work.json +0 -10
- package/.jettypod/hooks/README.md +0 -77
- package/.jettypod/hooks/protect-claude-md.js +0 -338
- package/.jettypod/test-work.db +0 -0
- package/.jettypod/work.db +0 -0
- package/CLAUDE.md +0 -49
- package/SPEED-STABLE-AUDIT.md +0 -853
- package/SYSTEM-BEHAVIOR.md +0 -2199
- package/TEST_SAFETY_AUDIT.md +0 -314
- package/TEST_SAFETY_IMPLEMENTATION.md +0 -97
- package/cucumber-report.html +0 -45
- package/dist/devpod-linux +0 -0
- package/dist/devpod-macos +0 -0
- package/dist/devpod-win.exe +0 -0
- package/docs/features/jettypod-standards-explained.md +0 -543
- package/docs/features/standards-inventory.md +0 -257
- package/features/auto-generate-production-chores.feature +0 -13
- package/features/backlog-command.feature +0 -26
- package/features/backlog-filtering-production.feature +0 -10
- package/features/claude-md-protection/steps.js +0 -498
- package/features/decisions/index.js +0 -490
- package/features/decisions/index.test.js +0 -208
- package/features/fix-text-wrapping.feature +0 -42
- package/features/git-hooks/git-hooks.feature +0 -30
- package/features/git-hooks/index.js +0 -93
- package/features/git-hooks/index.test.js +0 -137
- package/features/git-hooks/post-commit +0 -56
- package/features/git-hooks/post-merge +0 -47
- package/features/git-hooks/pre-commit +0 -28
- package/features/git-hooks/simple-steps.js +0 -53
- package/features/git-hooks/simple-test.feature +0 -10
- package/features/git-hooks/steps.js +0 -196
- package/features/jettypod-update-command.feature +0 -46
- package/features/mode-prompts/index.js +0 -95
- package/features/mode-prompts/simple-steps.js +0 -44
- package/features/mode-prompts/simple-test.feature +0 -9
- package/features/mode-prompts/validation.test.js +0 -120
- package/features/multiple-claude-instances.feature +0 -121
- package/features/production-mode-skill.feature +0 -121
- package/features/refactor-mode/steps.js +0 -217
- package/features/refactor-mode.feature +0 -49
- package/features/simplify-external-transition.feature +0 -166
- package/features/skills-update/index.test.js +0 -216
- package/features/step_definitions/backlog-command.steps.js +0 -37
- package/features/step_definitions/fix-text-wrapping.steps.js +0 -271
- package/features/step_definitions/multiple-claude-instances.steps.js +0 -621
- package/features/step_definitions/production-mode-skill.steps.js +0 -862
- package/features/step_definitions/simplify-external-transition.steps.js +0 -370
- package/features/step_definitions/terminal-logo.steps.js +0 -145
- package/features/step_definitions/update-command.steps.js +0 -183
- package/features/support/hooks.js +0 -9
- package/features/terminal-logo/index.js +0 -39
- package/features/terminal-logo/terminal-logo.feature +0 -30
- package/features/update-command/index.js +0 -181
- package/features/update-command/index.test.js +0 -225
- package/features/work-commands/bug-workflow-display.feature +0 -22
- package/features/work-commands/index.js +0 -498
- package/features/work-commands/simple-steps.js +0 -69
- package/features/work-commands/stable-tests.feature +0 -57
- package/features/work-commands/steps.js +0 -1174
- package/features/work-commands/validation.test.js +0 -88
- package/features/work-commands/work-commands.feature +0 -13
- package/features/work-tracking/discovery-validation.test.js +0 -228
- package/features/work-tracking/index.js +0 -1921
- package/features/work-tracking/mode-required.feature +0 -112
- package/features/work-tracking/phase-tracking.test.js +0 -482
- package/features/work-tracking/prototype-tracking.test.js +0 -485
- package/features/work-tracking/tree-view.test.js +0 -310
- package/features/work-tracking/work-set-mode.feature +0 -71
- package/features/work-tracking/work-start-mode.feature +0 -88
- package/full-test.txt +0 -0
- package/lib/bug-workflow.test.js +0 -177
- package/lib/claudemd.test.js +0 -195
- package/lib/config.test.js +0 -511
- package/lib/constants.test.js +0 -164
- package/lib/current-work.test.js +0 -146
- package/lib/database-project-config.test.js +0 -111
- package/lib/database.test.js +0 -106
- package/lib/decisions-generator.test.js +0 -457
- package/lib/decisions-helpers.test.js +0 -310
- package/lib/git-coordinator.js +0 -167
- package/lib/git.test.js +0 -145
- package/lib/migrations/002-default-work-item-modes.test.js +0 -351
- package/lib/production-chore-generator.test.js +0 -432
- package/lib/production-context-detector.test.js +0 -277
- package/lib/production-scenario-appender.test.js +0 -235
- package/lib/production-scenario-validator.test.js +0 -246
- package/lib/production-standards-reader.test.js +0 -270
- package/lib/project-state.test.js +0 -92
- package/lib/push-queue.js +0 -417
- package/lib/queue-processor.js +0 -74
- package/lib/test-helpers.js +0 -202
- package/lib/test-helpers.test.js +0 -255
- package/prototypes/2025-01-11-production-mode-autonomous.js +0 -119
- package/prototypes/2025-01-11-production-mode-collaborative.js +0 -166
- package/prototypes/2025-01-11-production-mode-guided.js +0 -217
- package/prototypes/2025-01-11-production-mode-smart-context.js +0 -347
- package/prototypes/2025-01-11-production-standards-example.md +0 -204
- package/prototypes/2025-11-10-backlog-filtering-tree-aware.js +0 -242
- package/prototypes/test/index.html +0 -1
- package/setup-dist-repo.sh +0 -68
- package/test-production-standards-engine.js +0 -130
- package/test-results.json +0 -2195
- package/test-safety-check.sh +0 -80
- package/work-item-tracking-plan.md +0 -199
- /package/{.jettypod/devpod.db → jettypod.db} +0 -0
|
@@ -1,481 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: speed-mode
|
|
3
|
-
description: Guide implementation of speed mode chores with autonomous code analysis and execution. Use when user starts work on a speed mode chore. Analyzes BDD scenarios, proposes implementation, writes code, and generates stable mode chores at completion.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Speed Mode Skill
|
|
7
|
-
|
|
8
|
-
Guides Claude Code through speed mode implementation with autonomous analysis and execution. Users confirm approach but Claude Code writes the code.
|
|
9
|
-
|
|
10
|
-
## Instructions
|
|
11
|
-
|
|
12
|
-
When this skill is activated, you are helping implement a speed mode chore to make the happy path scenario pass. Follow this structured approach:
|
|
13
|
-
|
|
14
|
-
### Overview
|
|
15
|
-
|
|
16
|
-
**Speed Mode Goal:** Implement ALL scoped functionality to make the happy path BDD scenario pass, assuming everything works correctly.
|
|
17
|
-
|
|
18
|
-
**Key Principles:**
|
|
19
|
-
- **Implement ALL features/functions** defined in the scenario - do not skip functionality
|
|
20
|
-
- **Assume happy path** - assume inputs are valid, files upload successfully, types are correct
|
|
21
|
-
- **No error handling** - no validation, no edge case handling, no error messages (that's for stable mode)
|
|
22
|
-
- **Fast iteration** - single file when possible, inline code over abstraction
|
|
23
|
-
- **Pragmatic** - localStorage for data, simple implementations
|
|
24
|
-
- **Autonomous execution** - Claude Code writes code, user confirms approach
|
|
25
|
-
|
|
26
|
-
**User Profile:** May not know how to code - Claude Code does the implementation autonomously.
|
|
27
|
-
|
|
28
|
-
---
|
|
29
|
-
|
|
30
|
-
## Implementation Steps
|
|
31
|
-
|
|
32
|
-
### Step 1: Check for Breadcrumbs and Analyze Scenario
|
|
33
|
-
|
|
34
|
-
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
35
|
-
|
|
36
|
-
**Your task:**
|
|
37
|
-
1. Get the current work item and read its description for breadcrumbs
|
|
38
|
-
2. If breadcrumbs exist (Scenario steps addressed, Implementation guidance, Verification), use them
|
|
39
|
-
3. If no breadcrumbs, fall back to full autonomous analysis
|
|
40
|
-
4. Read the parent feature's scenario file
|
|
41
|
-
5. Parse the Gherkin and identify what needs to be implemented
|
|
42
|
-
|
|
43
|
-
**Code to check for breadcrumbs:**
|
|
44
|
-
|
|
45
|
-
```javascript
|
|
46
|
-
const { getCurrentWork } = require('../../lib/current-work');
|
|
47
|
-
const { getDb } = require('../../lib/database');
|
|
48
|
-
const fs = require('fs');
|
|
49
|
-
const path = require('path');
|
|
50
|
-
|
|
51
|
-
const currentWork = getCurrentWork();
|
|
52
|
-
|
|
53
|
-
// Check if description has breadcrumbs from feature-planning
|
|
54
|
-
const hasBreadcrumbs = currentWork.description &&
|
|
55
|
-
currentWork.description.includes('Scenario steps addressed:') &&
|
|
56
|
-
currentWork.description.includes('Implementation guidance:') &&
|
|
57
|
-
currentWork.description.includes('Verification:');
|
|
58
|
-
|
|
59
|
-
// Get parent feature
|
|
60
|
-
const db = getDb();
|
|
61
|
-
db.get('SELECT * FROM work_items WHERE id = ?', [currentWork.parent_id], (err, feature) => {
|
|
62
|
-
if (!feature.scenario_file) {
|
|
63
|
-
console.error('No scenario file found for this feature');
|
|
64
|
-
return;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
const scenarioPath = path.join(process.cwd(), feature.scenario_file);
|
|
68
|
-
const scenarioContent = fs.readFileSync(scenarioPath, 'utf8');
|
|
69
|
-
|
|
70
|
-
// Parse and analyze...
|
|
71
|
-
});
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
**Parse Gherkin:**
|
|
75
|
-
- Extract first `Scenario:` block (happy path)
|
|
76
|
-
- Parse Given/When/Then/And steps
|
|
77
|
-
- Identify:
|
|
78
|
-
- Initial state setup (Given)
|
|
79
|
-
- User actions (When)
|
|
80
|
-
- Expected outcomes (Then)
|
|
81
|
-
- Observable changes (And)
|
|
82
|
-
|
|
83
|
-
**Display to user (with breadcrumbs):**
|
|
84
|
-
|
|
85
|
-
```
|
|
86
|
-
🚀 Speed Mode: [Chore Title]
|
|
87
|
-
|
|
88
|
-
Scenario steps addressed:
|
|
89
|
-
[Steps from breadcrumbs]
|
|
90
|
-
|
|
91
|
-
Implementation guidance:
|
|
92
|
-
[Files, patterns, functions from breadcrumbs]
|
|
93
|
-
|
|
94
|
-
Verification:
|
|
95
|
-
[Step definitions from breadcrumbs]
|
|
96
|
-
|
|
97
|
-
Now analyzing codebase to finalize implementation approach...
|
|
98
|
-
```
|
|
99
|
-
|
|
100
|
-
**Display to user (without breadcrumbs):**
|
|
101
|
-
|
|
102
|
-
```
|
|
103
|
-
🚀 Speed Mode: [Feature Name]
|
|
104
|
-
|
|
105
|
-
Happy Path Scenario:
|
|
106
|
-
[Scenario title]
|
|
107
|
-
|
|
108
|
-
What needs to happen:
|
|
109
|
-
• [Given] Initial state: [extracted requirement]
|
|
110
|
-
• [When] User action: [extracted action]
|
|
111
|
-
• [Then] Expected result: [extracted outcome]
|
|
112
|
-
• [And] Observable change: [extracted change]
|
|
113
|
-
|
|
114
|
-
Now analyzing codebase to propose implementation...
|
|
115
|
-
```
|
|
116
|
-
|
|
117
|
-
**Move to Step 2 automatically.**
|
|
118
|
-
|
|
119
|
-
### Step 2: Autonomous Codebase Analysis
|
|
120
|
-
|
|
121
|
-
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
122
|
-
|
|
123
|
-
**Your task:**
|
|
124
|
-
1. Check for epic architectural decisions
|
|
125
|
-
2. Use breadcrumbs if available, otherwise discover patterns
|
|
126
|
-
3. Verify/find relevant existing files
|
|
127
|
-
4. Understand code patterns and conventions
|
|
128
|
-
5. Identify where new code should be added
|
|
129
|
-
|
|
130
|
-
**Check for architectural decisions:**
|
|
131
|
-
|
|
132
|
-
```javascript
|
|
133
|
-
const { getDecisionsForEpic } = require('../../lib/decisions-helpers');
|
|
134
|
-
|
|
135
|
-
// Get epic from current work
|
|
136
|
-
db.get('SELECT epic_id FROM work_items WHERE id = ?', [currentWork.parent_id], async (err, feature) => {
|
|
137
|
-
if (feature.epic_id) {
|
|
138
|
-
const decisions = await getDecisionsForEpic(feature.epic_id);
|
|
139
|
-
// Decisions constrain your implementation approach
|
|
140
|
-
}
|
|
141
|
-
});
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
**If breadcrumbs exist (from feature-planning):**
|
|
145
|
-
- Parse "Files to create/modify" section - these are your target files
|
|
146
|
-
- Parse "Patterns to follow" section - read these reference files first
|
|
147
|
-
- Parse "Key functions/components needed" - these guide your implementation
|
|
148
|
-
- Verify reference files exist and read them to understand patterns
|
|
149
|
-
- Confirm target file locations make sense in project structure
|
|
150
|
-
|
|
151
|
-
**If no breadcrumbs (autonomous discovery):**
|
|
152
|
-
- Use Glob tool to find files matching patterns from scenario
|
|
153
|
-
- Example: Scenario mentions "login" → search for `**/*login*.js`, `**/*auth*.js`
|
|
154
|
-
- Use Grep tool to search for keywords from scenario
|
|
155
|
-
- Example: Scenario mentions "dashboard" → grep for "dashboard"
|
|
156
|
-
- Read similar features to understand patterns
|
|
157
|
-
|
|
158
|
-
**Understand patterns:**
|
|
159
|
-
- File structure conventions (where do features live?)
|
|
160
|
-
- Naming patterns (camelCase? kebab-case?)
|
|
161
|
-
- Import/export patterns
|
|
162
|
-
- Testing patterns (if tests exist)
|
|
163
|
-
- Database patterns (if data persistence mentioned)
|
|
164
|
-
|
|
165
|
-
**Identify integration points:**
|
|
166
|
-
- Where does this feature hook into existing code?
|
|
167
|
-
- What files need to import the new code?
|
|
168
|
-
- What existing functions need to call the new code?
|
|
169
|
-
|
|
170
|
-
**Display analysis results:**
|
|
171
|
-
|
|
172
|
-
```
|
|
173
|
-
📊 Codebase Analysis Complete
|
|
174
|
-
|
|
175
|
-
Architectural Constraints:
|
|
176
|
-
[List any epic decisions that apply]
|
|
177
|
-
|
|
178
|
-
Existing Patterns Found:
|
|
179
|
-
• File structure: [pattern]
|
|
180
|
-
• Naming convention: [pattern]
|
|
181
|
-
• Similar feature: [file path and pattern]
|
|
182
|
-
|
|
183
|
-
Integration Points:
|
|
184
|
-
• New code will go in: [directory]
|
|
185
|
-
• Needs to be imported by: [file]
|
|
186
|
-
• Will call existing: [function/module]
|
|
187
|
-
|
|
188
|
-
Now proposing implementation approach...
|
|
189
|
-
```
|
|
190
|
-
|
|
191
|
-
**Move to Step 3 automatically.**
|
|
192
|
-
|
|
193
|
-
### Step 3: Propose and Execute Implementation
|
|
194
|
-
|
|
195
|
-
**Two phases: Propose (get user confirmation) → Execute (autonomous)**
|
|
196
|
-
|
|
197
|
-
#### Phase 1: Propose Implementation Approach
|
|
198
|
-
|
|
199
|
-
**Present your analysis and proposal:**
|
|
200
|
-
|
|
201
|
-
```
|
|
202
|
-
💡 Implementation Proposal
|
|
203
|
-
|
|
204
|
-
Based on scenario analysis and codebase patterns, here's how I'll make the scenario pass:
|
|
205
|
-
|
|
206
|
-
**Files to create/modify:**
|
|
207
|
-
1. [file path] - [what it will do]
|
|
208
|
-
2. [file path] - [what it will do]
|
|
209
|
-
|
|
210
|
-
**Key implementation points:**
|
|
211
|
-
• [Point 1]: [specific approach]
|
|
212
|
-
• [Point 2]: [specific approach]
|
|
213
|
-
• [Point 3]: [specific approach]
|
|
214
|
-
|
|
215
|
-
**Why this approach:**
|
|
216
|
-
[Brief explanation of how this satisfies the scenario while following codebase patterns]
|
|
217
|
-
|
|
218
|
-
Sound good? I'll implement this autonomously once you confirm.
|
|
219
|
-
```
|
|
220
|
-
|
|
221
|
-
**WAIT for user confirmation or adjustments.**
|
|
222
|
-
|
|
223
|
-
If user adjusts: revise proposal and confirm again.
|
|
224
|
-
|
|
225
|
-
#### Phase 2: Autonomous Execution
|
|
226
|
-
|
|
227
|
-
**CRITICAL:** After user confirms, Claude Code executes autonomously - no permission needed for individual code changes.
|
|
228
|
-
|
|
229
|
-
**Execution loop:**
|
|
230
|
-
|
|
231
|
-
1. **Create/modify files** using Write/Edit tools
|
|
232
|
-
- Follow the proposed plan
|
|
233
|
-
- Write minimal code (speed mode - happy path only)
|
|
234
|
-
- Add basic comments for clarity
|
|
235
|
-
- Use inline code over abstractions
|
|
236
|
-
|
|
237
|
-
2. **Run BDD tests** to verify step definitions pass
|
|
238
|
-
```javascript
|
|
239
|
-
// Run the feature's BDD tests (scenarios + step definitions)
|
|
240
|
-
const { exec } = require('child_process');
|
|
241
|
-
exec('npm run test:bdd -- [feature-file].feature', (err, stdout) => {
|
|
242
|
-
// Check if step definitions pass
|
|
243
|
-
// Step definitions were created during feature discovery
|
|
244
|
-
// Your implementation must make them pass
|
|
245
|
-
});
|
|
246
|
-
```
|
|
247
|
-
|
|
248
|
-
3. **Check if BDD scenario passes**
|
|
249
|
-
- Run: `npm run test:bdd -- features/[feature-slug].feature`
|
|
250
|
-
- Step definitions execute your implementation code
|
|
251
|
-
- If yes: Move to final step
|
|
252
|
-
- If no: Analyze failure, adjust code, iterate
|
|
253
|
-
- **CRITICAL:** Tests must pass before moving on
|
|
254
|
-
|
|
255
|
-
4. **Display progress:**
|
|
256
|
-
```
|
|
257
|
-
✍️ Writing [file name]...
|
|
258
|
-
✅ Created [file name]
|
|
259
|
-
|
|
260
|
-
🧪 Running tests...
|
|
261
|
-
❌ Scenario failed: [error message]
|
|
262
|
-
🔧 Adjusting [specific fix]...
|
|
263
|
-
✅ Scenario passes!
|
|
264
|
-
```
|
|
265
|
-
|
|
266
|
-
**Speed mode constraints:**
|
|
267
|
-
- **Implement ALL scoped functionality** - if the scenario requires file upload, implement it (just assume it works)
|
|
268
|
-
- **Single file when possible** - keep it simple
|
|
269
|
-
- **NO error handling** - no try/catch, no validation, no edge cases
|
|
270
|
-
- **Assume everything works** - valid inputs, successful operations, correct types
|
|
271
|
-
- **localStorage/memory for data** - no full database setup
|
|
272
|
-
- **Inline code over separate modules** - keep it simple
|
|
273
|
-
- **Focus: Make. All. Features. Work.** (on the happy path)
|
|
274
|
-
|
|
275
|
-
**When scenario passes:**
|
|
276
|
-
|
|
277
|
-
```
|
|
278
|
-
🎉 Happy path scenario passes!
|
|
279
|
-
|
|
280
|
-
Implementation complete:
|
|
281
|
-
• Created: [list files]
|
|
282
|
-
• Modified: [list files]
|
|
283
|
-
• Tests: ✅ Passing
|
|
284
|
-
|
|
285
|
-
Now analyzing what was built to propose stable mode chores...
|
|
286
|
-
```
|
|
287
|
-
|
|
288
|
-
**Move to final step automatically.**
|
|
289
|
-
|
|
290
|
-
### Step 4: Generate Stable Mode Chores
|
|
291
|
-
|
|
292
|
-
**Two phases: Analyze and propose → Get confirmation → Create autonomously**
|
|
293
|
-
|
|
294
|
-
#### Phase 1: Analyze Implementation
|
|
295
|
-
|
|
296
|
-
**Your task:** Review what was built and identify what's needed for stable mode.
|
|
297
|
-
|
|
298
|
-
**Analysis checklist:**
|
|
299
|
-
|
|
300
|
-
1. **Error handling gaps**
|
|
301
|
-
- What user errors are possible?
|
|
302
|
-
- What system errors could occur?
|
|
303
|
-
- What validation is missing?
|
|
304
|
-
|
|
305
|
-
2. **Edge cases**
|
|
306
|
-
- Boundary conditions (empty inputs, max values, etc.)
|
|
307
|
-
- Race conditions
|
|
308
|
-
- State consistency issues
|
|
309
|
-
|
|
310
|
-
3. **Non-happy-path scenarios**
|
|
311
|
-
- Read the full scenario file (not just happy path)
|
|
312
|
-
- Identify scenarios 2+ (error handling, edge cases)
|
|
313
|
-
- Check what additional behavior is needed
|
|
314
|
-
|
|
315
|
-
4. **Code quality needs**
|
|
316
|
-
- What needs better structure/organization?
|
|
317
|
-
- What needs proper error messages?
|
|
318
|
-
- What needs logging/debugging support?
|
|
319
|
-
|
|
320
|
-
#### Phase 2: Propose Stable Mode Chores
|
|
321
|
-
|
|
322
|
-
**Present your analysis:**
|
|
323
|
-
|
|
324
|
-
```
|
|
325
|
-
📋 Stable Mode Chores Proposal
|
|
326
|
-
|
|
327
|
-
I've analyzed the implementation. Here are the chores needed for stable mode:
|
|
328
|
-
|
|
329
|
-
**Chore 1: [Title]**
|
|
330
|
-
- Why: [What gap this fills]
|
|
331
|
-
- Scope: [What specifically needs to be done]
|
|
332
|
-
- Scenario: [Which BDD scenario this addresses, if applicable]
|
|
333
|
-
|
|
334
|
-
**Chore 2: [Title]**
|
|
335
|
-
- Why: [What gap this fills]
|
|
336
|
-
- Scope: [What specifically needs to be done]
|
|
337
|
-
- Scenario: [Which BDD scenario this addresses, if applicable]
|
|
338
|
-
|
|
339
|
-
**Chore 3: [Title]**
|
|
340
|
-
- Why: [What gap this fills]
|
|
341
|
-
- Scope: [What specifically needs to be done]
|
|
342
|
-
- Scenario: [Which BDD scenario this addresses, if applicable]
|
|
343
|
-
|
|
344
|
-
These chores will make all BDD scenarios pass with proper error handling and edge case coverage.
|
|
345
|
-
|
|
346
|
-
Sound good? I'll create these chores once you confirm.
|
|
347
|
-
```
|
|
348
|
-
|
|
349
|
-
**WAIT for user confirmation or adjustments.**
|
|
350
|
-
|
|
351
|
-
If user adjusts: revise chores and confirm again.
|
|
352
|
-
|
|
353
|
-
#### Phase 3: Create Chores Autonomously
|
|
354
|
-
|
|
355
|
-
**CRITICAL:** After user confirms, create chores programmatically - no additional permission needed.
|
|
356
|
-
|
|
357
|
-
**Code to create chores:**
|
|
358
|
-
|
|
359
|
-
```javascript
|
|
360
|
-
const { create } = require('./features/work-tracking');
|
|
361
|
-
const { getCurrentWork } = require('../../lib/current-work');
|
|
362
|
-
|
|
363
|
-
const currentWork = getCurrentWork();
|
|
364
|
-
const featureId = currentWork.parent_id; // Parent feature
|
|
365
|
-
|
|
366
|
-
// For each confirmed chore:
|
|
367
|
-
await create('chore', 'Chore Title', 'Description', featureId, 'stable', false);
|
|
368
|
-
```
|
|
369
|
-
|
|
370
|
-
**Display results:**
|
|
371
|
-
|
|
372
|
-
```
|
|
373
|
-
✅ Created [N] stable mode chores
|
|
374
|
-
|
|
375
|
-
Chores created:
|
|
376
|
-
• #[ID]: [Title]
|
|
377
|
-
• #[ID]: [Title]
|
|
378
|
-
• #[ID]: [Title]
|
|
379
|
-
```
|
|
380
|
-
|
|
381
|
-
#### Phase 4: Auto-Elevate to Stable Mode (If All Speed Chores Done)
|
|
382
|
-
|
|
383
|
-
**CRITICAL: Check if ALL speed mode chores are complete. If yes, auto-elevate to stable mode.**
|
|
384
|
-
|
|
385
|
-
```javascript
|
|
386
|
-
// Check if all speed chores for this feature are done
|
|
387
|
-
const { getDb } = require('../../lib/database');
|
|
388
|
-
const { getCurrentWork } = require('../../lib/current-work');
|
|
389
|
-
|
|
390
|
-
const currentWork = getCurrentWork();
|
|
391
|
-
const featureId = currentWork.parent_id;
|
|
392
|
-
|
|
393
|
-
const db = getDb();
|
|
394
|
-
db.get(`
|
|
395
|
-
SELECT COUNT(*) as incomplete_count
|
|
396
|
-
FROM work_items
|
|
397
|
-
WHERE parent_id = ?
|
|
398
|
-
AND type = 'chore'
|
|
399
|
-
AND mode = 'speed'
|
|
400
|
-
AND status != 'done'
|
|
401
|
-
`, [featureId], async (err, result) => {
|
|
402
|
-
if (err) {
|
|
403
|
-
console.error('Error checking speed chores:', err.message);
|
|
404
|
-
db.close();
|
|
405
|
-
return;
|
|
406
|
-
}
|
|
407
|
-
|
|
408
|
-
if (result.incomplete_count === 0) {
|
|
409
|
-
// All speed chores done - auto-elevate to stable
|
|
410
|
-
console.log('\n✅ All speed mode chores complete!');
|
|
411
|
-
console.log('Auto-elevating feature to stable mode...\n');
|
|
412
|
-
|
|
413
|
-
// Use Bash tool to execute elevation
|
|
414
|
-
// DO NOT display as text - EXECUTE IT
|
|
415
|
-
} else {
|
|
416
|
-
console.log(`\n📋 ${result.incomplete_count} speed mode chores remaining`);
|
|
417
|
-
}
|
|
418
|
-
|
|
419
|
-
db.close();
|
|
420
|
-
});
|
|
421
|
-
```
|
|
422
|
-
|
|
423
|
-
**If all speed chores are done, use Bash tool to EXECUTE elevation:**
|
|
424
|
-
|
|
425
|
-
```javascript
|
|
426
|
-
// Use Bash tool to execute:
|
|
427
|
-
node jettypod.js work elevate [feature-id] stable
|
|
428
|
-
```
|
|
429
|
-
|
|
430
|
-
**DO NOT display this as example text. EXECUTE IT using the Bash tool.**
|
|
431
|
-
|
|
432
|
-
After execution, display:
|
|
433
|
-
|
|
434
|
-
```
|
|
435
|
-
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
436
|
-
🎯 Speed Mode Complete! Feature Elevated to Stable Mode
|
|
437
|
-
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
438
|
-
|
|
439
|
-
What we accomplished:
|
|
440
|
-
✅ Happy path scenario passes
|
|
441
|
-
✅ All speed mode chores complete
|
|
442
|
-
✅ Feature elevated to stable mode
|
|
443
|
-
✅ Stable mode chores created and ready
|
|
444
|
-
|
|
445
|
-
**Next step:** Start the first stable mode chore
|
|
446
|
-
jettypod work start [first-stable-chore-id]
|
|
447
|
-
```
|
|
448
|
-
|
|
449
|
-
**If speed chores remain, display:**
|
|
450
|
-
|
|
451
|
-
```
|
|
452
|
-
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
453
|
-
🎯 Speed Mode Chore Complete!
|
|
454
|
-
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
455
|
-
|
|
456
|
-
What we accomplished:
|
|
457
|
-
✅ Happy path scenario passes for this chore
|
|
458
|
-
✅ Stable mode chores created
|
|
459
|
-
|
|
460
|
-
Remaining speed mode chores: [count]
|
|
461
|
-
|
|
462
|
-
**Next step:** Continue with next speed mode chore
|
|
463
|
-
jettypod work start [next-speed-chore-id]
|
|
464
|
-
```
|
|
465
|
-
|
|
466
|
-
**Mark current chore as done:**
|
|
467
|
-
|
|
468
|
-
Use Bash tool to commit, push, and merge to main:
|
|
469
|
-
```bash
|
|
470
|
-
git add . && git commit -m "feat: [brief description of what was implemented]" && git push
|
|
471
|
-
```
|
|
472
|
-
|
|
473
|
-
Then merge to main (which auto-marks chore as done via git hooks):
|
|
474
|
-
```bash
|
|
475
|
-
git checkout main && git pull && git merge [branch-name] && git push
|
|
476
|
-
```
|
|
477
|
-
|
|
478
|
-
The post-merge hook will automatically mark the chore as done when merged to main.
|
|
479
|
-
|
|
480
|
-
**End skill.**
|
|
481
|
-
|