Skip to content

Commit

Permalink
httpx performance boost
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions committed Dec 8, 2024
1 parent 3b6d22e commit 319c9c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bbot/modules/httpx.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,9 @@ async def handle_batch(self, *events):
command += ["-http-proxy", proxy]
async for line in self.run_process_live(command, text=False, input=list(stdin), stderr=subprocess.DEVNULL):
try:
j = orjson.loads(line)
j = await self.helpers.run_in_executor(orjson.loads, line)
except orjson.JSONDecodeError:
self.debug(f"Failed to decode line: {line}")
self.warning(f"httpx failed to decode line: {line}")
continue

url = j.get("url", "")
Expand Down

0 comments on commit 319c9c3

Please sign in to comment.