Implement question queue feature, improve session & branch switch, add /abort command, support codex/copilot CLI native sessions#26
Merged
Conversation
…d message flow Mix bot-managed and native Codex/Copilot sessions in /switch, import native sessions into bot state, and refine session/provider/branch state handling for smoother cross-device continuation. Harden branch preparation and fallback behavior by checking real remote branch existence, rolling back failed origin-based prep, and prompting users through branch discrepancy recovery instead of silently switching. Add stronger runtime handling for busy projects: queue later text messages to disk, process queued question files after the active run, and prompt before continuing queued work when the previous run was aborted. Tighten agent progress and abort behavior, keep /abort and /current usable while a project is busy, and expand README plus regression tests to cover queueing, switching, branch recovery, and abort flows.
Move default state and log storage under ~/.coding-agent-telegram, remove STATE_FILE/STATE_BACKUP_FILE/LOG_DIR env configuration, and update startup, config loading, env template, CLI guidance, and README to match the simplified home-based layout with local state-file backward compatibility. Refactor session_commands.py into focused mixins for provider selection, lifecycle handling, branch resolution, and session status while keeping the legacy session_commands wrapper path for compatibility. Align Copilot behavior with the native CLI by stopping project-scoped COPILOT_HOME injection, discovering native Copilot sessions from ~/.copilot unless COPILOT_HOME is explicitly set, and using human-readable fallback labels when native session metadata lacks a summary or event history. Remove the built-in agent prompt prefix, improve queued-question handoff prompting so the agent reads the queue file instead of answering about the path itself, and normalize abort messages so users consistently see 'Agent run aborted by /abort.' instead of sanitized path placeholders. Expand regression coverage for config defaults, Copilot discovery, queue-file prompting, and abort-message sanitization.
dcha-agent
added a commit
that referenced
this pull request
Mar 28, 2026
…nd, support codex/copilot CLI native sessions (#26) * Improve session switching, branch recovery, abort handling, and queued message flow Mix bot-managed and native Codex/Copilot sessions in /switch, import native sessions into bot state, and refine session/provider/branch state handling for smoother cross-device continuation. Harden branch preparation and fallback behavior by checking real remote branch existence, rolling back failed origin-based prep, and prompting users through branch discrepancy recovery instead of silently switching. Add stronger runtime handling for busy projects: queue later text messages to disk, process queued question files after the active run, and prompt before continuing queued work when the previous run was aborted. Tighten agent progress and abort behavior, keep /abort and /current usable while a project is busy, and expand README plus regression tests to cover queueing, switching, branch recovery, and abort flows. * Move .coding_agent_telegram and .env_coding_agent_telegram to home folder * Align Copilot state with native CLI and split session command logic Move default state and log storage under ~/.coding-agent-telegram, remove STATE_FILE/STATE_BACKUP_FILE/LOG_DIR env configuration, and update startup, config loading, env template, CLI guidance, and README to match the simplified home-based layout with local state-file backward compatibility. Refactor session_commands.py into focused mixins for provider selection, lifecycle handling, branch resolution, and session status while keeping the legacy session_commands wrapper path for compatibility. Align Copilot behavior with the native CLI by stopping project-scoped COPILOT_HOME injection, discovering native Copilot sessions from ~/.copilot unless COPILOT_HOME is explicitly set, and using human-readable fallback labels when native session metadata lacks a summary or event history. Remove the built-in agent prompt prefix, improve queued-question handoff prompting so the agent reads the queue file instead of answering about the path itself, and normalize abort messages so users consistently see 'Agent run aborted by /abort.' instead of sanitized path placeholders. Expand regression coverage for config defaults, Copilot discovery, queue-file prompting, and abort-message sanitization. --------- Co-authored-by: Dcha Agent <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Improve session switching, branch recovery, abort handling, and queued message flow
Mix bot-managed and native Codex/Copilot CLI sessions in /switch, import native sessions into bot state, and refine session/provider/branch state handling for smoother cross-device continuation.
Harden branch preparation and fallback behavior by checking real remote branch existence, rolling back failed origin-based prep, and prompting users through branch discrepancy recovery instead of silently switching.
Add stronger runtime handling for busy projects: queue later text messages to disk, process queued question files after the active run, and prompt before continuing queued work when the previous run was aborted.
Tighten agent progress and abort behavior, keep /abort and /current usable while a project is busy, and expand README plus regression tests to cover queueing, switching, branch recovery, and abort flows.