We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c8a786 commit c18384cCopy full SHA for c18384c
ooniapi/services/ooniprobe/src/ooniprobe/routers/v1/probe_services.py
@@ -606,7 +606,6 @@ def list_tor_targets(
606
settings: Settings = Depends(get_settings),
607
) -> Dict[str, TorTarget]:
608
609
- tor_dir = settings.tor_targets
610
token = request.headers.get("Authorization")
611
if token == None:
612
# XXX not actually validated
@@ -617,4 +616,6 @@ def list_tor_targets(
617
616
return resp
618
except ujson.JSONDecodeError:
619
log.info("tor-targets: failed to parse json")
620
- raise HTTPException(status_code=401, detail="Invalid tor-targets")
+ except FileNotFoundError
+ log.info("tor-targets: failed to open json")
621
+ raise HTTPException(status_code=401, detail="Invalid tor-targets")
0 commit comments