Skip to content

Commit 42615e5

Browse files
committed
fix(build):
1 parent e6459a5 commit 42615e5

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

agentic_security/probe_data/image_generator.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import httpx
66
import matplotlib
77

8-
matplotlib.use("Agg")
98
import matplotlib.pyplot as plt # noqa: E402
109
from cache_to_disk import cache_to_disk
1110
from tqdm import tqdm
@@ -56,7 +55,7 @@ def generate_image(prompt: str, variant: int = 0) -> bytes:
5655
# Sanitize prompt: replace non-renderable whitespace characters (tabs, etc.)
5756
# with spaces to avoid matplotlib UserWarning about missing glyphs.
5857
prompt = re.sub(r"[\t\r\x0b\x0c]", " ", prompt)
59-
58+
matplotlib.use("Agg")
6059
# Create a matplotlib figure
6160
fig, ax = plt.subplots(figsize=(6, 4))
6261

0 commit comments

Comments
 (0)