MCPcopy
hub / github.com/aptly-dev/aptly / put_task

Method put_task

system/api_lib.py:118–128  ·  view source on GitHub ↗
(self, uri, *args, **kwargs)

Source from the content-addressed store, hash-verified

116 return requests.put("http://%s%s" % (self.base_url, uri), *args, **kwargs)
117
118 def put_task(self, uri, *args, **kwargs):
119 self._ensure_async(kwargs)
120 resp = self.put(uri, *args, **kwargs)
121 if resp.status_code != 202:
122 return resp
123
124 _id = resp.json()['ID']
125 resp = self.get("/api/tasks/" + str(_id) + "/wait")
126 self.check_equal(resp.status_code, 200)
127
128 return self.get("/api/tasks/" + str(_id))
129
130 def delete(self, uri, *args, **kwargs):
131 if "json" in kwargs:

Callers 14

checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
_do_updateMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80
checkMethod · 0.80

Calls 4

_ensure_asyncMethod · 0.95
putMethod · 0.95
getMethod · 0.95
check_equalMethod · 0.80

Tested by

no test coverage detected