Wednesday, October 19, 2011

How to clear SUDS cache

At suds/cache.py we can follow the way how is the cache path is generated.
    if location is None:
            location = os.path.join(tmp(), 'suds')
        log.debug("cache dir is %s" % location)
        self.location = location
Here is the code that wipes all chache data in default place.
import os
import shutil
from tempfile import gettempdir as tmp
shutil.rmtree(os.path.join(tmp(), 'suds'), True)

No comments:

Post a Comment