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 8338430 commit 2b2c131Copy full SHA for 2b2c131
sourceplusplus/models/instrument/LiveMeter.py
@@ -24,6 +24,9 @@ def from_json(cls, json_str):
24
for key in json_dict:
25
setattr(meter, key, json_dict[key])
26
meter.location = LiveSourceLocation(json_dict["location"]["source"], json_dict["location"]["line"])
27
- meter.throttle = HitThrottle(json_dict["throttle"]["limit"], ThrottleStep(json_dict["throttle"]["step"]))
+
28
+ if "throttle" in json_dict:
29
+ meter.throttle = HitThrottle(json_dict["throttle"]["limit"], ThrottleStep(json_dict["throttle"]["step"]))
30
31
meter.type = LiveInstrumentType.METER
32
return meter
0 commit comments