Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

tui3: trailing task and done events in turn demote settled assistant answer to raw plain workingProse

Cerrado
#1,565 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
65/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
go
Área
cli, frontend

Línea de trabajo

Read deriveWorkfolds and workEntry in internal/tui3/workfold.go, then trace assistantRows in internal/tui3/render.go, focusing on entryDone and entryTask near turn boundaries. Confirm the fix preserves intermediate rolling summaries while ensuring the terminal assistant entry reaches settledMarkdown and retains markdown rendering when asynchronous events follow it.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

area:chat bug sev:serious
Problem

In the TUI chat surface (internal/tui3), settled final assistant answers frequently fail to convert into rendered markdown answers, staying trapped as unformatted plain text with raw markdown syntax (###, **bold**, backticks) indented as step narration under previous disclosure nodes instead of standing as clean rolling answers.

This is especially prominent in manager and team turns, but also occurs in standard chats whenever background tasks, worker notifications, or tool events land near the turn boundary.

Root Cause Analysis in Code
  1. workEntry in internal/tui3/workfold.go (lines 525–533):
    When classifying whether an assistant entry e is working narration (demoted = true) or a settled answer, workEntry falls through to a forward scan:

    for at := i + 1; at < len(es) && es[at].turn == e.turn; at++ {
        if groupBreaks(&es[at]) {
            return false
        }
        ...
        if es[at].kind != entryDivider && es[at].kind != entryNote && !entryWithdrawn(&es[at]) {
            return true
        }
    }
    

    When background task completions (entryDone, e.g. ✖ ◆ manager permissions · incomplete · 34s) or task status entries (entryTask) append to the current turn after the assistant finishes speaking, workEntry treats them as subsequent non-divider/non-note work and sets es[i].demoted = true.

  2. assistantRows in internal/tui3/render.go (lines 1372–1385):

    if e.demoted {
        e.feet = nil
        text := e.text
        if e.capHead && e.capCut > 0 && e.capCut <= len(text) {
            text = text[e.capCut:]
        }
        return append(tags, a.workingProse(text, width)...)
    }
    if e.settled {
        return append(tags, a.settledMarkdown(at, e, width)...)
    }
    

    Because e.demoted was set to true, the assistant block never enters settledMarkdown. It routes to workingProse, which performs raw plain-text line-wrapping with zero markdown formatting.

  3. Missing workfold certification in deriveWorkfolds (workfold.go:264–316):
    In manager turns or turns where blocked triggers (such as team_send, entrySeam, or asks), no workfold is constructed for the turn (folds map has no entry for the turn). Without a certifying f.answer == i in a workfold, the forward loop in workEntry runs and is tripped by entryDone / entryTask.

Expected Behavior
  • When nothing is clicked in the transcript, intermediate steps collapse into clean rolling summary lines (▸ headline ... duration), and the assistant's terminal answer renders below them through settledMarkdown with full markdown formatting.
  • Asynchronous task completion cards (entryDone), notifications, and background events appended to the turn must not demote the assistant's final response into intermediate working prose.

Drafted with CodeAF

Lenguaje dominante
Go
Estrellas
115
Forks
14
Merge medio
9 h 37 min
PR fusionados (30 d)
755

Preparar el entorno

Aún no hemos revisado los archivos de configuración de este proyecto. Empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de Agent-Field/CodeAF

Todos los issues de Agent-Field/CodeAF

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.