Fix bad function calls
RefineProject.apply_operations and RefineProject.wait_until_idle called RefineProject.do when they are supposed to call RefineProject.do_json.
This commit is contained in:
parent
f3354f6fc1
commit
bd8d9e2727
|
@ -285,7 +285,7 @@ class RefineProject:
|
|||
|
||||
def wait_until_idle(self, polling_delay=0.5):
|
||||
while True:
|
||||
response = self.do('get-processes')
|
||||
response = self.do_json('get-processes')
|
||||
if 'processes' in response and len(response['processes']) > 0:
|
||||
time.sleep(polling_delay)
|
||||
else:
|
||||
|
@ -293,7 +293,7 @@ class RefineProject:
|
|||
|
||||
def apply_operations(self, file_path, wait=True):
|
||||
json = open(file_path).read()
|
||||
response_json = self.do('apply-operations', {'operations': json})
|
||||
response_json = self.do_json('apply-operations', {'operations': json})
|
||||
if response_json['code'] == 'pending' and wait:
|
||||
self.wait_until_idle()
|
||||
return 'ok'
|
||||
|
|
Loading…
Reference in New Issue