summaryrefslogtreecommitdiff
path: root/wrappers/python
diff options
context:
space:
mode:
authorjwijenbergh <jeroenwijenbergh@protonmail.com>2022-07-12 09:23:08 +0200
committerjwijenbergh <jeroenwijenbergh@protonmail.com>2022-07-12 09:23:08 +0200
commitfc345f1623d83d3c2e9acb8b3c9139656b2797d1 (patch)
treef519604015e9d90b6c032025a2307aa7fd758aad /wrappers/python
parent71d24f33639a7ad7a76061115f13e781424c845a (diff)
Exports + Python: Fix config JSON parsing
Diffstat (limited to 'wrappers/python')
-rw-r--r--wrappers/python/src/main.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/wrappers/python/src/main.py b/wrappers/python/src/main.py
index 6f4b140..4868fca 100644
--- a/wrappers/python/src/main.py
+++ b/wrappers/python/src/main.py
@@ -2,6 +2,7 @@ from . import lib, VPNStateChange, encode_args, decode_res
from typing import Optional, Tuple
import threading
from .event import StateType, EventHandler
+import json
eduvpn_objects = {}
@@ -110,8 +111,10 @@ class EduVPN(object):
if config_err:
raise Exception(config_err)
- config = config_json["config"]
- config_type = config_json["config_type"]
+
+ config_json_dict = json.loads(config_json)
+ config = config_json_dict["config"]
+ config_type = config_json_dict["config_type"]
return config, config_type