MCPcopy
hub / github.com/pyload/pyload / checkOnlineStatusContainer

Method checkOnlineStatusContainer

module/Api.py:398–410  ·  view source on GitHub ↗

checks online status of urls and a submited container file :param urls: list of urls :param container: container file name :param data: file content :return: online check

(self, urls, container, data)

Source from the content-addressed store, hash-verified

396
397 @permission(PERMS.ADD)
398 def checkOnlineStatusContainer(self, urls, container, data):
399 """ checks online status of urls and a submited container file
400
401 :param urls: list of urls
402 :param container: container file name
403 :param data: file content
404 :return: online check
405 """
406 th = open(join(self.core.config["general"]["download_folder"], "tmp_" + container), "wb")
407 th.write(str(data))
408 th.close()
409
410 return self.checkOnlineStatus(urls + [th.name])
411
412 @permission(PERMS.ADD)
413 def pollResults(self, rid):

Callers 1

processCommandMethod · 0.45

Calls 3

checkOnlineStatusMethod · 0.95
writeMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected