Skip to content

fix(email): specification.html has drifted from its generator — regeneration would drop hand-edited sections #2080

Description

@itomek

Problem

The email agent's committed hub/agents/python/email/specification.html carries hand-edited sections (e.g. the #1892 context-window envelope block, the #1889 thread-handling sentence) that its generator hub/agents/python/email/gaia_agent_email/spec_html.py does not produce — a fresh render_endpoint_spec_html() run would silently DROP those sections. Recent PRs matched the established practice of editing both files in parallel, but the generator and the committed artifact have structurally drifted: regeneration is no longer safe.

Outcome

spec_html.py regenerates the committed specification.html faithfully (hand-maintained sections become generator-emitted), or the file is explicitly split into a generated part and a hand-maintained part with a drift guard, so regeneration cannot silently lose documentation.

Acceptance criteria

Scope & expectations

  • Where: hub/agents/python/email/gaia_agent_email/spec_html.py, hub/agents/python/email/specification.html, tests in hub/agents/python/email/tests/
  • Out of scope: content changes to the spec; openapi.email.json (already generator-guarded)
  • Constraints: keep the rendered page's structure/anchors stable (external links may target section ids)

How to verify

Test run output showing the new drift guard passing on the synced pair and failing when either side is edited alone.

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent::emailEmail agent changesbugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions