@codemcp/workflows 6.0.1 → 6.0.2
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/package.json +3 -2
- package/packages/cli/package.json +1 -1
- package/packages/cli/resources/agents/architect.yaml +61 -0
- package/packages/cli/resources/agents/business-analyst.yaml +60 -0
- package/packages/cli/resources/agents/developer.yaml +61 -0
- package/packages/cli/resources/templates/architecture/arc42/arc42-template-EN.md +1077 -0
- package/packages/cli/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio-2023.png +0 -0
- package/packages/cli/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio.png +0 -0
- package/packages/cli/resources/templates/architecture/arc42/images/05_building_blocks-EN.png +0 -0
- package/packages/cli/resources/templates/architecture/arc42/images/08-concepts-EN.drawio.png +0 -0
- package/packages/cli/resources/templates/architecture/arc42/images/arc42-logo.png +0 -0
- package/packages/cli/resources/templates/architecture/c4.md +224 -0
- package/packages/cli/resources/templates/architecture/freestyle.md +53 -0
- package/packages/cli/resources/templates/architecture/game.md +250 -0
- package/packages/cli/resources/templates/architecture/none.md +17 -0
- package/packages/cli/resources/templates/design/comprehensive.md +207 -0
- package/packages/cli/resources/templates/design/freestyle.md +37 -0
- package/packages/cli/resources/templates/design/game.md +66 -0
- package/packages/cli/resources/templates/design/none.md +17 -0
- package/packages/cli/resources/templates/requirements/ears.md +90 -0
- package/packages/cli/resources/templates/requirements/freestyle.md +42 -0
- package/packages/cli/resources/templates/requirements/game.md +162 -0
- package/packages/cli/resources/templates/requirements/none.md +17 -0
- package/packages/cli/resources/templates/skills/POWER.md +23 -0
- package/packages/cli/resources/templates/skills/SKILL.md +19 -0
- package/packages/cli/resources/workflows/adr.yaml +157 -0
- package/packages/cli/resources/workflows/big-bang-conversion.yaml +592 -0
- package/packages/cli/resources/workflows/boundary-testing.yaml +376 -0
- package/packages/cli/resources/workflows/bugfix.yaml +177 -0
- package/packages/cli/resources/workflows/business-analysis.yaml +597 -0
- package/packages/cli/resources/workflows/c4-analysis.yaml +471 -0
- package/packages/cli/resources/workflows/epcc.yaml +183 -0
- package/packages/cli/resources/workflows/game-beginner.yaml +434 -0
- package/packages/cli/resources/workflows/greenfield.yaml +201 -0
- package/packages/cli/resources/workflows/minor.yaml +138 -0
- package/packages/cli/resources/workflows/posts.yaml +193 -0
- package/packages/cli/resources/workflows/sdd-bugfix-crowd.yaml +608 -0
- package/packages/cli/resources/workflows/sdd-bugfix.yaml +381 -0
- package/packages/cli/resources/workflows/sdd-feature-crowd.yaml +713 -0
- package/packages/cli/resources/workflows/sdd-feature.yaml +471 -0
- package/packages/cli/resources/workflows/sdd-greenfield-crowd.yaml +336 -0
- package/packages/cli/resources/workflows/sdd-greenfield.yaml +463 -0
- package/packages/cli/resources/workflows/slides.yaml +237 -0
- package/packages/cli/resources/workflows/tdd.yaml +160 -0
- package/packages/cli/resources/workflows/waterfall.yaml +209 -0
- package/packages/core/package.json +1 -1
- package/packages/core/resources/agents/architect.yaml +61 -0
- package/packages/core/resources/agents/business-analyst.yaml +60 -0
- package/packages/core/resources/agents/developer.yaml +61 -0
- package/packages/core/resources/templates/architecture/arc42/arc42-template-EN.md +1077 -0
- package/packages/core/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio-2023.png +0 -0
- package/packages/core/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio.png +0 -0
- package/packages/core/resources/templates/architecture/arc42/images/05_building_blocks-EN.png +0 -0
- package/packages/core/resources/templates/architecture/arc42/images/08-concepts-EN.drawio.png +0 -0
- package/packages/core/resources/templates/architecture/arc42/images/arc42-logo.png +0 -0
- package/packages/core/resources/templates/architecture/c4.md +224 -0
- package/packages/core/resources/templates/architecture/freestyle.md +53 -0
- package/packages/core/resources/templates/architecture/game.md +250 -0
- package/packages/core/resources/templates/architecture/none.md +17 -0
- package/packages/core/resources/templates/design/comprehensive.md +207 -0
- package/packages/core/resources/templates/design/freestyle.md +37 -0
- package/packages/core/resources/templates/design/game.md +66 -0
- package/packages/core/resources/templates/design/none.md +17 -0
- package/packages/core/resources/templates/requirements/ears.md +90 -0
- package/packages/core/resources/templates/requirements/freestyle.md +42 -0
- package/packages/core/resources/templates/requirements/game.md +162 -0
- package/packages/core/resources/templates/requirements/none.md +17 -0
- package/packages/core/resources/templates/skills/POWER.md +23 -0
- package/packages/core/resources/templates/skills/SKILL.md +19 -0
- package/packages/core/resources/workflows/adr.yaml +157 -0
- package/packages/core/resources/workflows/big-bang-conversion.yaml +592 -0
- package/packages/core/resources/workflows/boundary-testing.yaml +376 -0
- package/packages/core/resources/workflows/bugfix.yaml +177 -0
- package/packages/core/resources/workflows/business-analysis.yaml +597 -0
- package/packages/core/resources/workflows/c4-analysis.yaml +471 -0
- package/packages/core/resources/workflows/epcc.yaml +183 -0
- package/packages/core/resources/workflows/game-beginner.yaml +434 -0
- package/packages/core/resources/workflows/greenfield.yaml +201 -0
- package/packages/core/resources/workflows/minor.yaml +138 -0
- package/packages/core/resources/workflows/posts.yaml +193 -0
- package/packages/core/resources/workflows/sdd-bugfix-crowd.yaml +608 -0
- package/packages/core/resources/workflows/sdd-bugfix.yaml +381 -0
- package/packages/core/resources/workflows/sdd-feature-crowd.yaml +713 -0
- package/packages/core/resources/workflows/sdd-feature.yaml +471 -0
- package/packages/core/resources/workflows/sdd-greenfield-crowd.yaml +336 -0
- package/packages/core/resources/workflows/sdd-greenfield.yaml +463 -0
- package/packages/core/resources/workflows/slides.yaml +237 -0
- package/packages/core/resources/workflows/tdd.yaml +160 -0
- package/packages/core/resources/workflows/waterfall.yaml +209 -0
- package/packages/docs/package.json +1 -1
- package/packages/mcp-server/package.json +1 -1
- package/packages/mcp-server/resources/agents/architect.yaml +61 -0
- package/packages/mcp-server/resources/agents/business-analyst.yaml +60 -0
- package/packages/mcp-server/resources/agents/developer.yaml +61 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/arc42-template-EN.md +1077 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio-2023.png +0 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/images/01_2_iso-25010-topics-EN.drawio.png +0 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/images/05_building_blocks-EN.png +0 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/images/08-concepts-EN.drawio.png +0 -0
- package/packages/mcp-server/resources/templates/architecture/arc42/images/arc42-logo.png +0 -0
- package/packages/mcp-server/resources/templates/architecture/c4.md +224 -0
- package/packages/mcp-server/resources/templates/architecture/freestyle.md +53 -0
- package/packages/mcp-server/resources/templates/architecture/game.md +250 -0
- package/packages/mcp-server/resources/templates/architecture/none.md +17 -0
- package/packages/mcp-server/resources/templates/design/comprehensive.md +207 -0
- package/packages/mcp-server/resources/templates/design/freestyle.md +37 -0
- package/packages/mcp-server/resources/templates/design/game.md +66 -0
- package/packages/mcp-server/resources/templates/design/none.md +17 -0
- package/packages/mcp-server/resources/templates/requirements/ears.md +90 -0
- package/packages/mcp-server/resources/templates/requirements/freestyle.md +42 -0
- package/packages/mcp-server/resources/templates/requirements/game.md +162 -0
- package/packages/mcp-server/resources/templates/requirements/none.md +17 -0
- package/packages/mcp-server/resources/templates/skills/POWER.md +23 -0
- package/packages/mcp-server/resources/templates/skills/SKILL.md +19 -0
- package/packages/mcp-server/resources/workflows/adr.yaml +157 -0
- package/packages/mcp-server/resources/workflows/big-bang-conversion.yaml +592 -0
- package/packages/mcp-server/resources/workflows/boundary-testing.yaml +376 -0
- package/packages/mcp-server/resources/workflows/bugfix.yaml +177 -0
- package/packages/mcp-server/resources/workflows/business-analysis.yaml +597 -0
- package/packages/mcp-server/resources/workflows/c4-analysis.yaml +471 -0
- package/packages/mcp-server/resources/workflows/epcc.yaml +183 -0
- package/packages/mcp-server/resources/workflows/game-beginner.yaml +434 -0
- package/packages/mcp-server/resources/workflows/greenfield.yaml +201 -0
- package/packages/mcp-server/resources/workflows/minor.yaml +138 -0
- package/packages/mcp-server/resources/workflows/posts.yaml +193 -0
- package/packages/mcp-server/resources/workflows/sdd-bugfix-crowd.yaml +608 -0
- package/packages/mcp-server/resources/workflows/sdd-bugfix.yaml +381 -0
- package/packages/mcp-server/resources/workflows/sdd-feature-crowd.yaml +713 -0
- package/packages/mcp-server/resources/workflows/sdd-feature.yaml +471 -0
- package/packages/mcp-server/resources/workflows/sdd-greenfield-crowd.yaml +336 -0
- package/packages/mcp-server/resources/workflows/sdd-greenfield.yaml +463 -0
- package/packages/mcp-server/resources/workflows/slides.yaml +237 -0
- package/packages/mcp-server/resources/workflows/tdd.yaml +160 -0
- package/packages/mcp-server/resources/workflows/waterfall.yaml +209 -0
- package/packages/visualizer/package.json +1 -1
|
@@ -0,0 +1,381 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../state-machine-schema.json
|
|
2
|
+
---
|
|
3
|
+
name: 'sdd-bugfix'
|
|
4
|
+
description: 'Test and specification-driven bugfix workflow: Reproduce → Specify → Test → Plan → Fix → Verify'
|
|
5
|
+
initial_state: 'reproduce'
|
|
6
|
+
|
|
7
|
+
# Enhanced metadata for better discoverability
|
|
8
|
+
metadata:
|
|
9
|
+
domain: 'sdd'
|
|
10
|
+
complexity: 'medium'
|
|
11
|
+
bestFor:
|
|
12
|
+
- 'Systematic bug fixing'
|
|
13
|
+
- 'Test-driven bug resolution'
|
|
14
|
+
- 'Specification-driven debugging'
|
|
15
|
+
- 'Quality-focused fixes'
|
|
16
|
+
useCases:
|
|
17
|
+
- 'Fix complex bugs with clear specification'
|
|
18
|
+
- 'Resolve issues with comprehensive testing'
|
|
19
|
+
- 'Debug problems requiring systematic approach'
|
|
20
|
+
examples:
|
|
21
|
+
- 'Fix authentication flow bug with test coverage'
|
|
22
|
+
- 'Resolve data corruption issue with specification'
|
|
23
|
+
- 'Debug performance problem with systematic approach'
|
|
24
|
+
|
|
25
|
+
# States with default instructions and transitions
|
|
26
|
+
states:
|
|
27
|
+
reproduce:
|
|
28
|
+
description: 'Reproduce and understand the bug systematically'
|
|
29
|
+
default_instructions: |
|
|
30
|
+
**Systematically reproduce and understand the bug** to create a solid foundation for specification-driven fixing.
|
|
31
|
+
|
|
32
|
+
**STEP 1: Gather Comprehensive Information**
|
|
33
|
+
- Identify exact OS, browser/runtime versions, and hardware specs
|
|
34
|
+
- Document the precise sequence of actions that trigger the bug
|
|
35
|
+
- Collect error messages, logs, or stack traces
|
|
36
|
+
- Determine if bug occurs consistently or intermittently
|
|
37
|
+
- Assess how many users are affected and the business impact
|
|
38
|
+
|
|
39
|
+
**STEP 2: Create Reproduction Cases**
|
|
40
|
+
- Develop minimal, reliable reproduction steps
|
|
41
|
+
- Document the exact environment and conditions
|
|
42
|
+
- Create test data or scenarios that trigger the issue
|
|
43
|
+
- Verify the bug occurs consistently
|
|
44
|
+
|
|
45
|
+
**STEP 3: Understand the Problem**
|
|
46
|
+
- Clarify current (buggy) behavior
|
|
47
|
+
- Specify correct behavior that should occur
|
|
48
|
+
- Distinguish symptoms from root cause
|
|
49
|
+
- Identify related issues or edge cases
|
|
50
|
+
|
|
51
|
+
**STEP 4: Document Findings**
|
|
52
|
+
- Create `$VIBE_DIR/specs/$BRANCH_NAME/reproduction.md` with detailed reproduction steps
|
|
53
|
+
- Include error logs, screenshots, or other evidence
|
|
54
|
+
- Document the gap between expected and actual behavior
|
|
55
|
+
|
|
56
|
+
**Output**: Clear, reliable reproduction case to verify the fix later.
|
|
57
|
+
|
|
58
|
+
transitions:
|
|
59
|
+
- trigger: 'bug_reproduced'
|
|
60
|
+
to: 'specify'
|
|
61
|
+
transition_reason: 'Bug reproduced successfully, ready to specify correct behavior'
|
|
62
|
+
|
|
63
|
+
- trigger: 'bug_not_reproducible'
|
|
64
|
+
to: 'reproduce'
|
|
65
|
+
instructions: >
|
|
66
|
+
Gather more details about the environment, conditions, or steps that might be missing from the current information.
|
|
67
|
+
Contact the reporter for additional information if needed.
|
|
68
|
+
transition_reason: 'Bug could not be reproduced, need more information'
|
|
69
|
+
|
|
70
|
+
specify:
|
|
71
|
+
description: 'Create specification of correct behavior'
|
|
72
|
+
default_instructions: |
|
|
73
|
+
**Create a clear specification of the correct behavior** to guide the fix and prevent regressions.
|
|
74
|
+
|
|
75
|
+
**STEP 1: Define Correct Behavior**
|
|
76
|
+
- Describe what should happen in the scenario that currently fails
|
|
77
|
+
- Specify expected outcomes for users
|
|
78
|
+
- Clarify system behavior in edge cases
|
|
79
|
+
- Document business rules that should be enforced
|
|
80
|
+
|
|
81
|
+
**STEP 2: Handle Ambiguities**
|
|
82
|
+
- Make informed decisions about unclear requirements
|
|
83
|
+
- Use `[NEEDS CLARIFICATION: question]` only for critical ambiguities (max 3)
|
|
84
|
+
- Prioritize: correctness > user experience > technical details
|
|
85
|
+
|
|
86
|
+
**STEP 3: Ensure Quality Standards**
|
|
87
|
+
- Focus on user impact and business value
|
|
88
|
+
- Avoid implementation details
|
|
89
|
+
- Ensure all requirements are testable
|
|
90
|
+
- Make success criteria measurable
|
|
91
|
+
|
|
92
|
+
**STEP 4: Document Specification**
|
|
93
|
+
- Create `$VIBE_DIR/specs/$BRANCH_NAME/bug-spec.md` using the template provided below
|
|
94
|
+
additional_instructions: |
|
|
95
|
+
**Bug Specification Template:**
|
|
96
|
+
|
|
97
|
+
Use this template to create your `bug-spec.md` file:
|
|
98
|
+
|
|
99
|
+
```markdown
|
|
100
|
+
# Bug Fix Specification: [BUG TITLE]
|
|
101
|
+
|
|
102
|
+
**Created**: [DATE]
|
|
103
|
+
**Bug Report**: [Reference to original bug report]
|
|
104
|
+
|
|
105
|
+
## Current Problem
|
|
106
|
+
|
|
107
|
+
**Description**: [Clear description of the bug and its impact]
|
|
108
|
+
|
|
109
|
+
**Symptoms**: [What users experience when the bug occurs]
|
|
110
|
+
|
|
111
|
+
**Impact**: [Business impact, user frustration, data issues, etc.]
|
|
112
|
+
|
|
113
|
+
## Expected Behavior
|
|
114
|
+
|
|
115
|
+
**Correct Functionality**: [Detailed specification of how it should work]
|
|
116
|
+
|
|
117
|
+
**User Experience**: [How users should be able to interact with the fixed system]
|
|
118
|
+
|
|
119
|
+
**Business Rules**: [Rules that should be enforced]
|
|
120
|
+
|
|
121
|
+
## User Scenarios
|
|
122
|
+
|
|
123
|
+
### Scenario 1 - [Primary Fix Scenario]
|
|
124
|
+
|
|
125
|
+
**Given** [initial state]
|
|
126
|
+
**When** [action that currently fails]
|
|
127
|
+
**Then** [expected correct outcome]
|
|
128
|
+
|
|
129
|
+
### Scenario 2 - [Edge Case Scenario]
|
|
130
|
+
|
|
131
|
+
**Given** [edge case state]
|
|
132
|
+
**When** [edge case action]
|
|
133
|
+
**Then** [expected correct outcome]
|
|
134
|
+
|
|
135
|
+
[Add more scenarios as needed]
|
|
136
|
+
|
|
137
|
+
## Functional Requirements
|
|
138
|
+
|
|
139
|
+
- **FR-001**: System MUST [correct behavior requirement]
|
|
140
|
+
- **FR-002**: System MUST [error handling requirement]
|
|
141
|
+
- **FR-003**: System MUST [data integrity requirement]
|
|
142
|
+
- **FR-004**: System MUST [user feedback requirement]
|
|
143
|
+
|
|
144
|
+
## Success Criteria
|
|
145
|
+
|
|
146
|
+
### Fix Validation
|
|
147
|
+
|
|
148
|
+
- **SC-001**: Original reproduction case no longer occurs
|
|
149
|
+
- **SC-002**: All user scenarios work as specified
|
|
150
|
+
- **SC-003**: [Performance/reliability metric if applicable]
|
|
151
|
+
- **SC-004**: No regressions in related functionality
|
|
152
|
+
|
|
153
|
+
### User Impact
|
|
154
|
+
|
|
155
|
+
- **SC-005**: [Measurable improvement in user experience]
|
|
156
|
+
- **SC-006**: [Reduction in error rates or support tickets]
|
|
157
|
+
|
|
158
|
+
## Edge Cases
|
|
159
|
+
|
|
160
|
+
- What happens when [boundary condition]?
|
|
161
|
+
- How does system handle [error scenario]?
|
|
162
|
+
- What about [related functionality]?
|
|
163
|
+
|
|
164
|
+
## Assumptions
|
|
165
|
+
|
|
166
|
+
- [Document any assumptions about correct behavior]
|
|
167
|
+
- [Include decisions made about ambiguous requirements]
|
|
168
|
+
|
|
169
|
+
## Dependencies
|
|
170
|
+
|
|
171
|
+
- [Related systems that must continue working]
|
|
172
|
+
- [Integration points that must be preserved]
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
Fill in all sections with specific details about the correct behavior that should replace the current buggy behavior.
|
|
176
|
+
|
|
177
|
+
transitions:
|
|
178
|
+
- trigger: 'specification_complete'
|
|
179
|
+
to: 'test'
|
|
180
|
+
transition_reason: 'Bug specification completed, ready to create tests'
|
|
181
|
+
|
|
182
|
+
- trigger: 'needs_clarification'
|
|
183
|
+
to: 'specify'
|
|
184
|
+
instructions: >
|
|
185
|
+
Present structured questions to stakeholders about unresolved clarifications in the bug specification.
|
|
186
|
+
Wait for their responses, then update the specification accordingly.
|
|
187
|
+
transition_reason: 'Bug specification needs clarification before proceeding'
|
|
188
|
+
|
|
189
|
+
test:
|
|
190
|
+
description: 'Create comprehensive tests that capture the bug and expected behavior'
|
|
191
|
+
default_instructions: |
|
|
192
|
+
**Create comprehensive tests** that capture both the current bug and the expected correct behavior to guide the fix and prevent regressions.
|
|
193
|
+
|
|
194
|
+
**STEP 1: Create Failing Tests for Current Bug**
|
|
195
|
+
- Write tests that demonstrate the current buggy behavior
|
|
196
|
+
- These tests should fail initially (Red phase of TDD)
|
|
197
|
+
- Cover the main reproduction case and related scenarios
|
|
198
|
+
- Include edge cases and boundary conditions
|
|
199
|
+
|
|
200
|
+
**STEP 2: Create Tests for Expected Behavior**
|
|
201
|
+
- Write tests that specify the correct behavior from `$VIBE_DIR/specs/$BRANCH_NAME/bug-spec.md`
|
|
202
|
+
- These tests should pass once the bug is fixed
|
|
203
|
+
- Cover all functional requirements from the specification
|
|
204
|
+
- Include user scenarios and success criteria
|
|
205
|
+
|
|
206
|
+
**STEP 3: Create Regression Tests**
|
|
207
|
+
- Write tests for related functionality that should not be affected
|
|
208
|
+
- Ensure the fix doesn't break existing features
|
|
209
|
+
- Test integration points and dependencies
|
|
210
|
+
|
|
211
|
+
**STEP 4: Organize Test Suite**
|
|
212
|
+
- Group tests by functionality and user scenarios
|
|
213
|
+
- Use clear, descriptive test names
|
|
214
|
+
- Include both unit and integration tests as appropriate
|
|
215
|
+
- Document test setup and data requirements
|
|
216
|
+
|
|
217
|
+
**Output**: Comprehensive test suite in appropriate test files to guide the fix implementation.
|
|
218
|
+
|
|
219
|
+
transitions:
|
|
220
|
+
- trigger: 'tests_created'
|
|
221
|
+
to: 'plan'
|
|
222
|
+
transition_reason: 'Tests created for bug and expected behavior, ready to plan the fix'
|
|
223
|
+
|
|
224
|
+
plan:
|
|
225
|
+
description: 'Plan the fix approach with constitutional compliance'
|
|
226
|
+
default_instructions: |
|
|
227
|
+
**Plan the fix approach** to ensure the solution aligns with system architecture and quality principles.
|
|
228
|
+
|
|
229
|
+
**STEP 1: Load Context**
|
|
230
|
+
- Read bug specification from `$VIBE_DIR/specs/$BRANCH_NAME/bug-spec.md`
|
|
231
|
+
- Review reproduction case from `$VIBE_DIR/specs/$BRANCH_NAME/reproduction.md`
|
|
232
|
+
- Understand the test requirements
|
|
233
|
+
- Analyze existing codebase and architecture
|
|
234
|
+
|
|
235
|
+
**STEP 2: Perform Root Cause Analysis**
|
|
236
|
+
- Identify the underlying cause of the bug
|
|
237
|
+
- Understand why the current implementation fails
|
|
238
|
+
- Map the problem to specific code areas or logic flaws
|
|
239
|
+
- Consider systemic issues vs. isolated bugs
|
|
240
|
+
|
|
241
|
+
**STEP 3: Design Fix Strategy**
|
|
242
|
+
- Design minimal, targeted fix that addresses root cause
|
|
243
|
+
- Ensure fix aligns with existing architectural patterns
|
|
244
|
+
- Consider impact on related functionality
|
|
245
|
+
- Plan for backward compatibility if needed
|
|
246
|
+
|
|
247
|
+
**STEP 4: Verify Constitutional/Quality Compliance**
|
|
248
|
+
- Ensure fix follows system design principles
|
|
249
|
+
- Verify approach maintains code quality standards
|
|
250
|
+
- Check that fix doesn't introduce technical debt
|
|
251
|
+
- Validate solution is maintainable and testable
|
|
252
|
+
|
|
253
|
+
**STEP 5: Create Implementation Plan**
|
|
254
|
+
- Break down fix into specific, actionable tasks
|
|
255
|
+
- Identify files and components that need changes
|
|
256
|
+
- Plan testing and validation approach
|
|
257
|
+
- Consider rollout and deployment strategy
|
|
258
|
+
|
|
259
|
+
**Output**: Create `$VIBE_DIR/specs/$BRANCH_NAME/fix-plan.md` with detailed approach for implementing the bug fix.
|
|
260
|
+
|
|
261
|
+
transitions:
|
|
262
|
+
- trigger: 'plan_complete'
|
|
263
|
+
to: 'fix'
|
|
264
|
+
transition_reason: 'Fix plan completed, ready to implement the solution'
|
|
265
|
+
|
|
266
|
+
- trigger: 'architectural_conflict'
|
|
267
|
+
to: 'plan'
|
|
268
|
+
instructions: >
|
|
269
|
+
Revise the approach to address conflicts with system architecture or quality principles.
|
|
270
|
+
Ensure proper integration and maintainability of the planned fix.
|
|
271
|
+
transition_reason: 'Fix plan conflicts with architecture, needs revision'
|
|
272
|
+
|
|
273
|
+
fix:
|
|
274
|
+
description: 'Implement the minimal fix to make tests pass'
|
|
275
|
+
default_instructions: |
|
|
276
|
+
**Implement the bug fix** following the plan and making the tests pass with minimal, targeted changes.
|
|
277
|
+
|
|
278
|
+
**STEP 1: Execute Fix Strategy**
|
|
279
|
+
- Follow the fix strategy from `$VIBE_DIR/specs/$BRANCH_NAME/fix-plan.md`
|
|
280
|
+
- Make targeted changes to address the root cause
|
|
281
|
+
- Avoid over-engineering or unnecessary modifications
|
|
282
|
+
- Keep changes minimal and focused
|
|
283
|
+
|
|
284
|
+
**STEP 2: Apply Test-Driven Implementation**
|
|
285
|
+
- Run the failing tests to confirm they capture the bug
|
|
286
|
+
- Implement changes to make the tests pass (Green phase)
|
|
287
|
+
- Ensure all new tests pass while maintaining existing functionality
|
|
288
|
+
|
|
289
|
+
**STEP 3: Maintain Quality Standards**
|
|
290
|
+
- Follow existing code patterns and conventions
|
|
291
|
+
- Maintain or improve code readability
|
|
292
|
+
- Add appropriate error handling
|
|
293
|
+
- Include necessary logging or monitoring
|
|
294
|
+
|
|
295
|
+
**STEP 4: Validate Implementation**
|
|
296
|
+
- Verify the original reproduction case no longer occurs
|
|
297
|
+
- Run full test suite to check for regressions
|
|
298
|
+
- Test edge cases and boundary conditions
|
|
299
|
+
- Validate fix meets success criteria from specification
|
|
300
|
+
|
|
301
|
+
**STEP 5: Track Progress**
|
|
302
|
+
- Document any deviations from the original plan
|
|
303
|
+
- Note any additional issues discovered during implementation
|
|
304
|
+
- Update tests if new edge cases are found
|
|
305
|
+
|
|
306
|
+
transitions:
|
|
307
|
+
- trigger: 'fix_implemented'
|
|
308
|
+
to: 'verify'
|
|
309
|
+
transition_reason: 'Bug fix implemented and tests passing, ready for verification'
|
|
310
|
+
|
|
311
|
+
- trigger: 'fix_blocked'
|
|
312
|
+
to: 'plan'
|
|
313
|
+
instructions: >
|
|
314
|
+
Return to planning to revise the approach or break down the problem further.
|
|
315
|
+
Fix implementation is blocked by technical issues or complexity that need to be resolved.
|
|
316
|
+
transition_reason: 'Fix implementation blocked, need to revise plan'
|
|
317
|
+
|
|
318
|
+
- trigger: 'tests_failing'
|
|
319
|
+
to: 'test'
|
|
320
|
+
instructions: >
|
|
321
|
+
Review and update the test suite to better capture the requirements.
|
|
322
|
+
Tests are failing in unexpected ways, indicating the test design may need revision.
|
|
323
|
+
transition_reason: 'Tests failing unexpectedly, need to revise test approach'
|
|
324
|
+
|
|
325
|
+
verify:
|
|
326
|
+
description: 'Verify the fix works and does not introduce regressions'
|
|
327
|
+
default_instructions: |
|
|
328
|
+
**Verify the bug fix** works correctly and doesn't introduce any regressions or new issues.
|
|
329
|
+
|
|
330
|
+
**STEP 1: Verify Bug Resolution**
|
|
331
|
+
- Confirm the original reproduction case no longer occurs
|
|
332
|
+
- Verify all scenarios from `$VIBE_DIR/specs/$BRANCH_NAME/bug-spec.md` work correctly
|
|
333
|
+
- Test the fix in the original environment where the bug was reported
|
|
334
|
+
- Validate that success criteria are met
|
|
335
|
+
|
|
336
|
+
**STEP 2: Perform Regression Testing**
|
|
337
|
+
- Run full test suite to ensure no existing functionality is broken
|
|
338
|
+
- Test related features and integration points
|
|
339
|
+
- Verify performance hasn't degraded
|
|
340
|
+
- Check that the fix doesn't introduce new edge case failures
|
|
341
|
+
|
|
342
|
+
**STEP 3: Validate User Acceptance**
|
|
343
|
+
- Test from user perspective using real scenarios
|
|
344
|
+
- Verify the fix addresses the original user problem
|
|
345
|
+
- Ensure user experience is improved, not just technically correct
|
|
346
|
+
- Consider having original bug reporter validate the fix
|
|
347
|
+
|
|
348
|
+
**STEP 4: Update Documentation**
|
|
349
|
+
- Update relevant documentation if behavior has changed
|
|
350
|
+
- Document the fix approach for future reference
|
|
351
|
+
- Prepare release notes or change log entries
|
|
352
|
+
- Consider if this fix reveals systemic issues to address
|
|
353
|
+
|
|
354
|
+
**Final Validation Checklist**:
|
|
355
|
+
- All tests pass (both new and existing)
|
|
356
|
+
- Original bug reproduction case fails (bug is fixed)
|
|
357
|
+
- No regressions detected
|
|
358
|
+
- User scenarios work as specified
|
|
359
|
+
|
|
360
|
+
transitions:
|
|
361
|
+
- trigger: 'regression_detected'
|
|
362
|
+
to: 'fix'
|
|
363
|
+
instructions: >
|
|
364
|
+
Return to implementation to address the problems.
|
|
365
|
+
The fix has introduced new issues or broken existing functionality.
|
|
366
|
+
transition_reason: 'Regression detected, need to revise fix implementation'
|
|
367
|
+
|
|
368
|
+
- trigger: 'fix_insufficient'
|
|
369
|
+
to: 'specify'
|
|
370
|
+
instructions: >
|
|
371
|
+
Return to specification to better define the requirements.
|
|
372
|
+
The fix doesn't fully address the original problem or reveals incomplete specification.
|
|
373
|
+
transition_reason: 'Fix insufficient, need to revise specification'
|
|
374
|
+
|
|
375
|
+
# Global transitions available from any state
|
|
376
|
+
global_transitions:
|
|
377
|
+
- trigger: 'abandon_bugfix'
|
|
378
|
+
to: 'reproduce'
|
|
379
|
+
instructions: >
|
|
380
|
+
If you want to restart, you'll begin again with reproducing and understanding the bug.
|
|
381
|
+
transition_reason: 'Bug fix abandoned, restart from beginning'
|