Can not register multiple webservice modules if one imports the other

Bug #369888 reported by Michael Nelson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lazr.restful
Triaged
Low
Unassigned

Bug Description

The situation I had was this: LP just registers one module "canonical.launchpad.interfaces", but since we're not meant to add new interfaces to interfaces/__init__.py, I tried adding a second module registration:

   <webservice:register module="canonical.launchpad.interfaces.archivesubscriber" />

for my new(ish) interface that is not listed in interfaces/__init__.py.

This then resulted in error:

zope.configuration.config.ConfigurationConflictError: Conflicting configuration actions

Apparently this is because the webservice adapter generator is going through archivesubscriber and trying to generate adapters for the interfaces imported there, which have interfaces from the first module declaration.

Revision history for this message
Francis J. Lacoste (flacoste) wrote :

There is an easy workaround is to not import the interfaces themselves but only the module that define them and use module.Interface in the new module.

Changed in lazr.restful:
importance: Undecided → Low
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.