Skip to content

v1.3.0 - Pre-flight validation to prevent file corruption

Choose a tag to compare

@JRedeker JRedeker released this 25 Jan 22:08
· 61 commits to trunk since this release

Breaking Fix: Addresses file corruption reports from agents

This release fixes the issue where agents would report:

"File corruption during morph_edit - The test file appears to have lost code during the edit operations"

What's New

  • Pre-flight validation prevents accidental deletions - Tool now returns an error if code_edit is missing markers for files >10 lines, preventing catastrophic code loss
  • Improved code_edit parameter description - Changed from "Only the changed lines" to "The code changes wrapped with markers" to emphasize wrapping
  • Added explicit wrapping rule - Tool description now includes "ALWAYS wrap your changes with markers at the start AND end"
  • Restored comprehensive examples - MORPH_INSTRUCTIONS.md now includes all key examples (adding functions, modifying code, deletions)
  • Added Quick Reference - Aligned with Morph's official agent instructions format
  • Added fetch timeout example - From official Morph documentation

Upgrade

cd /path/to/opencode-morph-fast-apply
git pull origin trunk

Then restart OpenCode to pick up the changes.

Full Changelog

https://github.com/JRedeker/opencode-morph-fast-apply#changelog