diff --git a/cognee/tests/integration/cli/test_cli_integration.py b/cognee/tests/integration/cli/test_cli_integration.py index af7f7983a..e979b0013 100644 --- a/cognee/tests/integration/cli/test_cli_integration.py +++ b/cognee/tests/integration/cli/test_cli_integration.py @@ -83,9 +83,16 @@ class TestCliIntegration: # Note: This might fail due to dependencies, but we're testing the CLI structure # The important thing is that it doesn't crash with argument parsing errors + # Allow litellm logging worker cancellation errors as they're expected during process shutdown + stderr_lower = result.stderr.lower() + has_error = "error" in stderr_lower + has_expected_failure = "failed to add data" in stderr_lower + has_litellm_cancellation = "loggingworker cancelled" in stderr_lower or "cancellederror" in stderr_lower + assert ( - "error" not in result.stderr.lower() - or "failed to add data" in result.stderr.lower() + not has_error + or has_expected_failure + or has_litellm_cancellation ) finally: