mirror of
https://github.com/msoedov/agentic_security.git
synced 2026-11-25 19:43:29 +01:00
Merge pull request #357 from msoedov/perf/harness-lazy-httpx
perf(harness): lazy import httpx
This commit is contained in:
3 files changed
+5
-5
No files matched your search
@@ -9,7 +9,7 @@ repos:
|
||||
args: [--py314-plus]
|
||||
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 26.3.1
|
||||
rev: 26.10.1
|
||||
hooks:
|
||||
- id: black
|
||||
language_version: python3.15
|
||||
|
||||
@@ -9,6 +9,8 @@ from agentic_security_harness.deciders import Decision
|
||||
from agentic_security_harness.loop import Harness, replay
|
||||
from agentic_security_harness.runlog import ROOT, RunLog
|
||||
|
||||
lazy import fire
|
||||
|
||||
|
||||
def output(data):
|
||||
print(json.dumps(data, ensure_ascii=True, allow_nan=False), flush=True)
|
||||
@@ -70,8 +72,6 @@ class CLI:
|
||||
|
||||
|
||||
def main():
|
||||
import fire
|
||||
|
||||
try:
|
||||
fire.Fire(CLI())
|
||||
except (Exception, KeyboardInterrupt) as exc:
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
|
||||
import json
|
||||
import os
|
||||
|
||||
import httpx
|
||||
from dataclasses import dataclass
|
||||
|
||||
from agentic_security_harness.policy import Action
|
||||
|
||||
lazy import httpx
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class Decision:
|
||||
|
||||
Reference in new issue
Block a user