From 6769c8b66fe5b9d280c590a882133bcdd20af844 Mon Sep 17 00:00:00 2001 From: user <70670632+stuxf@users.noreply.github.com> Date: Tue, 5 May 2026 20:45:08 +0000 Subject: [PATCH] [Fix] CI: license check for black 26.3.1 + skip disk_cache test without diskcache - Add black to liccheck.ini Authorized Packages (MIT-licensed). - pytest.importorskip("diskcache") at top of test_disk_cache.py so the test skips cleanly when diskcache isn't installed (it's no longer pulled in by the dev group after the CVE-2025-69872 mitigation). Co-Authored-By: Claude Opus 4.7 (1M context) --- tests/code_coverage_tests/liccheck.ini | 1 + tests/test_litellm/caching/test_disk_cache.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/tests/code_coverage_tests/liccheck.ini b/tests/code_coverage_tests/liccheck.ini index 2100aa1377f..23e31f8886b 100644 --- a/tests/code_coverage_tests/liccheck.ini +++ b/tests/code_coverage_tests/liccheck.ini @@ -171,3 +171,4 @@ langgraph: >=1.0.10 # MIT License langgraph-prebuilt: >=1.0.8 # MIT License - https://github.com/langchain-ai/langgraph/blob/main/LICENSE pytest-rerunfailures: >=15.1 # MPL 2.0 license pytest-recording: >=0.13.4 # MIT license +black: >=24.10.0 # MIT License - https://github.com/psf/black/blob/main/LICENSE diff --git a/tests/test_litellm/caching/test_disk_cache.py b/tests/test_litellm/caching/test_disk_cache.py index d2b6fef5385..470e2064c38 100644 --- a/tests/test_litellm/caching/test_disk_cache.py +++ b/tests/test_litellm/caching/test_disk_cache.py @@ -4,6 +4,8 @@ import tempfile import pytest +pytest.importorskip("diskcache") + sys.path.insert(0, os.path.abspath("../../..")) from litellm.caching.disk_cache import DiskCache