docs(post-mortem): Apply session start checklists and edit tool warnings
From gui_decoupling_controller track post-mortem: workflow.md: - Add mandatory session start checklist (6 items) - Add code style section with 1-space indentation enforcement - Add native edit tool warning with MCP alternatives AGENTS.md: - Add critical native edit tool warning - Document MCP tool alternatives for file editing tier1-orchestrator.md: - Add session start checklist tier2-tech-lead.md: - Add session start checklist - Add tool restrictions section (allowed vs forbidden) - Add explicit delegation pattern tier3-worker.md: - Add task start checklist tier4-qa.md: - Add analysis start checklist
This commit is contained in:
35
AGENTS.md
35
AGENTS.md
@@ -91,17 +91,36 @@ When uncertain about threading, event flow, data structures, or module interacti
|
||||
|
||||
## Code Style
|
||||
|
||||
- **IMPORTANT**: DO NOT ADD ***ANY*** COMMENTS unless asked
|
||||
- Use 1-space indentation for Python code
|
||||
- Use type hints where appropriate
|
||||
## Code Style
|
||||
|
||||
- **IMPORTANT**: DO NOT ADD ***ANY*** COMMENTS unless asked
|
||||
- Use 1-space indentation for Python code
|
||||
- Use type hints where appropriate
|
||||
- Internal methods/variables prefixed with underscore
|
||||
|
||||
## Quality Gates
|
||||
### CRITICAL: Native Edit Tool Destroys Indentation
|
||||
|
||||
Before marking any task complete:
|
||||
- [ ] All tests pass
|
||||
- [ ] Code coverage meets requirements (>80%)
|
||||
- [ ] Code follows project's code style guidelines
|
||||
- [ ] All public functions documented (docstrings)
|
||||
- [ ] Type safety enforced (type hints)
|
||||
- [ ] No linting or static analysis errors
|
||||
The native `Edit` tool DESTROYS 1-space indentation and converts to 4-space.
|
||||
|
||||
**NEVER use native `edit` tool on Python files.**
|
||||
|
||||
Instead, use Manual Slop MCP tools:
|
||||
- `manual-slop_py_update_definition` - Replace function/class
|
||||
- `manual-slop_set_file_slice` - Replace line range
|
||||
- `manual-slop_py_set_signature` - Replace signature only
|
||||
|
||||
Or use Python subprocess with `newline=''` to preserve line endings:
|
||||
```python
|
||||
python -c "
|
||||
with open('file.py', 'r', encoding='utf-8', newline='') as f:
|
||||
content = f.read()
|
||||
content = content.replace(old, new)
|
||||
with open('file.py', 'w', encoding='utf-8', newline='') as f:
|
||||
f.write(content)
|
||||
"
|
||||
```
|
||||
|
||||
## Quality Gates
|
||||
|
||||
Reference in New Issue
Block a user