Merge lp:~jml/launchpad/interface-apocalypse into lp:launchpad
- interface-apocalypse
- Merge into devel
Proposed by
Jonathan Lange
Status: | Rejected |
---|---|
Rejected by: | Jonathan Lange |
Proposed branch: | lp:~jml/launchpad/interface-apocalypse |
Merge into: | lp:launchpad |
Diff against target: |
2072 lines (+283/-566) 90 files modified
cronscripts/create-debwatches.py (+1/-1) cronscripts/distributionmirror-prober.py (+5/-2) cronscripts/flag-expired-memberships.py (+5/-3) cronscripts/foaf-update-karma-cache.py (+1/-1) cronscripts/parse-ppa-apache-access-logs.py (+1/-3) cronscripts/process-mail.py (+1/-1) cronscripts/send-bug-notifications.py (+1/-1) cronscripts/update-debwatches.py (+12/-3) cronscripts/update-pkgcache.py (+1/-2) cronscripts/update-stats.py (+5/-3) database/schema/pending/add-mailing-list-experts.py (+5/-2) database/schema/pending/create-openid-rp-configs.py (+0/-51) database/schema/pending/import_language_packs.py (+0/-69) database/schema/pending/update-shippingrequest-types.py (+0/-51) lib/canonical/database/harness.py (+0/-1) lib/canonical/database/sqlbase.py (+3/-3) lib/canonical/launchpad/browser/feeds.py (+16/-12) lib/canonical/launchpad/browser/launchpadstatistic.py (+3/-1) lib/canonical/launchpad/browser/librarian.py (+1/-1) lib/canonical/launchpad/browser/packagerelationship.py (+1/-1) lib/canonical/launchpad/components/cdatetime.py (+1/-1) lib/canonical/launchpad/components/tokens.py (+1/-1) lib/canonical/launchpad/database/account.py (+1/-2) lib/canonical/launchpad/database/emailaddress.py (+1/-1) lib/canonical/launchpad/database/launchpadstatistic.py (+3/-3) lib/canonical/launchpad/database/librarian.py (+2/-2) lib/canonical/launchpad/database/logintoken.py (+5/-5) lib/canonical/launchpad/database/message.py (+7/-5) lib/canonical/launchpad/database/oauth.py (+1/-1) lib/canonical/launchpad/database/temporaryblobstorage.py (+2/-2) lib/canonical/launchpad/doc/security.txt (+1/-1) lib/canonical/launchpad/doc/validation.txt (+1/-1) lib/canonical/launchpad/doc/xmlrpc-selftest.txt (+1/-1) lib/canonical/launchpad/helpers.py (+1/-1) lib/canonical/launchpad/interfaces/__init__.py (+12/-146) lib/canonical/launchpad/interfaces/ftests/validation.txt (+2/-1) lib/canonical/launchpad/interfaces/validation.py (+4/-4) lib/canonical/launchpad/mail/commands.py (+24/-18) lib/canonical/launchpad/mail/handlers.py (+13/-11) lib/canonical/launchpad/mail/helpers.py (+2/-2) lib/canonical/launchpad/mail/meta.py (+1/-1) lib/canonical/launchpad/mailnotification.py (+10/-8) lib/canonical/launchpad/pagetitles.py (+2/-4) lib/canonical/launchpad/rest/me.py (+1/-1) lib/canonical/launchpad/rest/pillarset.py (+1/-1) lib/canonical/launchpad/subscribers/karma.py (+1/-1) lib/canonical/launchpad/systemhomes.py (+20/-14) lib/canonical/launchpad/testing/fakepackager.py (+2/-4) lib/canonical/launchpad/testing/pages.py (+3/-3) lib/canonical/launchpad/testing/systemdocs.py (+1/-1) lib/canonical/launchpad/utilities/celebrities.py (+7/-9) lib/canonical/launchpad/utilities/personroles.py (+1/-1) lib/canonical/launchpad/webapp/adapter.py (+1/-1) lib/canonical/launchpad/webapp/dbpolicy.py (+1/-2) lib/canonical/launchpad/webapp/launchbag.py (+12/-14) lib/canonical/launchpad/xmlrpc/__init__.py (+0/-6) lib/canonical/launchpad/xmlrpc/application.py (+3/-3) lib/canonical/launchpad/xmlrpc/authserver.py (+2/-4) lib/canonical/launchpad/xmlrpc/configure.zcml (+4/-4) lib/canonical/launchpad/zcml/launchpad.zcml (+4/-4) lib/canonical/lazr/feed/feed.py (+1/-1) lib/canonical/testing/layers.py (+2/-1) lib/canonical/widgets/announcementdate.py (+1/-1) lib/canonical/widgets/branch.py (+1/-1) lib/canonical/widgets/bugtask.py (+7/-3) lib/canonical/widgets/date.py (+1/-1) lib/canonical/widgets/launchpadtarget.py (+6/-3) lib/canonical/widgets/owner.py (+1/-1) lib/canonical/widgets/password.py (+1/-1) lib/canonical/widgets/product.py (+3/-2) lib/lp/bugs/configure.zcml (+1/-1) lib/lp/bugs/interfaces/__init__.py (+0/-5) lib/lp/bugs/tests/bugzilla-xmlrpc-transport.txt (+1/-1) lib/lp/bugs/tests/externalbugtracker.py (+1/-1) lib/lp/code/configure.zcml (+4/-4) lib/lp/registry/interfaces/commercialsubscription.py (+1/-6) lib/lp/registry/interfaces/product.py (+2/-0) lib/lp/services/features/browser/configure.zcml (+1/-1) scripts/bug-export.py (+1/-1) scripts/bug-import.py (+1/-1) scripts/cache-country-mirrors.py (+3/-2) scripts/close-account.py (+3/-3) scripts/convert-person-to-team.py (+2/-1) scripts/ftpmaster-tools/initialise-from-parent.py (+1/-1) scripts/ftpmaster-tools/remove-package.py (+1/-1) scripts/ftpmaster-tools/sync-source.py (+2/-4) scripts/migrate-bugzilla-initialcontacts.py (+3/-3) scripts/mlist-sync.py (+3/-2) scripts/rosetta/check-distroseries-translations-diffs.py (+1/-1) utilities/make-lp-user (+3/-5) |
To merge this branch: | bzr merge lp:~jml/launchpad/interface-apocalypse |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Jonathan Lange (community) | Approve | ||
Review via email: mp+40323@code.launchpad.net |
Commit message
No more direct imports from c.l.interfaces; no more re-exports from c.l.interfaces.
Description of the change
No more direct imports from canonical.
To post a comment you must log in.
Revision history for this message
Jonathan Lange (jml) : | # |
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'cronscripts/create-debwatches.py' |
2 | --- cronscripts/create-debwatches.py 2010-10-03 15:30:06 +0000 |
3 | +++ cronscripts/create-debwatches.py 2010-11-08 14:57:15 +0000 |
4 | @@ -22,7 +22,7 @@ |
5 | from lp.services.scripts.base import ( |
6 | LaunchpadCronScript, LaunchpadScriptFailure) |
7 | from canonical.launchpad.scripts.debsync import do_import |
8 | -from canonical.launchpad.interfaces import ILaunchpadCelebrities |
9 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
10 | |
11 | |
12 | # setup core values and defaults |
13 | |
14 | === modified file 'cronscripts/distributionmirror-prober.py' |
15 | --- cronscripts/distributionmirror-prober.py 2010-10-03 15:30:06 +0000 |
16 | +++ cronscripts/distributionmirror-prober.py 2010-11-08 14:57:15 +0000 |
17 | @@ -20,8 +20,11 @@ |
18 | from canonical.database.sqlbase import ISOLATION_LEVEL_AUTOCOMMIT |
19 | from lp.services.scripts.base import ( |
20 | LaunchpadCronScript, LaunchpadScriptFailure) |
21 | -from canonical.launchpad.interfaces import ( |
22 | - IDistributionMirrorSet, ILibraryFileAliasSet, MirrorContent) |
23 | +from lp.registry.interfaces.distributionmirror import ( |
24 | + IDistributionMirrorSet, |
25 | + MirrorContent, |
26 | + ) |
27 | +from canonical.launchpad.interfaces.librarian import ILibraryFileAliasSet |
28 | from canonical.launchpad.webapp import canonical_url |
29 | from lp.registry.scripts.distributionmirror_prober import ( |
30 | get_expected_cdimage_paths, probe_archive_mirror, probe_cdimage_mirror) |
31 | |
32 | === modified file 'cronscripts/flag-expired-memberships.py' |
33 | --- cronscripts/flag-expired-memberships.py 2010-10-03 15:30:06 +0000 |
34 | +++ cronscripts/flag-expired-memberships.py 2010-11-08 14:57:15 +0000 |
35 | @@ -15,9 +15,11 @@ |
36 | from zope.component import getUtility |
37 | |
38 | from canonical.config import config |
39 | -from canonical.launchpad.interfaces import ( |
40 | - DAYS_BEFORE_EXPIRATION_WARNING_IS_SENT, ILaunchpadCelebrities, |
41 | - ITeamMembershipSet) |
42 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
43 | +from lp.registry.interfaces.teammembership import ( |
44 | + DAYS_BEFORE_EXPIRATION_WARNING_IS_SENT, |
45 | + ITeamMembershipSet, |
46 | + ) |
47 | from lp.services.scripts.base import ( |
48 | LaunchpadCronScript, LaunchpadScriptFailure) |
49 | |
50 | |
51 | === modified file 'cronscripts/foaf-update-karma-cache.py' |
52 | --- cronscripts/foaf-update-karma-cache.py 2010-10-03 15:30:06 +0000 |
53 | +++ cronscripts/foaf-update-karma-cache.py 2010-11-08 14:57:15 +0000 |
54 | @@ -12,8 +12,8 @@ |
55 | from canonical.config import config |
56 | from canonical.database.sqlbase import ( |
57 | ISOLATION_LEVEL_AUTOCOMMIT, flush_database_updates) |
58 | -from canonical.launchpad.interfaces import IKarmaCacheManager |
59 | from lp.app.errors import NotFoundError |
60 | +from lp.registry.interfaces.karma import IKarmaCacheManager |
61 | from lp.services.scripts.base import LaunchpadCronScript |
62 | |
63 | |
64 | |
65 | === modified file 'cronscripts/parse-ppa-apache-access-logs.py' |
66 | --- cronscripts/parse-ppa-apache-access-logs.py 2010-06-10 05:22:58 +0000 |
67 | +++ cronscripts/parse-ppa-apache-access-logs.py 2010-11-08 14:57:15 +0000 |
68 | @@ -14,9 +14,7 @@ |
69 | from zope.component import getUtility |
70 | |
71 | from canonical.config import config |
72 | -# XXX: wgrant 2010-03-16 bug=539496: Importing directly from |
73 | -# lp.registry.interfaces.person results in a circular import. |
74 | -from canonical.launchpad.interfaces import IPersonSet |
75 | +from lp.registry.interfaces.person import IPersonSet |
76 | from lp.soyuz.interfaces.archive import NoSuchPPA |
77 | from lp.soyuz.scripts.ppa_apache_log_parser import DBUSER, get_ppa_file_key |
78 | from lp.services.apachelogparser.script import ParseApacheLogs |
79 | |
80 | === modified file 'cronscripts/process-mail.py' |
81 | --- cronscripts/process-mail.py 2010-10-11 18:29:14 +0000 |
82 | +++ cronscripts/process-mail.py 2010-11-08 14:57:15 +0000 |
83 | @@ -14,7 +14,7 @@ |
84 | from lp.services.scripts.base import ( |
85 | LaunchpadCronScript, LaunchpadScriptFailure) |
86 | from lp.services.mail.incoming import handleMail |
87 | -from canonical.launchpad.interfaces import IMailBox |
88 | +from canonical.launchpad.interfaces.mailbox import IMailBox |
89 | |
90 | |
91 | class ProcessMail(LaunchpadCronScript): |
92 | |
93 | === modified file 'cronscripts/send-bug-notifications.py' |
94 | --- cronscripts/send-bug-notifications.py 2010-10-03 15:30:06 +0000 |
95 | +++ cronscripts/send-bug-notifications.py 2010-11-08 14:57:15 +0000 |
96 | @@ -19,8 +19,8 @@ |
97 | |
98 | from canonical.config import config |
99 | from canonical.database.constants import UTC_NOW |
100 | -from canonical.launchpad.interfaces import IBugNotificationSet |
101 | from canonical.launchpad.mail import sendmail |
102 | +from lp.bugs.interfaces.bugnotification import IBugNotificationSet |
103 | from lp.bugs.scripts.bugnotification import get_email_notifications |
104 | from lp.services.scripts.base import LaunchpadCronScript |
105 | |
106 | |
107 | === modified file 'cronscripts/update-debwatches.py' |
108 | --- cronscripts/update-debwatches.py 2010-10-03 15:30:06 +0000 |
109 | +++ cronscripts/update-debwatches.py 2010-11-08 14:57:15 +0000 |
110 | @@ -15,12 +15,21 @@ |
111 | # zope bits |
112 | from zope.component import getUtility |
113 | |
114 | +from lp.bugs.interfaces.bug import IBugSet |
115 | +from lp.bugs.interfaces.bugtask import ( |
116 | + BugTaskSearchParams, |
117 | + IBugTaskSet, |
118 | + ) |
119 | +from lp.bugs.interfaces.bugwatch import IBugWatchSet |
120 | +from lp.bugs.interfaces.cve import ICveSet |
121 | from lp.bugs.scripts import debbugs |
122 | from lp.services.scripts.base import (LaunchpadCronScript, |
123 | LaunchpadScriptFailure) |
124 | -from canonical.launchpad.interfaces import (IBugSet, |
125 | - ILaunchpadCelebrities, InvalidEmailMessage, IBugTaskSet, |
126 | - IBugWatchSet, IMessageSet, ICveSet, BugTaskSearchParams) |
127 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
128 | +from canonical.launchpad.interfaces.message import ( |
129 | + InvalidEmailMessage, |
130 | + IMessageSet, |
131 | + ) |
132 | from canonical.database.constants import UTC_NOW |
133 | |
134 | # setup core values and defaults |
135 | |
136 | === modified file 'cronscripts/update-pkgcache.py' |
137 | --- cronscripts/update-pkgcache.py 2010-10-03 15:30:06 +0000 |
138 | +++ cronscripts/update-pkgcache.py 2010-11-08 14:57:15 +0000 |
139 | @@ -13,8 +13,7 @@ |
140 | |
141 | from zope.component import getUtility |
142 | |
143 | -from canonical.config import config |
144 | -from canonical.launchpad.interfaces import IDistributionSet |
145 | +from lp.registry.interfaces.distribution import IDistributionSet |
146 | from lp.services.scripts.base import LaunchpadCronScript |
147 | |
148 | |
149 | |
150 | === modified file 'cronscripts/update-stats.py' |
151 | --- cronscripts/update-stats.py 2010-10-03 15:30:06 +0000 |
152 | +++ cronscripts/update-stats.py 2010-11-08 14:57:15 +0000 |
153 | @@ -11,10 +11,12 @@ |
154 | |
155 | from zope.component import getUtility |
156 | from canonical.database.sqlbase import ISOLATION_LEVEL_READ_COMMITTED |
157 | +from canonical.launchpad.interfaces.launchpadstatistic import ( |
158 | + ILaunchpadStatisticSet, |
159 | + ) |
160 | from lp.services.scripts.base import LaunchpadCronScript |
161 | -from canonical.launchpad.interfaces import ( |
162 | - IDistributionSet, ILaunchpadStatisticSet, IPersonSet |
163 | - ) |
164 | +from lp.registry.interfaces.distribution import IDistributionSet |
165 | +from lp.registry.interfaces.person import IPersonSet |
166 | from canonical.config import config |
167 | |
168 | |
169 | |
170 | === modified file 'database/schema/pending/add-mailing-list-experts.py' |
171 | --- database/schema/pending/add-mailing-list-experts.py 2010-10-03 15:30:06 +0000 |
172 | +++ database/schema/pending/add-mailing-list-experts.py 2010-11-08 14:57:15 +0000 |
173 | @@ -9,10 +9,13 @@ |
174 | |
175 | from zope.component import getUtility |
176 | |
177 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
178 | from canonical.launchpad.scripts import execute_zcml_for_scripts |
179 | from canonical.lp import initZopeless |
180 | -from canonical.launchpad.interfaces import ( |
181 | - ILaunchpadCelebrities, IPersonSet, TeamSubscriptionPolicy) |
182 | +from lp.registry.interfaces.person import ( |
183 | + IPersonSet, |
184 | + TeamSubscriptionPolicy, |
185 | + ) |
186 | |
187 | |
188 | execute_zcml_for_scripts() |
189 | |
190 | === removed file 'database/schema/pending/create-openid-rp-configs.py' |
191 | --- database/schema/pending/create-openid-rp-configs.py 2010-10-03 15:30:06 +0000 |
192 | +++ database/schema/pending/create-openid-rp-configs.py 1970-01-01 00:00:00 +0000 |
193 | @@ -1,51 +0,0 @@ |
194 | -#!/usr/bin/python -S |
195 | -# |
196 | -# Copyright 2009 Canonical Ltd. This software is licensed under the |
197 | -# GNU Affero General Public License version 3 (see the file LICENSE). |
198 | - |
199 | -# A script to create OpenIDRPConfigs for trust roots we care about. |
200 | -# This is essentially porting the values from the KNOWN_TRUST_ROOTS |
201 | -# dict that we care about. |
202 | - |
203 | -import _pythonpath |
204 | - |
205 | -import os |
206 | - |
207 | -from zope.component import getUtility |
208 | - |
209 | -from canonical.config import config |
210 | -from canonical.launchpad.interfaces import ( |
211 | - ILibraryFileAliasSet, IOpenIDRPConfigSet) |
212 | -from canonical.launchpad.scripts import execute_zcml_for_scripts |
213 | -from canonical.lp import initZopeless |
214 | -from canonical.launchpad.interfaces import PersonCreationRationale as PCR |
215 | - |
216 | -execute_zcml_for_scripts() |
217 | -ztm = initZopeless() |
218 | - |
219 | -# Create Canonical logo file in Librarian |
220 | -filename = os.path.join( |
221 | - config.root, 'lib/canonical/launchpad/icing/canonical-logo.png') |
222 | -size = os.path.getsize(filename) |
223 | -fp = open(filename, 'rb') |
224 | -logo = getUtility(ILibraryFileAliasSet).create( |
225 | - name='canonical-logo.png', size=size, file=fp, contentType='image/png') |
226 | - |
227 | -# Create RP configs |
228 | -for trust_root in ['http://pdl-dev.co.uk', 'http://www.mmania.biz', |
229 | - 'http://shop.canonical.com', 'https://shop.canonical.com', |
230 | - 'https://testshop.canonical.com']: |
231 | - rpconfig = getUtility(IOpenIDRPConfigSet).new( |
232 | - trust_root=trust_root, |
233 | - displayname="The Ubuntu Store from Canonical", |
234 | - description=("For the Ubuntu Store, you need a Launchpad account " |
235 | - "so we can remember your order details and keep in " |
236 | - "touch with you about your orders."), |
237 | - logo=logo, |
238 | - allowed_sreg=['email', 'fullname', 'nickname', |
239 | - 'x_address1', 'x_address2', 'x_organization', |
240 | - 'x_city', 'x_province', 'country', 'postcode', |
241 | - 'x_phone'], |
242 | - creation_rationale=PCR.OWNER_CREATED_UBUNTU_SHOP) |
243 | - |
244 | -ztm.commit() |
245 | |
246 | === removed file 'database/schema/pending/import_language_packs.py' |
247 | --- database/schema/pending/import_language_packs.py 2010-10-03 15:30:06 +0000 |
248 | +++ database/schema/pending/import_language_packs.py 1970-01-01 00:00:00 +0000 |
249 | @@ -1,69 +0,0 @@ |
250 | -#!/usr/bin/python |
251 | -# |
252 | -# Copyright 2009 Canonical Ltd. This software is licensed under the |
253 | -# GNU Affero General Public License version 3 (see the file LICENSE). |
254 | - |
255 | -"""Script to upload existing language packs into Launchpad.""" |
256 | - |
257 | -from urllib2 import urlopen |
258 | -from zope.component import getUtility |
259 | - |
260 | -from canonical.launchpad.scripts import execute_zcml_for_scripts |
261 | -from canonical.launchpad.interfaces import ( |
262 | - IDistributionSet, ILanguagePackSet, LanguagePackType) |
263 | -from canonical.librarian.interfaces import ILibrarianClient |
264 | -from canonical.lp import initZopeless |
265 | - |
266 | -language_packs_dates = { |
267 | - 'dapper': '2007-08-03', |
268 | - 'edgy': '2006-10-19', |
269 | - 'feisty': '2007-04-12', |
270 | - 'gutsy': '2007-08-02', |
271 | - } |
272 | - |
273 | - |
274 | -def get_langpack_url(distroseries_name, export_date): |
275 | - filename = 'rosetta-%s-%s.tar.gz' % (distroseries_name, export_date) |
276 | - return 'http://people.ubuntu.com/~carlos/language-packs/%s/%s' % ( |
277 | - distroseries_name, filename) |
278 | - |
279 | - |
280 | -def main(): |
281 | - # setup a transaction manager to LPDB |
282 | - tm = initZopeless() |
283 | - |
284 | - # load the zcml configuration |
285 | - execute_zcml_for_scripts() |
286 | - |
287 | - # get an librarian client instance |
288 | - client = getUtility(ILibrarianClient) |
289 | - |
290 | - for distroseries_name, langpack_date in language_packs_dates.iteritems(): |
291 | - # Open the language pack file. |
292 | - langpack = urlopen(get_langpack_url(distroseries_name, langpack_date)) |
293 | - |
294 | - # Get some metadata information. |
295 | - flen = int(langpack.info()['Content-Length']) |
296 | - filename = 'ubuntu-%s-translations.tar.gz' % distroseries_name |
297 | - ftype = 'application/x-gtar' |
298 | - |
299 | - # Add it to Librarian |
300 | - file_alias = client.addFile( |
301 | - filename, flen, langpack, contentType=ftype) |
302 | - |
303 | - # Register it in the LanguagePack table. |
304 | - distribution = getUtility(IDistributionSet)['ubuntu'] |
305 | - distroseries = distribution.getSeries(distroseries_name) |
306 | - language_pack_set = getUtility(ILanguagePackSet) |
307 | - lang_pack_type = LanguagePackType.FULL |
308 | - |
309 | - # And set it as the base one. |
310 | - distroseries.language_pack_base = language_pack_set.addLanguagePack( |
311 | - distroseries, file_alias, lang_pack_type) |
312 | - |
313 | - # Store the changes. |
314 | - tm.commit() |
315 | - |
316 | - |
317 | -if __name__ == '__main__': |
318 | - main() |
319 | |
320 | === removed file 'database/schema/pending/update-shippingrequest-types.py' |
321 | --- database/schema/pending/update-shippingrequest-types.py 2010-10-03 15:30:06 +0000 |
322 | +++ database/schema/pending/update-shippingrequest-types.py 1970-01-01 00:00:00 +0000 |
323 | @@ -1,51 +0,0 @@ |
324 | -#!/usr/bin/python -S |
325 | -# |
326 | -# Copyright 2009 Canonical Ltd. This software is licensed under the |
327 | -# GNU Affero General Public License version 3 (see the file LICENSE). |
328 | - |
329 | -# Update the type of all Feisty requests since these are the only ones we can |
330 | -# still infer. |
331 | - |
332 | -import _pythonpath |
333 | - |
334 | -from canonical.database.sqlbase import cursor, sqlvalues |
335 | -from canonical.launchpad.database import ShippingRequest |
336 | -from canonical.launchpad.scripts import execute_zcml_for_scripts |
337 | -from canonical.lp import initZopeless |
338 | -from canonical.launchpad.interfaces import ( |
339 | - ShipItDistroSeries, ShipItFlavour, ShippingRequestType) |
340 | - |
341 | - |
342 | -execute_zcml_for_scripts() |
343 | -ztm = initZopeless(implicitBegin=False) |
344 | - |
345 | -ztm.begin() |
346 | -query = """ |
347 | - SELECT DISTINCT ShippingRequest.id |
348 | - FROM ShippingRequest |
349 | - WHERE ShippingRequest.type IS NULL |
350 | - AND ShippingRequest.id IN ( |
351 | - SELECT request FROM RequestedCDs WHERE distrorelease = %s) |
352 | - """ % sqlvalues(ShipItDistroSeries.FEISTY) |
353 | -cur = cursor() |
354 | -cur.execute(query) |
355 | -ids = cur.fetchall() |
356 | -ztm.abort() |
357 | - |
358 | -for [id] in ids: |
359 | - ztm.begin() |
360 | - |
361 | - request = ShippingRequest.get(id) |
362 | - requested_cds = request.getAllRequestedCDs() |
363 | - is_custom = False |
364 | - for flavour in ShipItFlavour.items: |
365 | - if request.containsCustomQuantitiesOfFlavour(flavour): |
366 | - is_custom = True |
367 | - if is_custom: |
368 | - request.type = ShippingRequestType.CUSTOM |
369 | - print "Updated type of request #%d to CUSTOM" % request.id |
370 | - else: |
371 | - request.type = ShippingRequestType.STANDARD |
372 | - print "Updated type of request #%d to STANDARD" % request.id |
373 | - |
374 | - ztm.commit() |
375 | |
376 | === modified file 'lib/canonical/database/harness.py' |
377 | --- lib/canonical/database/harness.py 2010-10-03 15:30:06 +0000 |
378 | +++ lib/canonical/database/harness.py 2010-11-08 14:57:15 +0000 |
379 | @@ -33,7 +33,6 @@ |
380 | # |
381 | # pylint: disable-msg=W0614,W0401 |
382 | from canonical.launchpad.database import * |
383 | -from canonical.launchpad.interfaces import * |
384 | from lp.bugs.model.bug import Bug |
385 | from lp.testing.factory import LaunchpadObjectFactory |
386 | from lp.testing.mail import create_mail_for_directoryMailBox |
387 | |
388 | === modified file 'lib/canonical/database/sqlbase.py' |
389 | --- lib/canonical/database/sqlbase.py 2010-10-24 12:37:51 +0000 |
390 | +++ lib/canonical/database/sqlbase.py 2010-11-08 14:57:15 +0000 |
391 | @@ -183,7 +183,7 @@ |
392 | We refetch any parameters from different stores from the |
393 | correct master Store. |
394 | """ |
395 | - from canonical.launchpad.interfaces import IMasterStore |
396 | + from canonical.launchpad.interfaces.lpstorm import IMasterStore |
397 | # Make it simple to write dumb-invalidators - initialised |
398 | # _cached_properties to a valid list rather than just-in-time creation. |
399 | self._cached_properties = [] |
400 | @@ -219,7 +219,7 @@ |
401 | |
402 | @classmethod |
403 | def _get_store(cls): |
404 | - from canonical.launchpad.interfaces import IStore |
405 | + from canonical.launchpad.interfaces.lpstorm import IStore |
406 | return IStore(cls) |
407 | |
408 | def __repr__(self): |
409 | @@ -229,7 +229,7 @@ |
410 | return '<%s at 0x%x>' % (self.__class__.__name__, id(self)) |
411 | |
412 | def destroySelf(self): |
413 | - from canonical.launchpad.interfaces import IMasterObject |
414 | + from canonical.launchpad.interfaces.lpstorm import IMasterObject |
415 | my_master = IMasterObject(self) |
416 | if self is my_master: |
417 | super(SQLBase, self).destroySelf() |
418 | |
419 | === modified file 'lib/canonical/launchpad/browser/feeds.py' |
420 | --- lib/canonical/launchpad/browser/feeds.py 2010-10-03 15:30:06 +0000 |
421 | +++ lib/canonical/launchpad/browser/feeds.py 2010-11-08 14:57:15 +0000 |
422 | @@ -29,17 +29,7 @@ |
423 | from zope.security.interfaces import Unauthorized |
424 | |
425 | from canonical.config import config |
426 | -from canonical.launchpad.interfaces import ( |
427 | - IAnnouncementSet, |
428 | - IBugSet, |
429 | - IBugTask, |
430 | - IBugTaskSet, |
431 | - IFeedsApplication, |
432 | - IHasAnnouncements, |
433 | - IHasBugs, |
434 | - ILaunchpadRoot, |
435 | - IPillarNameSet, |
436 | - ) |
437 | +from canonical.launchpad.interfaces.launchpad import IFeedsApplication |
438 | from canonical.launchpad.layers import FeedsLayer |
439 | from canonical.launchpad.webapp import ( |
440 | canonical_name, |
441 | @@ -47,16 +37,30 @@ |
442 | Navigation, |
443 | stepto, |
444 | ) |
445 | -from canonical.launchpad.webapp.interfaces import ICanonicalUrlData |
446 | +from canonical.launchpad.webapp.interfaces import ( |
447 | + ICanonicalUrlData, |
448 | + ILaunchpadRoot, |
449 | + ) |
450 | from canonical.launchpad.webapp.publisher import RedirectionView |
451 | from canonical.launchpad.webapp.url import urlappend |
452 | from canonical.launchpad.webapp.vhosts import allvhosts |
453 | from lp.app.errors import NotFoundError |
454 | +from lp.bugs.interfaces.bug import IBugSet |
455 | +from lp.bugs.interfaces.bugtarget import IHasBugs |
456 | +from lp.bugs.interfaces.bugtask import ( |
457 | + IBugTask, |
458 | + IBugTaskSet, |
459 | + ) |
460 | from lp.code.interfaces.branch import IBranch |
461 | +from lp.registry.interfaces.announcement import ( |
462 | + IAnnouncementSet, |
463 | + IHasAnnouncements, |
464 | + ) |
465 | from lp.registry.interfaces.person import ( |
466 | IPerson, |
467 | IPersonSet, |
468 | ) |
469 | +from lp.registry.interfaces.pillar import IPillarNameSet |
470 | from lp.registry.interfaces.product import IProduct |
471 | from lp.registry.interfaces.projectgroup import IProjectGroup |
472 | |
473 | |
474 | === modified file 'lib/canonical/launchpad/browser/launchpadstatistic.py' |
475 | --- lib/canonical/launchpad/browser/launchpadstatistic.py 2010-10-03 15:30:06 +0000 |
476 | +++ lib/canonical/launchpad/browser/launchpadstatistic.py 2010-11-08 14:57:15 +0000 |
477 | @@ -10,7 +10,9 @@ |
478 | 'LaunchpadStatisticSetFacets', |
479 | ] |
480 | |
481 | -from canonical.launchpad.interfaces import ILaunchpadStatisticSet |
482 | +from canonical.launchpad.interfaces.launchpadstatistic import ( |
483 | + ILaunchpadStatisticSet, |
484 | + ) |
485 | from canonical.launchpad.webapp import ( |
486 | LaunchpadView, |
487 | StandardLaunchpadFacets, |
488 | |
489 | === modified file 'lib/canonical/launchpad/browser/librarian.py' |
490 | --- lib/canonical/launchpad/browser/librarian.py 2010-10-03 15:30:06 +0000 |
491 | +++ lib/canonical/launchpad/browser/librarian.py 2010-11-08 14:57:15 +0000 |
492 | @@ -26,7 +26,7 @@ |
493 | from zope.publisher.interfaces.browser import IBrowserPublisher |
494 | from zope.security.interfaces import Unauthorized |
495 | |
496 | -from canonical.launchpad.interfaces import ILibraryFileAlias |
497 | +from canonical.launchpad.interfaces.librarian import ILibraryFileAlias |
498 | from canonical.launchpad.layers import WebServiceLayer |
499 | from canonical.launchpad.webapp.authorization import check_permission |
500 | from canonical.launchpad.webapp.interfaces import ( |
501 | |
502 | === modified file 'lib/canonical/launchpad/browser/packagerelationship.py' |
503 | --- lib/canonical/launchpad/browser/packagerelationship.py 2010-10-03 15:30:06 +0000 |
504 | +++ lib/canonical/launchpad/browser/packagerelationship.py 2010-11-08 14:57:15 +0000 |
505 | @@ -13,7 +13,7 @@ |
506 | import operator as std_operator |
507 | from zope.interface import implements |
508 | |
509 | -from canonical.launchpad.interfaces import ( |
510 | +from canonical.launchpad.interfaces.packagerelationship import ( |
511 | IPackageRelationship, |
512 | IPackageRelationshipSet, |
513 | ) |
514 | |
515 | === modified file 'lib/canonical/launchpad/components/cdatetime.py' |
516 | --- lib/canonical/launchpad/components/cdatetime.py 2010-10-03 15:30:06 +0000 |
517 | +++ lib/canonical/launchpad/components/cdatetime.py 2010-11-08 14:57:15 +0000 |
518 | @@ -10,7 +10,7 @@ |
519 | import pytz |
520 | from zope.interface import implements |
521 | |
522 | -from canonical.launchpad.interfaces import IAging |
523 | +from canonical.launchpad.interfaces.launchpad import IAging |
524 | |
525 | |
526 | SECONDS_PER_HOUR = 3600 |
527 | |
528 | === modified file 'lib/canonical/launchpad/components/tokens.py' |
529 | --- lib/canonical/launchpad/components/tokens.py 2010-10-03 15:30:06 +0000 |
530 | +++ lib/canonical/launchpad/components/tokens.py 2010-11-08 14:57:15 +0000 |
531 | @@ -14,7 +14,7 @@ |
532 | |
533 | from zope.component import getUtility |
534 | |
535 | -from canonical.launchpad.interfaces import IMasterStore |
536 | +from canonical.launchpad.interfaces.lpstorm import IMasterStore |
537 | |
538 | |
539 | def create_token(token_length): |
540 | |
541 | === modified file 'lib/canonical/launchpad/database/account.py' |
542 | --- lib/canonical/launchpad/database/account.py 2010-10-03 15:30:06 +0000 |
543 | +++ lib/canonical/launchpad/database/account.py 2010-11-08 14:57:15 +0000 |
544 | @@ -17,14 +17,13 @@ |
545 | from zope.security.proxy import removeSecurityProxy |
546 | |
547 | from canonical.database.constants import ( |
548 | - DEFAULT, |
549 | UTC_NOW, |
550 | ) |
551 | from canonical.database.datetimecol import UtcDateTimeCol |
552 | from canonical.database.enumcol import EnumCol |
553 | from canonical.database.sqlbase import SQLBase |
554 | from canonical.launchpad.database.emailaddress import EmailAddress |
555 | -from canonical.launchpad.interfaces import ( |
556 | +from canonical.launchpad.interfaces.lpstorm import ( |
557 | IMasterObject, |
558 | IMasterStore, |
559 | IStore, |
560 | |
561 | === modified file 'lib/canonical/launchpad/database/emailaddress.py' |
562 | --- lib/canonical/launchpad/database/emailaddress.py 2010-10-03 15:30:06 +0000 |
563 | +++ lib/canonical/launchpad/database/emailaddress.py 2010-11-08 14:57:15 +0000 |
564 | @@ -27,7 +27,7 @@ |
565 | SQLBase, |
566 | sqlvalues, |
567 | ) |
568 | -from canonical.launchpad.interfaces import ( |
569 | +from canonical.launchpad.interfaces.emailaddress import ( |
570 | EmailAddressAlreadyTaken, |
571 | EmailAddressStatus, |
572 | IEmailAddress, |
573 | |
574 | === modified file 'lib/canonical/launchpad/database/launchpadstatistic.py' |
575 | --- lib/canonical/launchpad/database/launchpadstatistic.py 2010-10-03 15:30:06 +0000 |
576 | +++ lib/canonical/launchpad/database/launchpadstatistic.py 2010-11-08 14:57:15 +0000 |
577 | @@ -25,15 +25,15 @@ |
578 | SQLBase, |
579 | sqlvalues, |
580 | ) |
581 | -from canonical.launchpad.interfaces import ( |
582 | +from canonical.launchpad.interfaces.launchpadstatistic import ( |
583 | ILaunchpadStatistic, |
584 | ILaunchpadStatisticSet, |
585 | - IPersonSet, |
586 | - QuestionStatus, |
587 | ) |
588 | +from lp.answers.interfaces.questionenums import QuestionStatus |
589 | from lp.answers.model.question import Question |
590 | from lp.bugs.model.bug import Bug |
591 | from lp.bugs.model.bugtask import BugTask |
592 | +from lp.registry.interfaces.person import IPersonSet |
593 | from lp.registry.model.product import Product |
594 | from lp.services.worlddata.model.language import Language |
595 | from lp.translations.model.pofile import POFile |
596 | |
597 | === modified file 'lib/canonical/launchpad/database/librarian.py' |
598 | --- lib/canonical/launchpad/database/librarian.py 2010-10-03 15:30:06 +0000 |
599 | +++ lib/canonical/launchpad/database/librarian.py 2010-11-08 14:57:15 +0000 |
600 | @@ -57,14 +57,14 @@ |
601 | session_store, |
602 | SQLBase, |
603 | ) |
604 | -from canonical.launchpad.interfaces import ( |
605 | +from canonical.launchpad.interfaces.librarian import ( |
606 | ILibraryFileAlias, |
607 | ILibraryFileAliasSet, |
608 | ILibraryFileAliasWithParent, |
609 | ILibraryFileContent, |
610 | ILibraryFileDownloadCount, |
611 | - IMasterStore, |
612 | ) |
613 | +from canonical.launchpad.interfaces.lpstorm import IMasterStore |
614 | from canonical.librarian.interfaces import ( |
615 | DownloadFailed, |
616 | ILibrarianClient, |
617 | |
618 | === modified file 'lib/canonical/launchpad/database/logintoken.py' |
619 | --- lib/canonical/launchpad/database/logintoken.py 2010-10-03 15:30:06 +0000 |
620 | +++ lib/canonical/launchpad/database/logintoken.py 2010-11-08 14:57:15 +0000 |
621 | @@ -31,14 +31,13 @@ |
622 | create_unique_token_for_table, |
623 | ) |
624 | from canonical.launchpad.helpers import get_email_template |
625 | -from canonical.launchpad.interfaces import ( |
626 | - IGPGHandler, |
627 | +from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet |
628 | +from canonical.launchpad.interfaces.gpghandler import IGPGHandler |
629 | +from canonical.launchpad.interfaces.authtoken import LoginTokenType |
630 | +from canonical.launchpad.interfaces.logintoken import ( |
631 | ILoginToken, |
632 | ILoginTokenSet, |
633 | - IPersonSet, |
634 | - LoginTokenType, |
635 | ) |
636 | -from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet |
637 | from canonical.launchpad.interfaces.lpstorm import IMasterObject |
638 | from canonical.launchpad.mail import ( |
639 | format_address, |
640 | @@ -53,6 +52,7 @@ |
641 | ) |
642 | from lp.app.errors import NotFoundError |
643 | from lp.registry.interfaces.gpg import IGPGKeySet |
644 | +from lp.registry.interfaces.person import IPersonSet |
645 | |
646 | |
647 | class LoginToken(SQLBase): |
648 | |
649 | === modified file 'lib/canonical/launchpad/database/message.py' |
650 | --- lib/canonical/launchpad/database/message.py 2010-10-21 16:36:01 +0000 |
651 | +++ lib/canonical/launchpad/database/message.py 2010-11-08 14:57:15 +0000 |
652 | @@ -63,11 +63,8 @@ |
653 | from canonical.database.sqlbase import SQLBase |
654 | from canonical.encoding import guess as ensure_unicode |
655 | from canonical.launchpad.helpers import get_filename_from_message_id |
656 | -from canonical.launchpad.interfaces import ( |
657 | +from canonical.launchpad.interfaces.librarian import ( |
658 | ILibraryFileAliasSet, |
659 | - IPersonSet, |
660 | - PersonCreationRationale, |
661 | - UnknownSender, |
662 | ) |
663 | from canonical.launchpad.interfaces.message import ( |
664 | IDirectEmailAuthorization, |
665 | @@ -77,10 +74,15 @@ |
666 | IMessageSet, |
667 | InvalidEmailMessage, |
668 | IUserToUserEmail, |
669 | + UnknownSender, |
670 | ) |
671 | from canonical.launchpad.mail import signed_message_from_string |
672 | from lp.app.errors import NotFoundError |
673 | -from lp.registry.interfaces.person import validate_public_person |
674 | +from lp.registry.interfaces.person import ( |
675 | + IPersonSet, |
676 | + PersonCreationRationale, |
677 | + validate_public_person, |
678 | + ) |
679 | from lp.services.job.model.job import Job |
680 | from lp.services.propertycache import cachedproperty |
681 | |
682 | |
683 | === modified file 'lib/canonical/launchpad/database/oauth.py' |
684 | --- lib/canonical/launchpad/database/oauth.py 2010-11-02 17:06:44 +0000 |
685 | +++ lib/canonical/launchpad/database/oauth.py 2010-11-08 14:57:15 +0000 |
686 | @@ -34,7 +34,7 @@ |
687 | create_token, |
688 | create_unique_token_for_table, |
689 | ) |
690 | -from canonical.launchpad.interfaces import ( |
691 | +from canonical.launchpad.interfaces.oauth import ( |
692 | ClockSkew, |
693 | IOAuthAccessToken, |
694 | IOAuthConsumer, |
695 | |
696 | === modified file 'lib/canonical/launchpad/database/temporaryblobstorage.py' |
697 | --- lib/canonical/launchpad/database/temporaryblobstorage.py 2010-10-03 15:30:06 +0000 |
698 | +++ lib/canonical/launchpad/database/temporaryblobstorage.py 2010-11-08 14:57:15 +0000 |
699 | @@ -32,12 +32,12 @@ |
700 | from canonical.database.datetimecol import UtcDateTimeCol |
701 | from canonical.database.sqlbase import SQLBase |
702 | from canonical.launchpad.database.librarian import LibraryFileAlias |
703 | -from canonical.launchpad.interfaces import ( |
704 | +from canonical.launchpad.interfaces.temporaryblobstorage import ( |
705 | BlobTooLarge, |
706 | - ILibraryFileAliasSet, |
707 | ITemporaryBlobStorage, |
708 | ITemporaryStorageManager, |
709 | ) |
710 | +from canonical.launchpad.interfaces.librarian import ILibraryFileAliasSet |
711 | from canonical.launchpad.interfaces.lpstorm import IStore |
712 | from lp.services.job.interfaces.job import JobStatus |
713 | |
714 | |
715 | === modified file 'lib/canonical/launchpad/doc/security.txt' |
716 | --- lib/canonical/launchpad/doc/security.txt 2010-10-03 15:30:06 +0000 |
717 | +++ lib/canonical/launchpad/doc/security.txt 2010-11-08 14:57:15 +0000 |
718 | @@ -63,7 +63,7 @@ |
719 | |
720 | <adapter |
721 | provides="canonical.launchpad.webapp.interfaces.IAuthorization" |
722 | - for="canonical.launchpad.interfaces.IProduct" |
723 | + for="lp.registry.interfaces.product.IProduct" |
724 | name="launchpad.Edit" |
725 | factory="canonical.launchpad.security.EditByOwner" |
726 | /> |
727 | |
728 | === modified file 'lib/canonical/launchpad/doc/validation.txt' |
729 | --- lib/canonical/launchpad/doc/validation.txt 2010-10-18 22:24:59 +0000 |
730 | +++ lib/canonical/launchpad/doc/validation.txt 2010-11-08 14:57:15 +0000 |
731 | @@ -7,7 +7,7 @@ |
732 | The validate_distrotask() function is used to guarantee that distribution |
733 | bugtasks are unique per bug. |
734 | |
735 | - >>> from canonical.launchpad.interfaces import validate_distrotask |
736 | + >>> from canonical.launchpad.interfaces.validation import validate_distrotask |
737 | >>> from lp.bugs.interfaces.bug import IBugSet |
738 | >>> from lp.registry.interfaces.distribution import IDistributionSet |
739 | >>> from lp.registry.interfaces.sourcepackagename import ISourcePackageNameSet |
740 | |
741 | === modified file 'lib/canonical/launchpad/doc/xmlrpc-selftest.txt' |
742 | --- lib/canonical/launchpad/doc/xmlrpc-selftest.txt 2009-03-24 12:43:49 +0000 |
743 | +++ lib/canonical/launchpad/doc/xmlrpc-selftest.txt 2010-11-08 14:57:15 +0000 |
744 | @@ -2,7 +2,7 @@ |
745 | |
746 | The Launchpad root object has a simple XMLRPC API to show that XMLRPC works. |
747 | |
748 | - >>> from canonical.launchpad.xmlrpc import SelfTest, ISelfTest |
749 | + >>> from canonical.launchpad.xmlrpc.application import SelfTest, ISelfTest |
750 | >>> from canonical.launchpad.webapp.testing import verifyObject |
751 | >>> selftestview = SelfTest('somecontext', 'somerequest') |
752 | >>> verifyObject(ISelfTest, selftestview) |
753 | |
754 | === modified file 'lib/canonical/launchpad/helpers.py' |
755 | --- lib/canonical/launchpad/helpers.py 2010-10-03 15:30:06 +0000 |
756 | +++ lib/canonical/launchpad/helpers.py 2010-11-08 14:57:15 +0000 |
757 | @@ -25,7 +25,7 @@ |
758 | from zope.security.interfaces import ForbiddenAttribute |
759 | |
760 | import canonical |
761 | -from canonical.launchpad.interfaces import ILaunchBag |
762 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
763 | from lp.services.geoip.interfaces import ( |
764 | IRequestLocalLanguages, |
765 | IRequestPreferredLanguages, |
766 | |
767 | === modified file 'lib/canonical/launchpad/interfaces/__init__.py' |
768 | --- lib/canonical/launchpad/interfaces/__init__.py 2010-10-31 20:18:45 +0000 |
769 | +++ lib/canonical/launchpad/interfaces/__init__.py 2010-11-08 14:57:15 +0000 |
770 | @@ -1,146 +1,12 @@ |
771 | -# Copyright 2009 Canonical Ltd. This software is licensed under the |
772 | -# GNU Affero General Public License version 3 (see the file LICENSE). |
773 | - |
774 | -# pylint: disable-msg=W0401,C0301 |
775 | - |
776 | -__metaclass__ = type |
777 | - |
778 | -# XXX flacoste 2009/03/18 We should use specific imports instead of |
779 | -# importing from this module. |
780 | - |
781 | -# SKIP this file when formatting imports. |
782 | -from canonical.launchpad.interfaces.launchpad import * |
783 | -from lp.bugs.interfaces.malone import * |
784 | -from canonical.launchpad.interfaces.validation import * |
785 | - |
786 | -# these need to be at the top, because the others depend on them sometimes |
787 | -from lp.blueprints.interfaces.specificationtarget import * |
788 | -from lp.registry.interfaces.person import * |
789 | -from lp.registry.interfaces.pillar import * |
790 | - |
791 | -from canonical.launchpad.interfaces.account import * |
792 | -from lp.soyuz.interfaces.archive import * |
793 | -from lp.soyuz.interfaces.archivedependency import * |
794 | -from lp.soyuz.interfaces.archivepermission import * |
795 | -from lp.soyuz.interfaces.archivesubscriber import * |
796 | -from lp.registry.interfaces.announcement import * |
797 | -from canonical.launchpad.interfaces.authserver import * |
798 | -from canonical.launchpad.interfaces.authtoken import * |
799 | -from lp.soyuz.interfaces.binarypackagerelease import * |
800 | -from lp.soyuz.interfaces.binarypackagename import * |
801 | -from lp.bugs.interfaces.bugactivity import * |
802 | -from lp.bugs.interfaces.bugattachment import * |
803 | -from lp.bugs.interfaces.bug import * |
804 | -from lp.bugs.interfaces.bugbranch import * |
805 | -from lp.bugs.interfaces.bugcve import * |
806 | -from lp.bugs.interfaces.buglink import * |
807 | -from lp.bugs.interfaces.bugmessage import * |
808 | -from lp.bugs.interfaces.bugnomination import * |
809 | -from lp.bugs.interfaces.bugnotification import * |
810 | -from lp.bugs.interfaces.bugsubscription import * |
811 | -from lp.bugs.interfaces.bugsupervisor import * |
812 | -from lp.bugs.interfaces.bugtask import * |
813 | -from lp.bugs.interfaces.bugtarget import * |
814 | -from lp.bugs.interfaces.bugtracker import * |
815 | -from lp.bugs.interfaces.bugwatch import * |
816 | -from lp.soyuz.interfaces.binarypackagebuild import * |
817 | -from lp.buildmaster.interfaces.builder import * |
818 | -from lp.soyuz.interfaces.buildrecords import * |
819 | -from lp.registry.interfaces.codeofconduct import * |
820 | -from lp.registry.interfaces.commercialsubscription import * |
821 | -from lp.soyuz.interfaces.component import * |
822 | -from lp.services.worlddata.interfaces.country import * |
823 | -from lp.bugs.interfaces.cve import * |
824 | -from lp.bugs.interfaces.cvereference import * |
825 | -from lp.registry.interfaces.distribution import * |
826 | -from lp.registry.interfaces.distributionmirror import * |
827 | -from lp.registry.interfaces.distributionsourcepackage import * |
828 | -from lp.registry.interfaces.distroseriesdifference import * |
829 | -from lp.registry.interfaces.distroseriesdifferencecomment import * |
830 | -from lp.soyuz.interfaces.distributionsourcepackagecache import * |
831 | -from lp.soyuz.interfaces.distributionsourcepackagerelease import * |
832 | -from lp.registry.interfaces.series import * |
833 | -from lp.soyuz.interfaces.distroarchseries import * |
834 | -from lp.soyuz.interfaces.distroarchseriesbinarypackage import * |
835 | -from lp.soyuz.interfaces.distroarchseriesbinarypackagerelease\ |
836 | - import * |
837 | -from lp.registry.interfaces.distroseries import * |
838 | -from lp.soyuz.interfaces.distroseriesbinarypackage import * |
839 | -from lp.soyuz.interfaces.distroseriespackagecache import * |
840 | -from lp.soyuz.interfaces.distroseriessourcepackagerelease import * |
841 | -from canonical.launchpad.interfaces.emailaddress import * |
842 | -from lp.registry.interfaces.entitlement import * |
843 | -from lp.bugs.interfaces.externalbugtracker import * |
844 | -from lp.registry.interfaces.featuredproject import * |
845 | -from lp.soyuz.interfaces.files import * |
846 | -from lp.registry.interfaces.gpg import * |
847 | -from canonical.launchpad.interfaces.gpghandler import * |
848 | -from lp.hardwaredb.interfaces.hwdb import * |
849 | -from lp.registry.interfaces.irc import * |
850 | -from lp.registry.interfaces.jabber import * |
851 | -from lp.registry.interfaces.karma import * |
852 | -from lp.services.worlddata.interfaces.language import * |
853 | -from canonical.launchpad.interfaces.launchpad import * |
854 | -from canonical.launchpad.interfaces.launchpadstatistic import * |
855 | -from canonical.launchpad.interfaces.librarian import * |
856 | -from lp.registry.interfaces.location import * |
857 | -from canonical.launchpad.interfaces.logintoken import * |
858 | -from canonical.launchpad.interfaces.lpstorm import * |
859 | -from canonical.launchpad.interfaces.mail import * |
860 | -from canonical.launchpad.interfaces.mailbox import * |
861 | -from lp.registry.interfaces.mailinglist import * |
862 | -from lp.registry.interfaces.mailinglistsubscription import * |
863 | -from canonical.launchpad.interfaces.message import * |
864 | -from lp.registry.interfaces.milestone import * |
865 | -from canonical.launchpad.interfaces.oauth import * |
866 | -from canonical.launchpad.interfaces.openidconsumer import * |
867 | -from canonical.launchpad.interfaces.packagerelationship import * |
868 | -from canonical.launchpad.interfaces.pathlookup import * |
869 | -from lp.registry.interfaces.poll import * |
870 | -from lp.soyuz.interfaces.processor import * |
871 | -from lp.registry.interfaces.product import * |
872 | -from lp.registry.interfaces.productlicense import * |
873 | -from lp.registry.interfaces.productrelease import * |
874 | -from lp.registry.interfaces.productseries import * |
875 | -from lp.registry.interfaces.projectgroup import * |
876 | -from lp.soyuz.interfaces.publishing import * |
877 | -from lp.soyuz.interfaces.queue import * |
878 | -from canonical.launchpad.interfaces.schema import * |
879 | -from lp.services.scripts.interfaces.scriptactivity import * |
880 | -from lp.soyuz.interfaces.section import * |
881 | -from canonical.launchpad.interfaces.searchservice import * |
882 | -from lp.registry.interfaces.sourcepackage import * |
883 | -from lp.registry.interfaces.sourcepackagename import * |
884 | -from lp.soyuz.interfaces.sourcepackagerelease import * |
885 | -from lp.blueprints.interfaces.specification import * |
886 | -from lp.blueprints.interfaces.specificationbranch import * |
887 | -from lp.blueprints.interfaces.specificationbug import * |
888 | -from lp.blueprints.interfaces.specificationdependency import * |
889 | -from lp.blueprints.interfaces.specificationfeedback import * |
890 | -from lp.blueprints.interfaces.specificationsubscription import * |
891 | -from lp.services.worlddata.interfaces.spokenin import * |
892 | -from lp.blueprints.interfaces.sprint import * |
893 | -from lp.blueprints.interfaces.sprintattendance import * |
894 | -from lp.blueprints.interfaces.sprintspecification import * |
895 | -from lp.registry.interfaces.ssh import * |
896 | -from lp.registry.interfaces.structuralsubscription import * |
897 | -from lp.registry.interfaces.teammembership import * |
898 | -from canonical.launchpad.interfaces.temporaryblobstorage import * |
899 | -from lp.registry.interfaces.wikiname import * |
900 | -from lp.soyuz.interfaces.packagediff import * |
901 | -from lp.soyuz.interfaces.packageset import * |
902 | - |
903 | -from lp.answers.interfaces.answercontact import * |
904 | -from lp.answers.interfaces.faq import * |
905 | -from lp.answers.interfaces.faqcollection import * |
906 | -from lp.answers.interfaces.faqtarget import * |
907 | -from lp.answers.interfaces.question import * |
908 | -from lp.coop.answersbugs.interfaces import * |
909 | -from lp.answers.interfaces.questioncollection import * |
910 | -from lp.answers.interfaces.questionenums import * |
911 | -from lp.answers.interfaces.questionmessage import * |
912 | -from lp.answers.interfaces.questionreopening import * |
913 | -from lp.answers.interfaces.questionsubscription import * |
914 | -from lp.answers.interfaces.questiontarget import * |
915 | - |
916 | -from canonical.launchpad.interfaces._schema_circular_imports import * |
917 | +# Copyright 2009-2010 Canonical Ltd. This software is licensed under the GNU |
918 | +# Affero General Public License version 3 (see the file LICENSE). |
919 | + |
920 | +"""Interface definitions for bits of Launchpad that don't fit anywhere else. |
921 | + |
922 | +See also `canonical.launchpad.database` for implementations of these |
923 | +interfaces. |
924 | + |
925 | +DEPRECATED: This package is deprecated. Do not add any new modules to this |
926 | +package. Where possible, move things out of this package into better |
927 | +locations under the 'lp' package. See the `lp` docstring for more details. |
928 | +""" |
929 | |
930 | === modified file 'lib/canonical/launchpad/interfaces/ftests/validation.txt' |
931 | --- lib/canonical/launchpad/interfaces/ftests/validation.txt 2010-10-21 01:42:14 +0000 |
932 | +++ lib/canonical/launchpad/interfaces/ftests/validation.txt 2010-11-08 14:57:15 +0000 |
933 | @@ -17,7 +17,8 @@ |
934 | This validator is used to check if the bug in the launchbag can be |
935 | nominated for the given series. |
936 | |
937 | - >>> from canonical.launchpad.interfaces import can_be_nominated_for_series |
938 | + >>> from canonical.launchpad.interfaces.validation import ( |
939 | + ... can_be_nominated_for_series) |
940 | |
941 | If we create a new bug, all the target's series can be nominated. |
942 | |
943 | |
944 | === modified file 'lib/canonical/launchpad/interfaces/validation.py' |
945 | --- lib/canonical/launchpad/interfaces/validation.py 2010-10-03 15:30:06 +0000 |
946 | +++ lib/canonical/launchpad/interfaces/validation.py 2010-11-08 14:57:15 +0000 |
947 | @@ -222,8 +222,8 @@ |
948 | """Check that the given email is valid and not registered to |
949 | another launchpad account. |
950 | """ |
951 | - from canonical.launchpad.webapp import canonical_url |
952 | - from canonical.launchpad.interfaces import IEmailAddressSet |
953 | + from canonical.launchpad.webapp.publisher import canonical_url |
954 | + from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet |
955 | |
956 | _validate_email(email) |
957 | _check_email_availability(email) |
958 | @@ -239,8 +239,8 @@ |
959 | user that the profile he's trying to create already exists, so there's no |
960 | need to create another one. |
961 | """ |
962 | - from canonical.launchpad.webapp import canonical_url |
963 | - from canonical.launchpad.interfaces import IPersonSet |
964 | + from canonical.launchpad.webapp.publisher import canonical_url |
965 | + from lp.registry.interfaces.person import IPersonSet |
966 | _validate_email(email) |
967 | owner = getUtility(IPersonSet).getByEmail(email) |
968 | if owner is not None: |
969 | |
970 | === modified file 'lib/canonical/launchpad/mail/commands.py' |
971 | --- lib/canonical/launchpad/mail/commands.py 2010-10-03 15:30:06 +0000 |
972 | +++ lib/canonical/launchpad/mail/commands.py 2010-11-08 14:57:15 +0000 |
973 | @@ -25,31 +25,16 @@ |
974 | ) |
975 | from zope.schema import ValidationError |
976 | |
977 | -from canonical.launchpad.interfaces import ( |
978 | +from canonical.launchpad.interfaces.mail import ( |
979 | BugTargetNotFound, |
980 | - BugTaskImportance, |
981 | - BugTaskStatus, |
982 | - CreateBugParams, |
983 | EmailProcessingError, |
984 | - IBug, |
985 | IBugEditEmailCommand, |
986 | IBugEmailCommand, |
987 | - IBugSet, |
988 | IBugTaskEditEmailCommand, |
989 | IBugTaskEmailCommand, |
990 | - ICveSet, |
991 | - IDistribution, |
992 | - IDistributionSourcePackage, |
993 | - IDistroBugTask, |
994 | - IDistroSeries, |
995 | - ILaunchBag, |
996 | - IMessageSet, |
997 | - IPillarNameSet, |
998 | - IProduct, |
999 | - IProductSeries, |
1000 | - IProjectGroup, |
1001 | - ISourcePackage, |
1002 | ) |
1003 | +from canonical.launchpad.interfaces.message import IMessageSet |
1004 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1005 | from canonical.launchpad.mail.helpers import ( |
1006 | get_error_message, |
1007 | get_person_or_team, |
1008 | @@ -60,6 +45,27 @@ |
1009 | NotFoundError, |
1010 | UserCannotUnsubscribePerson, |
1011 | ) |
1012 | +from lp.bugs.interfaces.bug import ( |
1013 | + CreateBugParams, |
1014 | + IBug, |
1015 | + IBugSet, |
1016 | + ) |
1017 | +from lp.bugs.interfaces.bugtask import ( |
1018 | + BugTaskImportance, |
1019 | + BugTaskStatus, |
1020 | + IDistroBugTask, |
1021 | + ) |
1022 | +from lp.bugs.interfaces.cve import ICveSet |
1023 | +from lp.registry.interfaces.distribution import IDistribution |
1024 | +from lp.registry.interfaces.distributionsourcepackage import ( |
1025 | + IDistributionSourcePackage, |
1026 | + ) |
1027 | +from lp.registry.interfaces.distroseries import IDistroSeries |
1028 | +from lp.registry.interfaces.pillar import IPillarNameSet |
1029 | +from lp.registry.interfaces.product import IProduct |
1030 | +from lp.registry.interfaces.productseries import IProductSeries |
1031 | +from lp.registry.interfaces.projectgroup import IProjectGroup |
1032 | +from lp.registry.interfaces.sourcepackage import ISourcePackage |
1033 | |
1034 | |
1035 | def normalize_arguments(string_args): |
1036 | |
1037 | === modified file 'lib/canonical/launchpad/mail/handlers.py' |
1038 | --- lib/canonical/launchpad/mail/handlers.py 2010-10-11 18:29:14 +0000 |
1039 | +++ lib/canonical/launchpad/mail/handlers.py 2010-11-08 14:57:15 +0000 |
1040 | @@ -15,24 +15,16 @@ |
1041 | from canonical.config import config |
1042 | from canonical.database.sqlbase import rollback |
1043 | from canonical.launchpad.helpers import get_email_template |
1044 | -from canonical.launchpad.interfaces import ( |
1045 | - BugAttachmentType, |
1046 | - CreatedBugWithNoBugTasksError, |
1047 | +from canonical.launchpad.interfaces.gpghandler import IGPGHandler |
1048 | +from canonical.launchpad.interfaces.mail import ( |
1049 | EmailProcessingError, |
1050 | - IBugAttachmentSet, |
1051 | IBugEditEmailCommand, |
1052 | IBugEmailCommand, |
1053 | - IBugMessageSet, |
1054 | IBugTaskEditEmailCommand, |
1055 | IBugTaskEmailCommand, |
1056 | - ILaunchBag, |
1057 | IMailHandler, |
1058 | - IMessageSet, |
1059 | - IQuestionSet, |
1060 | - ISpecificationSet, |
1061 | - QuestionStatus, |
1062 | ) |
1063 | -from canonical.launchpad.interfaces.gpghandler import IGPGHandler |
1064 | +from canonical.launchpad.interfaces.message import IMessageSet |
1065 | from canonical.launchpad.mail.commands import ( |
1066 | BugEmailCommands, |
1067 | get_error_message, |
1068 | @@ -52,6 +44,16 @@ |
1069 | send_process_error_notification, |
1070 | ) |
1071 | from canonical.launchpad.webapp import urlparse |
1072 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1073 | +from lp.answers.interfaces.questioncollection import IQuestionSet |
1074 | +from lp.answers.interfaces.questionenums import QuestionStatus |
1075 | +from lp.blueprints.interfaces.specification import ISpecificationSet |
1076 | +from lp.bugs.interfaces.bug import CreatedBugWithNoBugTasksError |
1077 | +from lp.bugs.interfaces.bugattachment import ( |
1078 | + BugAttachmentType, |
1079 | + IBugAttachmentSet, |
1080 | + ) |
1081 | +from lp.bugs.interfaces.bugmessage import IBugMessageSet |
1082 | from lp.code.mail.codehandler import CodeHandler |
1083 | from lp.services.mail.sendmail import ( |
1084 | sendmail, |
1085 | |
1086 | === modified file 'lib/canonical/launchpad/mail/helpers.py' |
1087 | --- lib/canonical/launchpad/mail/helpers.py 2010-10-03 15:30:06 +0000 |
1088 | +++ lib/canonical/launchpad/mail/helpers.py 2010-11-08 14:57:15 +0000 |
1089 | @@ -9,7 +9,7 @@ |
1090 | |
1091 | from zope.component import getUtility |
1092 | |
1093 | -from canonical.launchpad.interfaces import ( |
1094 | +from lp.bugs.interfaces.bugtask import ( |
1095 | IDistroBugTask, |
1096 | IDistroSeriesBugTask, |
1097 | IUpstreamBugTask, |
1098 | @@ -51,7 +51,7 @@ |
1099 | def get_bugtask_type(bugtask): |
1100 | """Returns the specific IBugTask interface the bugtask provides. |
1101 | |
1102 | - >>> from canonical.launchpad.interfaces import ( |
1103 | + >>> from lp.bugs.interfaces.bugtask import ( |
1104 | ... IUpstreamBugTask, IDistroBugTask, IDistroSeriesBugTask) |
1105 | >>> from zope.interface import classImplementsOnly |
1106 | >>> class BugTask: |
1107 | |
1108 | === modified file 'lib/canonical/launchpad/mail/meta.py' |
1109 | --- lib/canonical/launchpad/mail/meta.py 2010-10-03 15:30:06 +0000 |
1110 | +++ lib/canonical/launchpad/mail/meta.py 2010-11-08 14:57:15 +0000 |
1111 | @@ -15,7 +15,7 @@ |
1112 | from zope.sendmail.interfaces import IMailer |
1113 | from zope.sendmail.zcml import IMailerDirective |
1114 | |
1115 | -from canonical.launchpad.interfaces import IMailBox |
1116 | +from canonical.launchpad.interfaces.mailbox import IMailBox |
1117 | from lp.services.mail.mailbox import ( |
1118 | DirectoryMailBox, |
1119 | POP3MailBox, |
1120 | |
1121 | === modified file 'lib/canonical/launchpad/mailnotification.py' |
1122 | --- lib/canonical/launchpad/mailnotification.py 2010-10-19 22:06:16 +0000 |
1123 | +++ lib/canonical/launchpad/mailnotification.py 2010-11-08 14:57:15 +0000 |
1124 | @@ -30,14 +30,6 @@ |
1125 | get_contact_email_addresses, |
1126 | get_email_template, |
1127 | ) |
1128 | -from canonical.launchpad.interfaces import ( |
1129 | - IHeldMessageDetails, |
1130 | - IPerson, |
1131 | - IPersonSet, |
1132 | - ISpecification, |
1133 | - ITeamMembershipSet, |
1134 | - TeamMembershipStatus, |
1135 | - ) |
1136 | from canonical.launchpad.interfaces.launchpad import ILaunchpadRoot |
1137 | from canonical.launchpad.interfaces.message import ( |
1138 | IDirectEmailAuthorization, |
1139 | @@ -51,7 +43,17 @@ |
1140 | ) |
1141 | from canonical.launchpad.webapp.publisher import canonical_url |
1142 | from canonical.launchpad.webapp.url import urlappend |
1143 | +from lp.blueprints.interfaces.specification import ISpecification |
1144 | from lp.bugs.mail.bugnotificationbuilder import get_bugmail_error_address |
1145 | +from lp.registry.interfaces.mailinglist import IHeldMessageDetails |
1146 | +from lp.registry.interfaces.person import ( |
1147 | + IPerson, |
1148 | + IPersonSet, |
1149 | + ) |
1150 | +from lp.registry.interfaces.teammembership import ( |
1151 | + ITeamMembershipSet, |
1152 | + TeamMembershipStatus, |
1153 | + ) |
1154 | from lp.services.mail.mailwrapper import MailWrapper |
1155 | # XXX 2010-06-16 gmb bug=594985 |
1156 | # This shouldn't be here, but if we take it out lots of things cry, |
1157 | |
1158 | === modified file 'lib/canonical/launchpad/pagetitles.py' |
1159 | --- lib/canonical/launchpad/pagetitles.py 2010-10-06 01:27:34 +0000 |
1160 | +++ lib/canonical/launchpad/pagetitles.py 2010-11-08 14:57:15 +0000 |
1161 | @@ -45,11 +45,9 @@ |
1162 | |
1163 | from zope.component import getUtility |
1164 | |
1165 | -from canonical.launchpad.interfaces import ( |
1166 | - ILaunchBag, |
1167 | - IMaloneApplication, |
1168 | - ) |
1169 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1170 | from canonical.lazr.utils import smartquote |
1171 | +from lp.bugs.interfaces.malone import IMaloneApplication |
1172 | |
1173 | |
1174 | DEFAULT_LAUNCHPAD_TITLE = 'Launchpad' |
1175 | |
1176 | === modified file 'lib/canonical/launchpad/rest/me.py' |
1177 | --- lib/canonical/launchpad/rest/me.py 2010-10-03 15:30:06 +0000 |
1178 | +++ lib/canonical/launchpad/rest/me.py 2010-11-08 14:57:15 +0000 |
1179 | @@ -16,7 +16,7 @@ |
1180 | from zope.component import getUtility |
1181 | from zope.interface import implements |
1182 | |
1183 | -from canonical.launchpad.interfaces import ( |
1184 | +from lp.registry.interfaces.person import ( |
1185 | IPerson, |
1186 | IPersonSet, |
1187 | ) |
1188 | |
1189 | === modified file 'lib/canonical/launchpad/rest/pillarset.py' |
1190 | --- lib/canonical/launchpad/rest/pillarset.py 2010-10-03 15:30:06 +0000 |
1191 | +++ lib/canonical/launchpad/rest/pillarset.py 2010-11-08 14:57:15 +0000 |
1192 | @@ -12,7 +12,7 @@ |
1193 | from lazr.restful.interfaces import ITopLevelEntryLink |
1194 | from zope.interface import implements |
1195 | |
1196 | -from canonical.launchpad.interfaces import IPillarNameSet |
1197 | +from lp.registry.interfaces.pillar import IPillarNameSet |
1198 | from canonical.launchpad.webapp.interfaces import ICanonicalUrlData |
1199 | |
1200 | |
1201 | |
1202 | === modified file 'lib/canonical/launchpad/subscribers/karma.py' |
1203 | --- lib/canonical/launchpad/subscribers/karma.py 2010-10-03 15:30:06 +0000 |
1204 | +++ lib/canonical/launchpad/subscribers/karma.py 2010-11-08 14:57:15 +0000 |
1205 | @@ -5,7 +5,7 @@ |
1206 | application.""" |
1207 | |
1208 | from canonical.database.sqlbase import block_implicit_flushes |
1209 | -from canonical.launchpad.interfaces import BugTaskStatus |
1210 | +from lp.bugs.interfaces.bugtask import BugTaskStatus |
1211 | from lp.bugs.subscribers.bug import get_bug_delta |
1212 | from lp.code.enums import BranchMergeProposalStatus |
1213 | from lp.registry.interfaces.person import IPerson |
1214 | |
1215 | === modified file 'lib/canonical/launchpad/systemhomes.py' |
1216 | --- lib/canonical/launchpad/systemhomes.py 2010-10-03 15:30:06 +0000 |
1217 | +++ lib/canonical/launchpad/systemhomes.py 2010-11-08 14:57:15 +0000 |
1218 | @@ -26,40 +26,40 @@ |
1219 | from zope.interface import implements |
1220 | |
1221 | from canonical.config import config |
1222 | -from canonical.launchpad.interfaces import ( |
1223 | - BugTaskSearchParams, |
1224 | +from canonical.launchpad.interfaces.launchpad import ( |
1225 | IAuthServerApplication, |
1226 | IBazaarApplication, |
1227 | - IBugTaskSet, |
1228 | - IBugTrackerSet, |
1229 | - IBugWatchSet, |
1230 | - IDistroSeriesSet, |
1231 | IFeedsApplication, |
1232 | - IHWDBApplication, |
1233 | - ILanguageSet, |
1234 | - ILaunchBag, |
1235 | - ILaunchpadStatisticSet, |
1236 | - IMailingListApplication, |
1237 | - IMaloneApplication, |
1238 | IPrivateMaloneApplication, |
1239 | - IProductSet, |
1240 | IRosettaApplication, |
1241 | IWebServiceApplication, |
1242 | ) |
1243 | from canonical.launchpad.webapp.interfaces import ( |
1244 | IAPIDocRoot, |
1245 | ICanonicalUrlData, |
1246 | + ILaunchBag, |
1247 | + ) |
1248 | +from canonical.launchpad.interfaces.launchpadstatistic import ( |
1249 | + ILaunchpadStatisticSet, |
1250 | ) |
1251 | from lp.bugs.interfaces.bug import ( |
1252 | CreateBugParams, |
1253 | IBugSet, |
1254 | InvalidBugTargetType, |
1255 | ) |
1256 | +from lp.bugs.interfaces.bugtask import ( |
1257 | + BugTaskSearchParams, |
1258 | + IBugTaskSet, |
1259 | + ) |
1260 | +from lp.bugs.interfaces.bugtracker import IBugTrackerSet |
1261 | +from lp.bugs.interfaces.bugwatch import IBugWatchSet |
1262 | +from lp.bugs.interfaces.malone import IMaloneApplication |
1263 | from lp.code.interfaces.codehosting import ICodehostingApplication |
1264 | from lp.code.interfaces.codeimportscheduler import ( |
1265 | ICodeImportSchedulerApplication, |
1266 | ) |
1267 | from lp.hardwaredb.interfaces.hwdb import ( |
1268 | + IHWDBApplication, |
1269 | IHWDeviceSet, |
1270 | IHWDriverSet, |
1271 | IHWSubmissionDeviceSet, |
1272 | @@ -71,7 +71,13 @@ |
1273 | from lp.registry.interfaces.distributionsourcepackage import ( |
1274 | IDistributionSourcePackage, |
1275 | ) |
1276 | -from lp.registry.interfaces.product import IProduct |
1277 | +from lp.registry.interfaces.distroseries import IDistroSeriesSet |
1278 | +from lp.registry.interfaces.product import ( |
1279 | + IProduct, |
1280 | + IProductSet, |
1281 | + ) |
1282 | +from lp.registry.interfaces.mailinglist import IMailingListApplication |
1283 | +from lp.services.worlddata.interfaces.language import ILanguageSet |
1284 | from lp.testopenid.interfaces.server import ITestOpenIDApplication |
1285 | from lp.translations.interfaces.translationgroup import ITranslationGroupSet |
1286 | from lp.translations.interfaces.translationsoverview import ( |
1287 | |
1288 | === modified file 'lib/canonical/launchpad/testing/fakepackager.py' |
1289 | --- lib/canonical/launchpad/testing/fakepackager.py 2010-10-03 15:30:06 +0000 |
1290 | +++ lib/canonical/launchpad/testing/fakepackager.py 2010-11-08 14:57:15 +0000 |
1291 | @@ -21,13 +21,11 @@ |
1292 | from zope.component import getUtility |
1293 | |
1294 | from canonical.launchpad.ftests.keys_for_tests import import_secret_test_key |
1295 | -from canonical.launchpad.interfaces import ( |
1296 | - IDistributionSet, |
1297 | - IGPGHandler, |
1298 | - ) |
1299 | +from canonical.launchpad.interfaces.gpghandler import IGPGHandler |
1300 | from canonical.launchpad.scripts import QuietFakeLogger |
1301 | from lp.archiveuploader.nascentupload import NascentUpload |
1302 | from lp.archiveuploader.uploadpolicy import findPolicyByName |
1303 | +from lp.registry.interfaces.distribution import IDistributionSet |
1304 | from lp.soyuz.enums import PackageUploadStatus |
1305 | |
1306 | |
1307 | |
1308 | === modified file 'lib/canonical/launchpad/testing/pages.py' |
1309 | --- lib/canonical/launchpad/testing/pages.py 2010-10-26 15:48:33 +0000 |
1310 | +++ lib/canonical/launchpad/testing/pages.py 2010-11-08 14:57:15 +0000 |
1311 | @@ -45,11 +45,10 @@ |
1312 | from zope.security.proxy import removeSecurityProxy |
1313 | from zope.testbrowser.testing import Browser |
1314 | |
1315 | -from canonical.launchpad.interfaces import ( |
1316 | - ILaunchpadCelebrities, |
1317 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
1318 | +from canonical.launchpad.interfaces.oauth import ( |
1319 | IOAuthConsumerSet, |
1320 | OAUTH_REALM, |
1321 | - TeamMembershipStatus, |
1322 | ) |
1323 | from canonical.launchpad.testing.systemdocs import ( |
1324 | LayeredDocFileSuite, |
1325 | @@ -62,6 +61,7 @@ |
1326 | from canonical.launchpad.webapp.url import urlsplit |
1327 | from canonical.testing.layers import PageTestLayer |
1328 | from lp.registry.errors import NameAlreadyTaken |
1329 | +from lp.registry.interfaces.teammembership import TeamMembershipStatus |
1330 | from lp.testing import ( |
1331 | ANONYMOUS, |
1332 | launchpadlib_for, |
1333 | |
1334 | === modified file 'lib/canonical/launchpad/testing/systemdocs.py' |
1335 | --- lib/canonical/launchpad/testing/systemdocs.py 2010-10-26 15:48:33 +0000 |
1336 | +++ lib/canonical/launchpad/testing/systemdocs.py 2010-11-08 14:57:15 +0000 |
1337 | @@ -29,7 +29,7 @@ |
1338 | from canonical.chunkydiff import elided_source |
1339 | from canonical.config import config |
1340 | from canonical.database.sqlbase import flush_database_updates |
1341 | -from canonical.launchpad.interfaces import ILaunchBag |
1342 | +from canonical.launchpad.interfaces.launchpad import ILaunchBag |
1343 | from canonical.launchpad.webapp.testing import verifyObject |
1344 | from canonical.testing import reset_logging |
1345 | from lp.testing import ( |
1346 | |
1347 | === modified file 'lib/canonical/launchpad/utilities/celebrities.py' |
1348 | --- lib/canonical/launchpad/utilities/celebrities.py 2010-10-03 15:30:06 +0000 |
1349 | +++ lib/canonical/launchpad/utilities/celebrities.py 2010-11-08 14:57:15 +0000 |
1350 | @@ -9,16 +9,14 @@ |
1351 | from zope.component import getUtility |
1352 | from zope.interface import implements |
1353 | |
1354 | -from canonical.launchpad.interfaces import ( |
1355 | - IBugTrackerSet, |
1356 | - IDistributionMirrorSet, |
1357 | - IDistributionSet, |
1358 | - ILanguageSet, |
1359 | - ILaunchpadCelebrities, |
1360 | - IPersonSet, |
1361 | - IProductSet, |
1362 | - ) |
1363 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
1364 | from lp.app.errors import NotFoundError |
1365 | +from lp.bugs.interfaces.bugtracker import IBugTrackerSet |
1366 | +from lp.registry.interfaces.distribution import IDistributionSet |
1367 | +from lp.registry.interfaces.distributionmirror import IDistributionMirrorSet |
1368 | +from lp.registry.interfaces.person import IPersonSet |
1369 | +from lp.registry.interfaces.product import IProductSet |
1370 | +from lp.services.worlddata.interfaces.language import ILanguageSet |
1371 | |
1372 | |
1373 | class MutatedCelebrityError(Exception): |
1374 | |
1375 | === modified file 'lib/canonical/launchpad/utilities/personroles.py' |
1376 | --- lib/canonical/launchpad/utilities/personroles.py 2010-10-03 15:30:06 +0000 |
1377 | +++ lib/canonical/launchpad/utilities/personroles.py 2010-11-08 14:57:15 +0000 |
1378 | @@ -12,7 +12,7 @@ |
1379 | ) |
1380 | from zope.interface import implements |
1381 | |
1382 | -from canonical.launchpad.interfaces import ( |
1383 | +from canonical.launchpad.interfaces.launchpad import ( |
1384 | IHasDrivers, |
1385 | ILaunchpadCelebrities, |
1386 | IPersonRoles, |
1387 | |
1388 | === modified file 'lib/canonical/launchpad/webapp/adapter.py' |
1389 | --- lib/canonical/launchpad/webapp/adapter.py 2010-10-20 04:25:48 +0000 |
1390 | +++ lib/canonical/launchpad/webapp/adapter.py 2010-11-08 14:57:15 +0000 |
1391 | @@ -49,7 +49,7 @@ |
1392 | DatabaseConfig, |
1393 | ) |
1394 | from canonical.database.interfaces import IRequestExpired |
1395 | -from canonical.launchpad.interfaces import ( |
1396 | +from canonical.launchpad.interfaces.lpstorm import ( |
1397 | IMasterObject, |
1398 | IMasterStore, |
1399 | ) |
1400 | |
1401 | === modified file 'lib/canonical/launchpad/webapp/dbpolicy.py' |
1402 | --- lib/canonical/launchpad/webapp/dbpolicy.py 2010-10-03 15:30:06 +0000 |
1403 | +++ lib/canonical/launchpad/webapp/dbpolicy.py 2010-11-08 14:57:15 +0000 |
1404 | @@ -25,7 +25,6 @@ |
1405 | Cache, |
1406 | GenerationalCache, |
1407 | ) |
1408 | -from storm.exceptions import TimeoutError |
1409 | from storm.zope.interfaces import IZStorm |
1410 | from zope.app.security.interfaces import IUnauthenticatedPrincipal |
1411 | from zope.component import getUtility |
1412 | @@ -43,7 +42,7 @@ |
1413 | dbconfig, |
1414 | ) |
1415 | from canonical.database.sqlbase import StupidCache |
1416 | -from canonical.launchpad.interfaces import ( |
1417 | +from canonical.launchpad.interfaces.lpstorm import ( |
1418 | IMasterStore, |
1419 | ISlaveStore, |
1420 | ) |
1421 | |
1422 | === modified file 'lib/canonical/launchpad/webapp/launchbag.py' |
1423 | --- lib/canonical/launchpad/webapp/launchbag.py 2010-10-03 15:30:06 +0000 |
1424 | +++ lib/canonical/launchpad/webapp/launchbag.py 2010-11-08 14:57:15 +0000 |
1425 | @@ -14,26 +14,24 @@ |
1426 | from zope.interface import implements |
1427 | |
1428 | from canonical.database.sqlbase import block_implicit_flushes |
1429 | -from canonical.launchpad.interfaces import ( |
1430 | - IAccount, |
1431 | - IBug, |
1432 | - IBugTask, |
1433 | - IDistribution, |
1434 | - IDistroArchSeries, |
1435 | - IDistroSeries, |
1436 | - ILaunchpadCelebrities, |
1437 | - IPerson, |
1438 | - IProduct, |
1439 | - IProjectGroup, |
1440 | - ISourcePackage, |
1441 | - ISpecification, |
1442 | - ) |
1443 | +from canonical.launchpad.interfaces.account import IAccount |
1444 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
1445 | from canonical.launchpad.webapp.interaction import get_current_principal |
1446 | from canonical.launchpad.webapp.interfaces import ( |
1447 | ILaunchBag, |
1448 | ILoggedInEvent, |
1449 | IOpenLaunchBag, |
1450 | ) |
1451 | +from lp.blueprints.interfaces.specification import ISpecification |
1452 | +from lp.bugs.interfaces.bug import IBug |
1453 | +from lp.bugs.interfaces.bugtask import IBugTask |
1454 | +from lp.registry.interfaces.distribution import IDistribution |
1455 | +from lp.registry.interfaces.distroseries import IDistroSeries |
1456 | +from lp.registry.interfaces.person import IPerson |
1457 | +from lp.registry.interfaces.product import IProduct |
1458 | +from lp.registry.interfaces.projectgroup import IProjectGroup |
1459 | +from lp.registry.interfaces.sourcepackage import ISourcePackage |
1460 | +from lp.soyuz.interfaces.distroarchseries import IDistroArchSeries |
1461 | |
1462 | |
1463 | _utc_tz = pytz.timezone('UTC') |
1464 | |
1465 | === modified file 'lib/canonical/launchpad/xmlrpc/__init__.py' |
1466 | --- lib/canonical/launchpad/xmlrpc/__init__.py 2010-09-18 00:08:27 +0000 |
1467 | +++ lib/canonical/launchpad/xmlrpc/__init__.py 2010-11-08 14:57:15 +0000 |
1468 | @@ -5,10 +5,4 @@ |
1469 | |
1470 | """XMLRPC views and APIs on Launchpad objects.""" |
1471 | |
1472 | -from canonical.launchpad.xmlrpc.application import * |
1473 | -from canonical.launchpad.xmlrpc.authserver import * |
1474 | -from lp.bugs.xmlrpc.bug import * |
1475 | -from lp.code.xmlrpc.branch import * |
1476 | -from lp.code.xmlrpc.codeimportscheduler import * |
1477 | - |
1478 | |
1479 | |
1480 | === modified file 'lib/canonical/launchpad/xmlrpc/application.py' |
1481 | --- lib/canonical/launchpad/xmlrpc/application.py 2010-10-03 15:30:06 +0000 |
1482 | +++ lib/canonical/launchpad/xmlrpc/application.py 2010-11-08 14:57:15 +0000 |
1483 | @@ -23,18 +23,18 @@ |
1484 | Interface, |
1485 | ) |
1486 | |
1487 | -from canonical.launchpad.interfaces import ( |
1488 | +from canonical.launchpad.interfaces.launchpad import ( |
1489 | IAuthServerApplication, |
1490 | - ILaunchBag, |
1491 | - IMailingListApplication, |
1492 | IPrivateApplication, |
1493 | IPrivateMaloneApplication, |
1494 | ) |
1495 | from canonical.launchpad.webapp import LaunchpadXMLRPCView |
1496 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1497 | from lp.code.interfaces.codehosting import ICodehostingApplication |
1498 | from lp.code.interfaces.codeimportscheduler import ( |
1499 | ICodeImportSchedulerApplication, |
1500 | ) |
1501 | +from lp.registry.interfaces.mailinglist import IMailingListApplication |
1502 | from lp.registry.interfaces.person import ISoftwareCenterAgentApplication |
1503 | |
1504 | |
1505 | |
1506 | === modified file 'lib/canonical/launchpad/xmlrpc/authserver.py' |
1507 | --- lib/canonical/launchpad/xmlrpc/authserver.py 2010-10-03 15:30:06 +0000 |
1508 | +++ lib/canonical/launchpad/xmlrpc/authserver.py 2010-11-08 14:57:15 +0000 |
1509 | @@ -12,12 +12,10 @@ |
1510 | from zope.component import getUtility |
1511 | from zope.interface import implements |
1512 | |
1513 | -from canonical.launchpad.interfaces import ( |
1514 | - IAuthServer, |
1515 | - IPersonSet, |
1516 | - ) |
1517 | +from canonical.launchpad.interfaces.authserver import IAuthServer |
1518 | from canonical.launchpad.webapp import LaunchpadXMLRPCView |
1519 | from canonical.launchpad.xmlrpc import faults |
1520 | +from lp.registry.interfaces.person import IPersonSet |
1521 | |
1522 | |
1523 | class AuthServerAPIView(LaunchpadXMLRPCView): |
1524 | |
1525 | === modified file 'lib/canonical/launchpad/xmlrpc/configure.zcml' |
1526 | --- lib/canonical/launchpad/xmlrpc/configure.zcml 2010-10-03 15:30:06 +0000 |
1527 | +++ lib/canonical/launchpad/xmlrpc/configure.zcml 2010-11-08 14:57:15 +0000 |
1528 | @@ -9,7 +9,7 @@ |
1529 | > |
1530 | |
1531 | <securedutility |
1532 | - class="canonical.launchpad.xmlrpc.PrivateApplication" |
1533 | + class="canonical.launchpad.xmlrpc.application.PrivateApplication" |
1534 | provides="canonical.launchpad.interfaces.launchpad.IPrivateApplication"> |
1535 | <allow interface="canonical.launchpad.interfaces.launchpad.IPrivateApplication"/> |
1536 | </securedutility> |
1537 | @@ -23,7 +23,7 @@ |
1538 | <xmlrpc:view |
1539 | for="canonical.launchpad.interfaces.launchpad.IAuthServerApplication" |
1540 | interface="canonical.launchpad.interfaces.authserver.IAuthServer" |
1541 | - class="canonical.launchpad.xmlrpc.AuthServerAPIView" |
1542 | + class="canonical.launchpad.xmlrpc.authserver.AuthServerAPIView" |
1543 | permission="zope.Public" |
1544 | /> |
1545 | |
1546 | @@ -49,7 +49,7 @@ |
1547 | <xmlrpc:view |
1548 | for="lp.code.interfaces.codeimportscheduler.ICodeImportSchedulerApplication" |
1549 | interface="lp.code.interfaces.codeimportscheduler.ICodeImportScheduler" |
1550 | - class="canonical.launchpad.xmlrpc.CodeImportSchedulerAPI" |
1551 | + class="lp.code.xmlrpc.codeimportscheduler.CodeImportSchedulerAPI" |
1552 | permission="zope.Public" |
1553 | /> |
1554 | |
1555 | @@ -62,7 +62,7 @@ |
1556 | <xmlrpc:view |
1557 | for="canonical.launchpad.interfaces.launchpad.IPrivateMaloneApplication" |
1558 | interface="lp.bugs.interfaces.externalbugtracker.IExternalBugTrackerTokenAPI" |
1559 | - class="canonical.launchpad.xmlrpc.ExternalBugTrackerTokenAPI" |
1560 | + class="lp.bugs.xmlrpc.bug.ExternalBugTrackerTokenAPI" |
1561 | permission="zope.Public" |
1562 | /> |
1563 | |
1564 | |
1565 | === modified file 'lib/canonical/launchpad/zcml/launchpad.zcml' |
1566 | --- lib/canonical/launchpad/zcml/launchpad.zcml 2010-10-03 15:30:06 +0000 |
1567 | +++ lib/canonical/launchpad/zcml/launchpad.zcml 2010-11-08 14:57:15 +0000 |
1568 | @@ -367,14 +367,14 @@ |
1569 | <!-- self-test xmlrpc api --> |
1570 | <xmlrpc:view |
1571 | for="canonical.launchpad.webapp.interfaces.ILaunchpadRoot" |
1572 | - interface="canonical.launchpad.xmlrpc.ISelfTest" |
1573 | - class="canonical.launchpad.xmlrpc.SelfTest" |
1574 | + interface="canonical.launchpad.xmlrpc.application.ISelfTest" |
1575 | + class="canonical.launchpad.xmlrpc.application.SelfTest" |
1576 | permission="zope.Public" |
1577 | /> |
1578 | <xmlrpc:view |
1579 | for="canonical.launchpad.interfaces.launchpad.IRosettaApplication" |
1580 | - interface="canonical.launchpad.xmlrpc.IRosettaSelfTest" |
1581 | - class="canonical.launchpad.xmlrpc.RosettaSelfTest" |
1582 | + interface="canonical.launchpad.xmlrpc.application.IRosettaSelfTest" |
1583 | + class="canonical.launchpad.xmlrpc.application.RosettaSelfTest" |
1584 | permission="zope.Public" |
1585 | /> |
1586 | |
1587 | |
1588 | === modified file 'lib/canonical/lazr/feed/feed.py' |
1589 | --- lib/canonical/lazr/feed/feed.py 2010-10-03 15:30:06 +0000 |
1590 | +++ lib/canonical/lazr/feed/feed.py 2010-11-08 14:57:15 +0000 |
1591 | @@ -35,7 +35,7 @@ |
1592 | # XXX: bac 2007-09-20 bug=153795: modules in canonical.lazr should not import |
1593 | # from canonical.launchpad, but we're doing it here as an expediency to get a |
1594 | # working prototype. |
1595 | -from canonical.launchpad.interfaces import ILaunchpadRoot |
1596 | +from canonical.launchpad.webapp.interfaces import ILaunchpadRoot |
1597 | from canonical.launchpad.webapp import ( |
1598 | canonical_url, |
1599 | LaunchpadView, |
1600 | |
1601 | === modified file 'lib/canonical/testing/layers.py' |
1602 | --- lib/canonical/testing/layers.py 2010-11-08 05:22:26 +0000 |
1603 | +++ lib/canonical/testing/layers.py 2010-11-08 14:57:15 +0000 |
1604 | @@ -108,7 +108,8 @@ |
1605 | session_store, |
1606 | ZopelessTransactionManager, |
1607 | ) |
1608 | -from canonical.launchpad.interfaces import IMailBox, IOpenLaunchBag |
1609 | +from canonical.launchpad.interfaces.mailbox import IMailBox |
1610 | +from canonical.launchpad.webapp.interfaces import IOpenLaunchBag |
1611 | from lp.testing import ANONYMOUS, login, logout, is_logged_in |
1612 | import lp.services.mail.stub |
1613 | from lp.services.mail.mailbox import TestMailBox |
1614 | |
1615 | === modified file 'lib/canonical/widgets/announcementdate.py' |
1616 | --- lib/canonical/widgets/announcementdate.py 2010-10-03 15:30:06 +0000 |
1617 | +++ lib/canonical/widgets/announcementdate.py 2010-11-08 14:57:15 +0000 |
1618 | @@ -16,11 +16,11 @@ |
1619 | from zope.schema.vocabulary import SimpleVocabulary, SimpleTerm |
1620 | |
1621 | from canonical.launchpad.webapp.interfaces import IAlwaysSubmittedWidget |
1622 | -from canonical.launchpad.interfaces import IAnnouncement |
1623 | from canonical.launchpad.validators import LaunchpadValidationError |
1624 | from canonical.widgets.itemswidgets import LaunchpadRadioWidget |
1625 | from canonical.widgets.date import DateTimeWidget |
1626 | from canonical.launchpad import _ |
1627 | +from lp.registry.interfaces.announcement import IAnnouncement |
1628 | |
1629 | |
1630 | class IAnnouncementDateWidget(ISimpleInputWidget): |
1631 | |
1632 | === modified file 'lib/canonical/widgets/branch.py' |
1633 | --- lib/canonical/widgets/branch.py 2010-10-03 15:30:06 +0000 |
1634 | +++ lib/canonical/widgets/branch.py 2010-11-08 14:57:15 +0000 |
1635 | @@ -15,7 +15,7 @@ |
1636 | from zope.component import getMultiAdapter, getUtility |
1637 | from zope.schema.vocabulary import SimpleVocabulary, SimpleTerm |
1638 | |
1639 | -from canonical.launchpad.interfaces import ILaunchBag |
1640 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1641 | from canonical.launchpad.webapp import canonical_url |
1642 | from canonical.widgets.itemswidgets import LaunchpadRadioWidget |
1643 | |
1644 | |
1645 | === modified file 'lib/canonical/widgets/bugtask.py' |
1646 | --- lib/canonical/widgets/bugtask.py 2010-10-03 15:30:06 +0000 |
1647 | +++ lib/canonical/widgets/bugtask.py 2010-11-08 14:57:15 +0000 |
1648 | @@ -22,16 +22,20 @@ |
1649 | |
1650 | from canonical.launchpad import _ |
1651 | from lp.services.fields import URIField |
1652 | -from canonical.launchpad.interfaces import ( |
1653 | - IBugWatchSet, IDistributionSet, ILaunchBag, NoBugTrackerFound, |
1654 | - UnrecognizedBugTrackerURL) |
1655 | from canonical.launchpad.webapp import canonical_url |
1656 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1657 | from lp.app.browser.tales import TeamFormatterAPI |
1658 | from canonical.widgets.helpers import get_widget_template |
1659 | from canonical.widgets.itemswidgets import LaunchpadRadioWidget |
1660 | from canonical.widgets.popup import VocabularyPickerWidget |
1661 | from canonical.widgets.textwidgets import StrippedTextWidget, URIWidget |
1662 | from lp.app.errors import NotFoundError, UnexpectedFormData |
1663 | +from lp.bugs.interfaces.bugwatch import ( |
1664 | + IBugWatchSet, |
1665 | + NoBugTrackerFound, |
1666 | + UnrecognizedBugTrackerURL, |
1667 | + ) |
1668 | +from lp.registry.interfaces.distribution import IDistributionSet |
1669 | |
1670 | |
1671 | class BugTaskAssigneeWidget(Widget): |
1672 | |
1673 | === modified file 'lib/canonical/widgets/date.py' |
1674 | --- lib/canonical/widgets/date.py 2010-10-03 15:30:06 +0000 |
1675 | +++ lib/canonical/widgets/date.py 2010-11-08 14:57:15 +0000 |
1676 | @@ -31,7 +31,7 @@ |
1677 | |
1678 | from z3c.ptcompat import ViewPageTemplateFile |
1679 | |
1680 | -from canonical.launchpad.interfaces import ILaunchBag |
1681 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1682 | from canonical.launchpad.validators import LaunchpadValidationError |
1683 | |
1684 | |
1685 | |
1686 | === modified file 'lib/canonical/widgets/launchpadtarget.py' |
1687 | --- lib/canonical/widgets/launchpadtarget.py 2010-10-03 15:30:06 +0000 |
1688 | +++ lib/canonical/widgets/launchpadtarget.py 2010-11-08 14:57:15 +0000 |
1689 | @@ -14,14 +14,17 @@ |
1690 | |
1691 | from z3c.ptcompat import ViewPageTemplateFile |
1692 | |
1693 | -from canonical.launchpad.interfaces import ( |
1694 | - IDistribution, IDistributionSourcePackage, ILaunchpadCelebrities, |
1695 | - IProduct) |
1696 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
1697 | from canonical.launchpad.validators import LaunchpadValidationError |
1698 | from canonical.launchpad.webapp.interfaces import ( |
1699 | IMultiLineWidgetLayout, IAlwaysSubmittedWidget) |
1700 | from canonical.widgets.itemswidgets import LaunchpadDropdownWidget |
1701 | from lp.app.errors import NotFoundError, UnexpectedFormData |
1702 | +from lp.registry.interfaces.distribution import IDistribution |
1703 | +from lp.registry.interfaces.distributionsourcepackage import ( |
1704 | + IDistributionSourcePackage, |
1705 | + ) |
1706 | +from lp.registry.interfaces.product import IProduct |
1707 | |
1708 | |
1709 | class LaunchpadTargetWidget(BrowserWidget, InputWidget): |
1710 | |
1711 | === modified file 'lib/canonical/widgets/owner.py' |
1712 | --- lib/canonical/widgets/owner.py 2010-10-03 15:30:06 +0000 |
1713 | +++ lib/canonical/widgets/owner.py 2010-11-08 14:57:15 +0000 |
1714 | @@ -8,7 +8,7 @@ |
1715 | from zope.app.form.interfaces import IInputWidget |
1716 | from zope.app.form.browser.interfaces import IBrowserWidget |
1717 | |
1718 | -from canonical.launchpad.interfaces import ILaunchBag |
1719 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1720 | |
1721 | class RequestWidget(object): |
1722 | '''A widget that sets itself to a value calculated from request |
1723 | |
1724 | === modified file 'lib/canonical/widgets/password.py' |
1725 | --- lib/canonical/widgets/password.py 2010-10-03 15:30:06 +0000 |
1726 | +++ lib/canonical/widgets/password.py 2010-11-08 14:57:15 +0000 |
1727 | @@ -19,7 +19,7 @@ |
1728 | from z3c.ptcompat import ViewPageTemplateFile |
1729 | |
1730 | from canonical.launchpad import _ |
1731 | -from canonical.launchpad.interfaces import IPasswordEncryptor |
1732 | +from canonical.launchpad.interfaces.launchpad import IPasswordEncryptor |
1733 | from canonical.launchpad.webapp.interfaces import IMultiLineWidgetLayout |
1734 | |
1735 | |
1736 | |
1737 | === modified file 'lib/canonical/widgets/product.py' |
1738 | --- lib/canonical/widgets/product.py 2010-10-03 15:30:06 +0000 |
1739 | +++ lib/canonical/widgets/product.py 2010-11-08 14:57:15 +0000 |
1740 | @@ -30,8 +30,9 @@ |
1741 | |
1742 | from canonical.launchpad.browser.widgets import DescriptionWidget |
1743 | from lp.services.fields import StrippedTextLine |
1744 | -from canonical.launchpad.interfaces import ( |
1745 | - BugTrackerType, IBugTracker, IBugTrackerSet, ILaunchBag) |
1746 | +from lp.bugs.interfaces.bugtracker import ( |
1747 | + BugTrackerType, IBugTracker, IBugTrackerSet) |
1748 | +from canonical.launchpad.webapp.interfaces import ILaunchBag |
1749 | from canonical.launchpad.validators import LaunchpadValidationError |
1750 | from canonical.launchpad.validators.email import email_validator |
1751 | from canonical.launchpad.webapp import canonical_url |
1752 | |
1753 | === modified file 'lib/lp/bugs/configure.zcml' |
1754 | --- lib/lp/bugs/configure.zcml 2010-11-03 12:24:24 +0000 |
1755 | +++ lib/lp/bugs/configure.zcml 2010-11-08 14:57:15 +0000 |
1756 | @@ -130,7 +130,7 @@ |
1757 | <xmlrpc:view |
1758 | for="lp.bugs.interfaces.malone.IMaloneApplication" |
1759 | methods="filebug" |
1760 | - class="canonical.launchpad.xmlrpc.FileBugAPI" |
1761 | + class="lp.bugs.xmlrpc.bug.FileBugAPI" |
1762 | permission="launchpad.AnyPerson"/> |
1763 | |
1764 | <!-- Global Malone portlets --> |
1765 | |
1766 | === modified file 'lib/lp/bugs/interfaces/__init__.py' |
1767 | --- lib/lp/bugs/interfaces/__init__.py 2010-08-20 20:31:18 +0000 |
1768 | +++ lib/lp/bugs/interfaces/__init__.py 2010-11-08 14:57:15 +0000 |
1769 | @@ -1,9 +1,4 @@ |
1770 | # Copyright 2009 Canonical Ltd. This software is licensed under the |
1771 | # GNU Affero General Public License version 3 (see the file LICENSE). |
1772 | |
1773 | -# XXX Gavin Panella bug=384831 2009-06-08 |
1774 | -# This ensures that interfaces are loaded in the correct order. Things |
1775 | -# otherwise break. |
1776 | -import canonical.launchpad.interfaces |
1777 | - |
1778 | |
1779 | |
1780 | === modified file 'lib/lp/bugs/tests/bugzilla-xmlrpc-transport.txt' |
1781 | --- lib/lp/bugs/tests/bugzilla-xmlrpc-transport.txt 2009-12-23 10:49:55 +0000 |
1782 | +++ lib/lp/bugs/tests/bugzilla-xmlrpc-transport.txt 2010-11-08 14:57:15 +0000 |
1783 | @@ -73,7 +73,7 @@ |
1784 | |
1785 | We can use the internal XML-RPC API to generate such a token. |
1786 | |
1787 | - >>> from canonical.launchpad.xmlrpc import ExternalBugTrackerTokenAPI |
1788 | + >>> from lp.bugs.xmlrpc.bug import ExternalBugTrackerTokenAPI |
1789 | >>> token_api = ExternalBugTrackerTokenAPI(None, None) |
1790 | >>> token_text = token_api.newBugTrackerToken() |
1791 | |
1792 | |
1793 | === modified file 'lib/lp/bugs/tests/externalbugtracker.py' |
1794 | --- lib/lp/bugs/tests/externalbugtracker.py 2010-10-15 11:21:00 +0000 |
1795 | +++ lib/lp/bugs/tests/externalbugtracker.py 2010-11-08 14:57:15 +0000 |
1796 | @@ -38,7 +38,7 @@ |
1797 | ) |
1798 | from canonical.launchpad.interfaces.logintoken import ILoginTokenSet |
1799 | from canonical.launchpad.testing.systemdocs import ordered_dict_as_string |
1800 | -from canonical.launchpad.xmlrpc import ExternalBugTrackerTokenAPI |
1801 | +from lp.bugs.xmlrpc.bug import ExternalBugTrackerTokenAPI |
1802 | from canonical.testing.layers import LaunchpadZopelessLayer |
1803 | from lp.bugs.externalbugtracker import ( |
1804 | BATCH_SIZE_UNLIMITED, |
1805 | |
1806 | === modified file 'lib/lp/code/configure.zcml' |
1807 | --- lib/lp/code/configure.zcml 2010-10-18 03:39:28 +0000 |
1808 | +++ lib/lp/code/configure.zcml 2010-11-08 14:57:15 +0000 |
1809 | @@ -191,13 +191,13 @@ |
1810 | |
1811 | <xmlrpc:view |
1812 | for="canonical.launchpad.interfaces.launchpad.IBazaarApplication" |
1813 | - interface="canonical.launchpad.xmlrpc.IBranchSetAPI" |
1814 | - class="canonical.launchpad.xmlrpc.BranchSetAPI" |
1815 | + interface="lp.code.xmlrpc.branch.IBranchSetAPI" |
1816 | + class="lp.code.xmlrpc.branch.BranchSetAPI" |
1817 | permission="launchpad.AnyPerson"/> |
1818 | <xmlrpc:view |
1819 | for="canonical.launchpad.interfaces.launchpad.IBazaarApplication" |
1820 | - interface="canonical.launchpad.xmlrpc.IPublicCodehostingAPI" |
1821 | - class="canonical.launchpad.xmlrpc.PublicCodehostingAPI" |
1822 | + interface="lp.code.xmlrpc.branch.IPublicCodehostingAPI" |
1823 | + class="lp.code.xmlrpc.branch.PublicCodehostingAPI" |
1824 | permission="zope.Public"/> |
1825 | |
1826 | <!-- Branch Merge Proposal --> |
1827 | |
1828 | === modified file 'lib/lp/registry/interfaces/commercialsubscription.py' |
1829 | --- lib/lp/registry/interfaces/commercialsubscription.py 2010-08-20 20:31:18 +0000 |
1830 | +++ lib/lp/registry/interfaces/commercialsubscription.py 2010-11-08 14:57:15 +0000 |
1831 | @@ -46,7 +46,7 @@ |
1832 | required=True, |
1833 | readonly=True, |
1834 | vocabulary='Product', |
1835 | - # Really IProduct. Set properly below. |
1836 | + # Really IProduct. Set properly in lp/registry/interfaces/product.py |
1837 | schema=Interface, |
1838 | description=_( |
1839 | "Project for which this commercial subscription is " |
1840 | @@ -102,8 +102,3 @@ |
1841 | title=_('Active'), |
1842 | readonly=True, |
1843 | description=_("Whether this subscription is active."))) |
1844 | - |
1845 | - |
1846 | -# Fix circular dependency issues. |
1847 | -from lp.registry.interfaces.product import IProduct |
1848 | -ICommercialSubscription['product'].schema = IProduct |
1849 | |
1850 | === modified file 'lib/lp/registry/interfaces/product.py' |
1851 | --- lib/lp/registry/interfaces/product.py 2010-11-02 20:10:56 +0000 |
1852 | +++ lib/lp/registry/interfaces/product.py 2010-11-08 14:57:15 +0000 |
1853 | @@ -1084,3 +1084,5 @@ |
1854 | from lp.registry.interfaces.distributionsourcepackage import ( |
1855 | IDistributionSourcePackage) |
1856 | IDistributionSourcePackage['upstream_product'].schema = IProduct |
1857 | + |
1858 | +ICommercialSubscription['product'].schema = IProduct |
1859 | |
1860 | === modified file 'lib/lp/services/features/browser/configure.zcml' |
1861 | --- lib/lp/services/features/browser/configure.zcml 2010-09-29 06:47:11 +0000 |
1862 | +++ lib/lp/services/features/browser/configure.zcml 2010-11-08 14:57:15 +0000 |
1863 | @@ -16,7 +16,7 @@ |
1864 | is for admins only. |
1865 | --> |
1866 | <browser:page |
1867 | - for="canonical.launchpad.interfaces.ILaunchpadRoot" |
1868 | + for="canonical.launchpad.webapp.interfaces.ILaunchpadRoot" |
1869 | class="lp.services.features.browser.edit.FeatureControlView" |
1870 | name="+feature-rules" |
1871 | permission="launchpad.Edit" |
1872 | |
1873 | === modified file 'scripts/bug-export.py' |
1874 | --- scripts/bug-export.py 2010-10-03 15:30:06 +0000 |
1875 | +++ scripts/bug-export.py 2010-11-08 14:57:15 +0000 |
1876 | @@ -11,7 +11,7 @@ |
1877 | |
1878 | from zope.component import getUtility |
1879 | from canonical.lp import initZopeless |
1880 | -from canonical.launchpad.interfaces import IProductSet |
1881 | +from lp.registry.interfaces.product import IProductSet |
1882 | from canonical.launchpad.scripts import execute_zcml_for_scripts |
1883 | |
1884 | from lp.bugs.scripts.bugexport import export_bugtasks |
1885 | |
1886 | === modified file 'scripts/bug-import.py' |
1887 | --- scripts/bug-import.py 2010-10-03 15:30:06 +0000 |
1888 | +++ scripts/bug-import.py 2010-11-08 14:57:15 +0000 |
1889 | @@ -10,7 +10,7 @@ |
1890 | |
1891 | from zope.component import getUtility |
1892 | from canonical.config import config |
1893 | -from canonical.launchpad.interfaces import IProductSet |
1894 | +from lp.registry.interfaces.product import IProductSet |
1895 | |
1896 | from lp.bugs.scripts.bugimport import BugImporter |
1897 | from lp.services.scripts.base import LaunchpadScript |
1898 | |
1899 | === modified file 'scripts/cache-country-mirrors.py' |
1900 | --- scripts/cache-country-mirrors.py 2010-10-03 15:30:06 +0000 |
1901 | +++ scripts/cache-country-mirrors.py 2010-11-08 14:57:15 +0000 |
1902 | @@ -19,10 +19,11 @@ |
1903 | |
1904 | from zope.component import getUtility |
1905 | |
1906 | +from lp.registry.interfaces.distributionmirror import ( |
1907 | + IDistributionMirrorSet, MirrorContent) |
1908 | from lp.services.scripts.base import ( |
1909 | LaunchpadScript, LaunchpadScriptFailure) |
1910 | -from canonical.launchpad.interfaces import ( |
1911 | - ICountrySet, IDistributionMirrorSet, MirrorContent) |
1912 | +from lp.services.worlddata.interfaces.country import ICountrySet |
1913 | |
1914 | |
1915 | class CacheCountryMirrors(LaunchpadScript): |
1916 | |
1917 | === modified file 'scripts/close-account.py' |
1918 | --- scripts/close-account.py 2010-10-03 15:30:06 +0000 |
1919 | +++ scripts/close-account.py 2010-11-08 14:57:15 +0000 |
1920 | @@ -15,9 +15,9 @@ |
1921 | |
1922 | from canonical.database.sqlbase import connect, sqlvalues |
1923 | from canonical.launchpad.scripts import db_options, logger_options, logger |
1924 | -from canonical.launchpad.interfaces import ( |
1925 | - PersonCreationRationale, QuestionStatus) |
1926 | -from canonical.launchpad.interfaces.account import AccountStatus |
1927 | +from lp.answers.interfaces.questionenums import QuestionStatus |
1928 | +from lp.registry.interfaces.person import PersonCreationRationale |
1929 | + |
1930 | |
1931 | def close_account(con, log, username): |
1932 | """Close a person's account. |
1933 | |
1934 | === modified file 'scripts/convert-person-to-team.py' |
1935 | --- scripts/convert-person-to-team.py 2010-10-03 15:30:06 +0000 |
1936 | +++ scripts/convert-person-to-team.py 2010-11-08 14:57:15 +0000 |
1937 | @@ -15,7 +15,8 @@ |
1938 | |
1939 | from lp.services.scripts.base import ( |
1940 | LaunchpadScript, LaunchpadScriptFailure) |
1941 | -from canonical.launchpad.interfaces import AccountStatus, IPersonSet |
1942 | +from canonical.launchpad.interfaces.account import AccountStatus |
1943 | +from lp.registry.interfaces.person import IPersonSet |
1944 | |
1945 | |
1946 | class ConvertPersonToTeamScript(LaunchpadScript): |
1947 | |
1948 | === modified file 'scripts/ftpmaster-tools/initialise-from-parent.py' |
1949 | --- scripts/ftpmaster-tools/initialise-from-parent.py 2010-10-03 15:30:06 +0000 |
1950 | +++ scripts/ftpmaster-tools/initialise-from-parent.py 2010-11-08 14:57:15 +0000 |
1951 | @@ -14,7 +14,7 @@ |
1952 | from contrib.glock import GlobalLock |
1953 | |
1954 | from canonical.config import config |
1955 | -from canonical.launchpad.interfaces import IDistributionSet |
1956 | +from lp.registry.interfaces.distribution import IDistributionSet |
1957 | from canonical.launchpad.scripts import ( |
1958 | execute_zcml_for_scripts, logger, logger_options) |
1959 | from canonical.lp import initZopeless |
1960 | |
1961 | === modified file 'scripts/ftpmaster-tools/remove-package.py' |
1962 | --- scripts/ftpmaster-tools/remove-package.py 2010-10-03 15:30:06 +0000 |
1963 | +++ scripts/ftpmaster-tools/remove-package.py 2010-11-08 14:57:15 +0000 |
1964 | @@ -25,7 +25,7 @@ |
1965 | from canonical.database.constants import UTC_NOW |
1966 | from canonical.launchpad.database import (BinaryPackagePublishingHistory, |
1967 | SourcePackagePublishingHistory) |
1968 | -from canonical.launchpad.interfaces import IDistributionSet |
1969 | +from lp.registry.interfaces.distribution import IDistributionSet |
1970 | from canonical.launchpad.scripts import (execute_zcml_for_scripts, |
1971 | logger, logger_options) |
1972 | from canonical.lp import initZopeless |
1973 | |
1974 | === modified file 'scripts/ftpmaster-tools/sync-source.py' |
1975 | --- scripts/ftpmaster-tools/sync-source.py 2010-10-20 13:33:24 +0000 |
1976 | +++ scripts/ftpmaster-tools/sync-source.py 2010-11-08 14:57:15 +0000 |
1977 | @@ -40,10 +40,6 @@ |
1978 | cursor, |
1979 | sqlvalues, |
1980 | ) |
1981 | -from canonical.launchpad.interfaces import ( |
1982 | - IDistributionSet, |
1983 | - IPersonSet, |
1984 | - ) |
1985 | from canonical.launchpad.scripts import ( |
1986 | execute_zcml_for_scripts, |
1987 | logger, |
1988 | @@ -55,6 +51,8 @@ |
1989 | DpkgSourceError, |
1990 | extract_dpkg_source, |
1991 | ) |
1992 | +from lp.registry.interfaces.distribution import IDistributionSet |
1993 | +from lp.registry.interfaces.person import IPersonSet |
1994 | from lp.registry.interfaces.pocket import PackagePublishingPocket |
1995 | from lp.soyuz.enums import PackagePublishingStatus |
1996 | from lp.soyuz.scripts.ftpmaster import ( |
1997 | |
1998 | === modified file 'scripts/migrate-bugzilla-initialcontacts.py' |
1999 | --- scripts/migrate-bugzilla-initialcontacts.py 2010-10-03 15:30:06 +0000 |
2000 | +++ scripts/migrate-bugzilla-initialcontacts.py 2010-11-08 14:57:15 +0000 |
2001 | @@ -4,7 +4,6 @@ |
2002 | # GNU Affero General Public License version 3 (see the file LICENSE). |
2003 | |
2004 | import logging |
2005 | -import re |
2006 | import MySQLdb |
2007 | |
2008 | import _pythonpath |
2009 | @@ -13,9 +12,10 @@ |
2010 | |
2011 | from canonical.lp import initZopeless |
2012 | from canonical.launchpad.scripts import execute_zcml_for_scripts |
2013 | -from canonical.launchpad.interfaces import ( |
2014 | - IPersonSet, IEmailAddressSet, ILaunchpadCelebrities) |
2015 | +from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet |
2016 | +from canonical.launchpad.interfaces.launchpad import ILaunchpadCelebrities |
2017 | from lp.app.errors import NotFoundError |
2018 | +from lp.registry.interfaces.person import IPersonSet |
2019 | |
2020 | |
2021 | execute_zcml_for_scripts() |
2022 | |
2023 | === modified file 'scripts/mlist-sync.py' |
2024 | --- scripts/mlist-sync.py 2010-10-07 17:37:01 +0000 |
2025 | +++ scripts/mlist-sync.py 2010-11-08 14:57:15 +0000 |
2026 | @@ -37,8 +37,9 @@ |
2027 | from zope.security.proxy import removeSecurityProxy |
2028 | |
2029 | from canonical.config import config |
2030 | -from canonical.launchpad.interfaces import ( |
2031 | - IEmailAddressSet, IMailingListSet, IPersonSet) |
2032 | +from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet |
2033 | +from lp.registry.interfaces.mailinglist import IMailingListSet |
2034 | +from lp.registry.interfaces.person import IPersonSet |
2035 | from lp.services.mailman.config import configure_prefix |
2036 | from lp.services.scripts.base import LaunchpadScript |
2037 | |
2038 | |
2039 | === modified file 'scripts/rosetta/check-distroseries-translations-diffs.py' |
2040 | --- scripts/rosetta/check-distroseries-translations-diffs.py 2010-10-03 15:30:06 +0000 |
2041 | +++ scripts/rosetta/check-distroseries-translations-diffs.py 2010-11-08 14:57:15 +0000 |
2042 | @@ -10,7 +10,7 @@ |
2043 | from zope.component import getUtility |
2044 | |
2045 | from canonical.lp import initZopeless |
2046 | -from canonical.launchpad.interfaces import IDistributionSet |
2047 | +from lp.registry.interfaces.distribution import IDistributionSet |
2048 | from canonical.launchpad.scripts import execute_zcml_for_scripts |
2049 | from canonical.launchpad.scripts import logger, logger_options |
2050 | |
2051 | |
2052 | === modified file 'utilities/make-lp-user' |
2053 | --- utilities/make-lp-user 2010-10-03 15:30:06 +0000 |
2054 | +++ utilities/make-lp-user 2010-11-08 14:57:15 +0000 |
2055 | @@ -43,14 +43,12 @@ |
2056 | |
2057 | from zope.component import getUtility |
2058 | |
2059 | -from canonical.launchpad.interfaces import ( |
2060 | - IPersonSet, |
2061 | - ISSHKeySet, |
2062 | - TeamMembershipStatus, |
2063 | - ) |
2064 | from canonical.launchpad.interfaces.gpghandler import IGPGHandler |
2065 | from canonical.launchpad.scripts import execute_zcml_for_scripts |
2066 | from lp.registry.interfaces.gpg import GPGKeyAlgorithm, IGPGKeySet |
2067 | +from lp.registry.interfaces.person import IPersonSet |
2068 | +from lp.registry.interfaces.ssh import ISSHKeySet |
2069 | +from lp.registry.interfaces.teammembership import TeamMembershipStatus |
2070 | from lp.testing.factory import LaunchpadObjectFactory |
2071 | |
2072 | # Shut up, pyflakes. |