Skip to content

Flaky test: test_cli_clear_resets_conversation_chain #270

Open

Description

@evansenter

test_cli_clear_resets_conversation_chain is flaky because it depends on LLM behavior.

Observed Failure

The test tells the model a "secret code", clears the conversation, then asks for it back. The model sometimes fails to recall it, causing the test to fail.

I'm sorry, but I don't have access to any secret codes from our previous interactions or in my current environment.

Root Cause

LLM-dependent tests are inherently non-deterministic. The model may:

  • Not store the information as expected
  • Not recall it reliably after context clear
  • Respond differently based on temperature/sampling

Options

  1. Remove the test - LLM behavior is outside our control
  2. Make it more resilient - Retry logic, or check for partial matches
  3. Mark as #[ignore] - Skip in regular CI, run manually
  4. Use mock responses - Replace LLM call with deterministic mock for this test

Evidence

Failed in CI on PR #269 (unrelated glob test fix), passed on re-run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions