mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-26 01:12:21 +00:00
Address two related concerns raised in PR review on the reconsider flow: 1. **Dry-run support for --reconsider** (P1, greptile-apps): The previous --reconsider branch unconditionally called post_comment + reopen_* regardless of --close. The docstring claimed 'close is forced True implicitly', but the workflow's only kill switch was AGENT_SHIN_ENABLED — invoking the script directly without --close was still destructive, the opposite of the conventional dry-run expectation. triage() now honors close=False in reconsider mode: a passing verdict returns action='would-reopen' (with the comment body it WOULD post in result['comment']) and a failing verdict returns action='would-leave-closed-still-failing'. The reconsider workflow now appends --close iff AGENT_SHIN_ENABLED == 'true', mirroring the pattern used by close_low_quality_prs.yml. 2. **Provenance gate for reopen** (P2, both greptile-apps and veria-ai): The reconsider flow could be used to silently override a maintainer's close decision — an external author edits the closed PR to include a closing keyword, comments '@agent-shin reconsider', and the bot reopens it. There was no check that Agent Shin was the actor that originally closed it. triage() now requires was_auto_closed_by_agent_shin() to be true before any reopen path can fire. The check looks for a bot-authored comment (login ends with '[bot]') containing the auto-close marker 'I'm **Agent Shin**'. Filtering by bot author makes the marker unspoofable: a contributor pasting the phrase into a manual comment cannot satisfy the check. When the provenance gate fails, triage returns action='skip-not-bot-closed' without burning LLM tokens or posting anything. Unit tests cover both behaviors plus the failure modes of was_auto_closed_by_agent_shin (no comments, non-bot author with marker, bot comment without marker, marker found anywhere in the comment list). Co-authored-by: Mateo Wang <mateo-berri@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| agent_tests | ||
| audio_tests | ||
| basic_proxy_startup_tests | ||
| batches_tests | ||
| benchmarks | ||
| code_coverage_tests | ||
| documentation_tests | ||
| enterprise | ||
| guardrails_tests | ||
| image_gen_tests | ||
| litellm | ||
| litellm-proxy-extras | ||
| litellm_core_utils | ||
| litellm_utils_tests | ||
| llm_responses_api_testing | ||
| llm_translation | ||
| load_tests | ||
| local_testing | ||
| logging_callback_tests | ||
| mcp_tests | ||
| multi_instance_e2e_tests | ||
| ocr_tests | ||
| old_proxy_tests/tests | ||
| openai_endpoints_tests | ||
| otel_tests | ||
| pass_through_tests | ||
| pass_through_unit_tests | ||
| proxy_admin_ui_tests | ||
| proxy_e2e_anthropic_messages_tests | ||
| proxy_security_tests | ||
| proxy_unit_tests | ||
| router_unit_tests | ||
| scim_tests | ||
| search_tests | ||
| spend_tracking_tests | ||
| store_model_in_db_tests | ||
| test_litellm | ||
| unified_google_tests | ||
| vector_store_tests | ||
| windows_tests | ||
| __init__.py | ||
| _flush_vcr_cache.py | ||
| _vcr_conftest_common.py | ||
| _vcr_redis_persister.py | ||
| eval_swe_bench.py | ||
| gettysburg.wav | ||
| large_text.py | ||
| openai_batch_completions.jsonl | ||
| README.MD | ||
| test_budget_management.py | ||
| test_callbacks_on_proxy.py | ||
| test_config.py | ||
| test_debug_warning.py | ||
| test_default_encoding_non_root.py | ||
| test_end_users.py | ||
| test_entrypoint.py | ||
| test_fallbacks.py | ||
| test_gpt5_azure_temperature_support.py | ||
| test_health.py | ||
| test_keys.py | ||
| test_litellm_proxy_responses_config.py | ||
| test_logging.conf | ||
| test_models.py | ||
| test_new_vector_store_endpoints.py | ||
| test_openai_endpoints.py | ||
| test_organizations.py | ||
| test_otel_thread_leak.py | ||
| test_passthrough_endpoints.py | ||
| test_presidio_latency.py | ||
| test_proxy_server_non_root.py | ||
| test_ratelimit.py | ||
| test_resource_cleanup.py | ||
| test_service_logger_otel.py | ||
| test_spend_logs.py | ||
| test_team.py | ||
| test_team_logging.py | ||
| test_team_members.py | ||
| test_users.py | ||
In total litellm runs 1000+ tests
[02/20/2025] Update:
To make it easier to contribute and map what behavior is tested,
we've started mapping the litellm directory in tests/test_litellm
This folder can only run mock tests.