Gentoo Archives: gentoo-commits

From: "Zac Medico (zmedico)" <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] portage r15290 - main/trunk/pym/portage/dbapi
Date: Sat, 30 Jan 2010 14:47:01
Message-Id: E1NbEb5-0002gA-1b@stork.gentoo.org
1 Author: zmedico
2 Date: 2010-01-30 14:46:50 +0000 (Sat, 30 Jan 2010)
3 New Revision: 15290
4
5 Modified:
6 main/trunk/pym/portage/dbapi/porttree.py
7 Log:
8 Don't generate DeprecationWarning for portdbapi arguments. Wait until new
9 portdbapi constructor is in stable portage first.
10
11
12 Modified: main/trunk/pym/portage/dbapi/porttree.py
13 ===================================================================
14 --- main/trunk/pym/portage/dbapi/porttree.py 2010-01-30 14:31:53 UTC (rev 15289)
15 +++ main/trunk/pym/portage/dbapi/porttree.py 2010-01-30 14:46:50 UTC (rev 15290)
16 @@ -143,7 +143,7 @@
17
18 def __init__(self, _unused_param=None, mysettings=None):
19 """
20 - @param _unused_param: deprecated
21 + @param _unused_param: deprecated, use mysettings['PORTDIR'] instead
22 @type _unused_param: None
23 @param mysettings: an immutable config instance
24 @type mysettings: portage.config
25 @@ -157,7 +157,8 @@
26 from portage import settings
27 self.mysettings = config(clone=settings)
28
29 - if _unused_param is not None:
30 + # enable this warning after this parameter is unused in stable portage
31 + if False and _unused_param is not None:
32 warnings.warn("The first parameter of the " + \
33 "portage.dbapi.porttree.portdbapi" + \
34 " constructor is now unused. Use " + \