From 20213be7232fd858130f8b4b468be6ac2b532741 Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Sat, 11 Apr 2020 00:39:03 -0700 Subject: Fix a bug in que --serve --- Run/Que/client.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'Run/Que/client.py') diff --git a/Run/Que/client.py b/Run/Que/client.py index ed128b8..e272d6a 100755 --- a/Run/Que/client.py +++ b/Run/Que/client.py @@ -35,11 +35,10 @@ def send(args): req.add_header("Authorization", key) if args.serve: while not time.sleep(1): - with request.urlopen(req, data=data, timeout=MAX_TIMEOUT) as req: - pass + request.urlopen(req, data=data, timeout=MAX_TIMEOUT) + else: - with request.urlopen(req, data=data, timeout=MAX_TIMEOUT) as req: - pass + request.urlopen(req, data=data, timeout=MAX_TIMEOUT) def recv(args): -- cgit v1.2.3