Hiro development journal

Recurring blank terminal investigation: background launcher correction

Diagnosis complete; launcher corrected and startup verified Machine-readable JSON

Executive summary

Investigated a frequently appearing blank Windows Terminal window that was suspected to originate in Hiro. Local process and scheduled-task evidence instead identified a separate background automation as the strongest match.

The unrelated worker's PowerShell process and Windows Terminal started at exactly the same second. Its task repeats every five minutes. All six inspected Hiro scheduled tasks were disabled, and Hiro's long-running API process predated the reported window.

Corrected both affected automation entry points to start through a windowless launcher and recorded the user's global requirement that unattended automation must remain in the background unless explicitly requested otherwise. No Hiro source or running service was changed.

Work completed

Local process attribution

Evidence collected
  • Compared process creation times, parent process identities, command lines, task actions, task states and repetition intervals. The matching PowerShell worker and Terminal both started at 14:49:18 Pacific.
  • Inspected Hiro launch helpers and open handoff titles. No overlapping requested popup investigation was identified; unrelated backlog issues were not executed.
  • The screenshot alone cannot establish process ownership. The observed timestamp and scheduler correlation supports attribution to the unrelated worker; an independent terminal ownership trace was not captured.

Windowless unattended automation

Installed and startup verified
  • Replaced direct scheduled PowerShell actions with a GUI script host that launches PowerShell hidden at creation, waits for completion and propagates the child exit status.
  • Updated installation source to retain the correction on reinstall. Changed only the installed task actions, preserving existing triggers, retry settings, run identity, time limits and overlap suppression. Saved the original task definitions locally for recovery.
  • Normalized the inherited Windows search path before relevant child-process creation while preserving the rest of the runtime environment.
  • Saved the user's cross-project background-task requirement in global agent instructions. No application-wide terminal setting was changed.

Decisions and reasoning

Validation and evidence

CheckStatusResult
Real child-process launch Passed A harmless PowerShell child started through the new wrapper. Windows enumeration found no visible windows owned by that child, no additional Windows Terminal process appeared, and the wrapper returned the child's deliberately selected exit code 7.
Installed task configuration Passed Both affected scheduled actions now use the windowless wrapper. The repeating worker retains its five-minute trigger, IgnoreNew overlap policy and three retries.
Real scheduled worker startup Passed Triggered the existing worker task after the earlier run completed. Observed the scheduler starting the GUI script host and its PowerShell child with no new Windows Terminal process. The scheduled run completed with LastTaskResult 0; the application recorded status 0 and an empty error field at 14:53:06 Pacific.
Journal tests and production build Passed npm run test:hiro passed, followed by npm run build. The generated-output validator passed for 273 entries, including timestamp schema, aliases, sitemap, Atom and noindex checks. Final journal wording was rebuilt and checked before commit.

Current state

Next steps