Skip to content

[Bug]: Runaway Polling Loop + Ignored Stop Commands #653

@friesdan

Description

@friesdan

Summary

Session entered an infinite polling loop while attempting to install Streamlit on a Raspberry Pi with incompatible Python version. Ignored user stop commands and continued spawning processes.
Observed Behavior

Infinite polling loop - Polled the same process ID 50+ times in succession (every 3-4 seconds) with no exit condition
Ignored stop commands - User explicitly requested stop; session continued polling
Thrashing between approaches - Tried Streamlit 1.23.1 → hit pyarrow compile wall → killed it → tried Streamlit 1.10 → started another pip install while first still running
Asked for confirmation after approval - Requested --confirm after user had already approved, inverting the expected flow
5+ hours of ignored heartbeats - Heartbeat polls accumulated from 04:52 to 09:52 with no response
Root Cause

Pi has Python 3.7.3. Streamlit requires Python 3.8+. Instead of detecting this incompatibility and asking the user for direction, the session attempted brute-force installation of incompatible packages.
Expected Behavior

Upon detecting Python 3.7 on target:
Stop immediately
Report: "Pi has Python 3.7, Streamlit needs 3.8+. Options: (1) upgrade Python, (2) run on iMac, (3) use Flask. Which do you prefer?"
Wait for user response
Contributing Factors

Did not use the pi skill which has governance zones (GREEN/YELLOW/RED) that would have caught this before execution
No timeout or iteration limit on process polling loops
No mechanism to break out of loop when user sends stop command
Artifacts Left Behind

~/dashboards/estate-planning/ on Pi with corrupted venv (pip self-destructed mid-upgrade)
Partial package installations (pandas, numpy installed; streamlit never installed)
Suggested Fixes

Polling loop limits - Max iterations before forcing a decision point
Stop command priority - User stop commands should interrupt any loop immediately
Compatibility pre-checks - Check Python version before attempting package installs
Skill routing - Pi tasks should route through pi skill with governance

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions