{"repo":"NousResearch/hermes-agent","public_id":"84685","display_label":"TUI cleanup UnboundLocalError before history snapshot","summary":"A bug where TUI turn cleanup raises an UnboundLocalError because the history variable is referenced before assignment when an exception fires early. The members cover the bug report and two fixes that pre-bind or guard the history reference before the try block.","subsystem":"gateway","counts":{"members":3,"open_issues":1,"open_issues_distinct":1,"open_prs":1,"closed_issues":0,"merged_prs":0,"attempt_prs":2},"landed_fix":null,"resolution":{"state":"unresolved","by":null},"freshness":{"state":"never_verified","last_verified_at":null,"is_stale":false},"grouping":{"backbone":"STRUCTURAL_SPANNING","link_density":0.6666666666666666},"fix_edges":[],"members":[{"kind":"issue","number":84685,"title":"[Bug] TUI turn cleanup raises UnboundLocalError (history.clear) when an exception fires before the history snapshot","url":null,"state":"open"},{"kind":"pr","number":84692,"title":"fix(tui): pre-bind history before turn try so cleanup never raises UnboundLocalError","url":null,"state":"closed","close_reason":{"category":"silent_close","implication":"active"},"merged":false},{"kind":"pr","number":84970,"title":"fix(tui): guard prompt cleanup before history snapshot","url":null,"state":"open","close_reason":{"category":"implemented_elsewhere","implication":"superseded"},"merged":false}],"trust":{"default_tier":"verified","includes_suggested":false}}