#2899: Plugin load order
----------------------------------+-----------------------------------------
Reporter: [EMAIL PROTECTED] | Owner: cmlenz
Type: defect | Status: closed
Priority: high | Milestone: 0.10
Component: general | Version: 0.9.3
Severity: major | Resolution: fixed
Keywords: |
----------------------------------+-----------------------------------------
Comment (by [EMAIL PROTECTED]):
Hi, just wanted to record an extra complicated case, I'm not going to
reopen the ticket because I have at least two work arounds.
I have some plugins that provide Web Admin interfaces but of course they
don't *need* the web admin interface to be installed in order to work, the
config can be manually edited in the config file.
So, I surrounded the import of IAdminPageProvider with a try except block
and if it is missing define the missing interface manually to keep the
Python interpreter happy, even though the web admin code will never be
invoked (which I don't care about).
However, in setup.py I don't want to mark Web Admin as *required* any more
because it isn't *required*. Instead I list it in extras_require.
Everything seems to be fine, except that now the load order bug is back.
The two work arounds I referred to are the naming hack (name the plugin
after webadmin in the alphabet to manually affect the load order) or by
splitting out the web admin code into yet another plugin. So long as
communication between the non-web admin plugin and the web admin plugin
happens via a consistent API there shouldn't be a problem, but it's a bit
messy.
--
Ticket URL: <http://trac.edgewall.org/ticket/2899>
The Trac Project <http://trac.edgewall.com/>
_______________________________________________
Trac-Tickets mailing list
[email protected]
http://lists.edgewall.com/mailman/listinfo/trac-tickets