commit 900753cfed18d8ecb3b6b4b382189fc30426007c
Author: Pierre-Yves Chibon <pingou(a)pingoured.fr>
Date: Wed May 14 18:06:10 2014 +0200
Add the critpath filter to get_packages
pkgdb2client.py | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
---
diff --git a/pkgdb2client.py b/pkgdb2client.py
index 5f90857..8157da0 100644
--- a/pkgdb2client.py
+++ b/pkgdb2client.py
@@ -621,7 +621,8 @@ class PkgDB(object):
def get_packages(
self, pattern='*', branches=None, poc=None, status=None,
- orphaned=False, acls=False, eol=False, page=1, count=False):
+ orphaned=False, critpath=None, acls=False, eol=False,
+ page=1, count=False):
''' Return the list of packages matching the provided criterias.
To get information about what packages a person has acls on, you
@@ -642,6 +643,10 @@ class PkgDB(object):
:type status: str or list or None
:kwarg orphaned: A boolean to returned only orphaned packages
:type orphaned: bool
+ :kwarg critpath: A boolean to returned only packages in the critical
+ path. Can be ``True``, ``False`` or ``None``.
+ Defaults to ``None``.
+ :type critpath: bool
:kwarg acls: A boolean to return the package ACLs in the output.
Beware, this may slow down you call considerably, maybe even
leading to a timeout
@@ -684,6 +689,10 @@ class PkgDB(object):
args['acls'] = acls
if orphaned is True:
args['orphaned'] = orphaned
+ if critpath is True:
+ args['critpath'] = 1
+ elif critpath is False:
+ args['critpath'] = 0
if eol is True:
args['eol'] = eol
Show replies by date