From e70f8bd3b206cabecf1bd3c64fa841519dba5242 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 21 Aug 2010 06:38:59 -0700 Subject: [PATCH] Add a deprecation warning for the unused justmanifest parameter of digestcheck(). --- pym/portage/package/ebuild/digestcheck.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/pym/portage/package/ebuild/digestcheck.py b/pym/portage/package/ebuild/digestcheck.py index 6861e3f9d..c2c2beff3 100644 --- a/pym/portage/package/ebuild/digestcheck.py +++ b/pym/portage/package/ebuild/digestcheck.py @@ -3,6 +3,8 @@ __all__ = ['digestcheck'] +import warnings + from portage import os, _encodings, _unicode_decode from portage.exception import DigestException, FileNotFound from portage.localization import _ @@ -10,12 +12,20 @@ from portage.manifest import Manifest from portage.output import EOutput from portage.util import writemsg -def digestcheck(myfiles, mysettings, strict=0, justmanifest=0): +def digestcheck(myfiles, mysettings, strict=False, justmanifest=None): """ Verifies checksums. Assumes all files have been downloaded. @rtype: int @returns: 1 on success and 0 on failure """ + + if justmanifest is not None: + warnings.warn("The justmanifest parameter of the " + \ + "portage.package.ebuild.digestcheck.digestcheck()" + \ + " function is now unused.", + DeprecationWarning, stacklevel=2) + justmanifest = None + if mysettings.get("EBUILD_SKIP_MANIFEST") == "1": return 1 pkgdir = mysettings["O"] -- 2.26.2