deprecate pathinfo.tmpdir

This commit is contained in:
Mike McLean 2025-05-05 16:02:59 -04:00
parent 67974ae7d8
commit 666d263b65

View file

@ -2456,6 +2456,9 @@ class PathInfo(object):
def tmpdir(self, volume=None):
"""Return a path to a unique directory under work()/tmp/"""
deprecated(
'PathInfo.tmpdir() is deprecated and will be removed in a future version of Koji')
# this function has never really been used in koji
tmp = None
while tmp is None or os.path.exists(tmp):
tmp = self.work(volume) + '/tmp/' + ''.join([random.choice(self.ASCII_CHARS)