fix(sling): auto-apply mol-polecat-work (#288) and fix wisp orphan lifecycle bug (#842) Fixes the formula-on-bead pattern to hook the base bead instead of the wisp: - Auto-apply mol-polecat-work when slinging bare beads to polecats - Hook BASE bead with attached_molecule pointing to wisp - gt done now closes attached molecule before closing hooked bead - Convoys complete properly when work finishes Fixes #288, #842, #858
This commit is contained in:
@@ -501,6 +501,23 @@ func checkSlungWork(ctx RoleContext) bool {
|
||||
}
|
||||
fmt.Println()
|
||||
|
||||
// Check for attached molecule and show execution prompt
|
||||
// This was missing for hooked beads (only worked for pinned beads).
|
||||
// With formula-on-bead, the base bead is hooked with attached_molecule pointing to wisp.
|
||||
attachment := beads.ParseAttachmentFields(hookedBead)
|
||||
if attachment != nil && attachment.AttachedMolecule != "" {
|
||||
fmt.Printf("%s\n\n", style.Bold.Render("## 🎯 ATTACHED MOLECULE"))
|
||||
fmt.Printf("Molecule: %s\n", attachment.AttachedMolecule)
|
||||
if attachment.AttachedArgs != "" {
|
||||
fmt.Printf("\n%s\n", style.Bold.Render("📋 ARGS (use these to guide execution):"))
|
||||
fmt.Printf(" %s\n", attachment.AttachedArgs)
|
||||
}
|
||||
fmt.Println()
|
||||
|
||||
// Show current step from molecule
|
||||
showMoleculeExecutionPrompt(ctx.WorkDir, attachment.AttachedMolecule)
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user