MCPcopy Create free account
hub / github.com/CloudPolis/webdav-client-python / clean

Method clean

webdav/client.py:626–644  ·  view source on GitHub ↗
(self, remote_path)

Source from the content-addressed store, hash-verified

624 raise NotConnection(self.webdav.hostname)
625
626 def clean(self, remote_path):
627
628 try:
629 urn = Urn(remote_path)
630
631 url = {'hostname': self.webdav.hostname, 'root': self.webdav.root, 'path': urn.quote()}
632 options = {
633 'URL': "{hostname}{root}{path}".format(**url),
634 'CUSTOMREQUEST': Client.requests['clean'],
635 'HTTPHEADER': self.get_header('clean')
636 }
637
638 request = self.Request(options=options)
639
640 request.perform()
641 request.close()
642
643 except pycurl.error:
644 raise NotConnection(self.webdav.hostname)
645
646 def publish(self, remote_path):
647

Callers 2

upload_directoryMethod · 0.95
cleanMethod · 0.45

Calls 5

quoteMethod · 0.95
get_headerMethod · 0.95
RequestMethod · 0.95
UrnClass · 0.90
NotConnectionClass · 0.85

Tested by

no test coverage detected