Skip to content
Snippets Groups Projects
Commit 468e3b7b authored by Chris Hines's avatar Chris Hines
Browse files

make sure nvidia-probe always outputs valid json, even if nothing is present

Former-commit-id: c3e16696
parent 675e5ba3
No related branches found
No related tags found
No related merge requests found
......@@ -55,5 +55,7 @@ try:
output=json.dumps(deviceList)
print output
except OSError:
output=json.dumps([])
print output
#if nvidia-smi is not installed on computer then this error is thrown by subprocess.Popen
sys.exit(0)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment