Skip to content

Changing a blocked task to In Progress can immediately move it to Backlog #674

Description

@kylecarbonneau

Opening as an issue instead of a PR, since I’m not sure if this is intentional or a bug. Expected behavior was that manually marking as In Progress would move the task from Blocked to In Progress, not back to the Backlog.

Steps to reproduce

  1. Execute a task and let it become blocked while its executor poller remains alive, such as at a permission prompt.
  2. Press Shift-S and change its status to In Progress.
  3. Observe the task briefly enter In Progress, then move to Backlog.

Expected behavior

The task remains queued/In Progress and resumes through a fresh executor run.

Actual behavior

The previous executor poller sees the internal queued status and returns Interrupted. Finalization treats that as a user cancellation and changes the task to backlog.

Relevant flow:

  • showChangeStatus maps In Progress to StatusQueued.
  • pollTmuxSession returns Interrupted: true upon seeing StatusQueued.
  • executeTask handles every interrupted result by writing StatusBacklog.

This appears timing-dependent because it requires the previous poller to remain registered.

Suggested fix

Distinguish requeueing from genuine interruption. Preserve queued when the old poller exits, release its running-task slot, and wake the worker for a fresh execution.

Environment

  • TaskYou: 0.3.18
  • Go: 1.24.4
  • OS: macOS 26.5.1, arm64

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions