[Tickets #6559] Re: DIMP should fail gracefully if IMP not installed
bugs at horde.org
bugs at horde.org
Wed Apr 2 18:26:55 UTC 2008
DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.
Ticket URL: http://bugs.horde.org/ticket/6559
-----------------------------------------------------------------------
Ticket | 6559
Updated By | php at ideacode.com
Summary | DIMP should fail gracefully if IMP not installed
Queue | DIMP
Version | HEAD
Type | Bug
State | Not A Bug
Priority | 1. Low
Milestone |
Patch |
Owners |
+New Attachment | issue6559.diff
-----------------------------------------------------------------------
php at ideacode.com (2008-04-02 14:26) wrote:
> I appreciate the thought that the application should degrade
> gracefully even if random files are deleted from it - which is along
> the same lines as saying it should function without its requirements
> installed - but there's, to be buzzwordy about it, low ROI there for
> an open source project.
A requirement in the documentation is only as good as its enforcement in
the software. If IMP is a required module, then I should not be able to
run a Horde framework with only nag, mnemo, whups, and wicked. But I can,
which demonstrates a discrepancy between what the documentation states are
requirements and what the software states are requirements. In the
presence of such a discrepancy, the software's view wins.
> And I'm sorry, but how is IMP not a requirement for DIMP?
Foremost because the software doesn't enforce the requirement. I
recognize the documentation states that IMP is a requirement, and that's
great, but the reality is that Horde (the collection) is a complex
organism, comprised of many different modules all with differing
requirements and implementation strategies, constrained by a loose hegemony
armed with guidelines designed to move everyone toward a common goal.
Recognizing that complexity, the purpose of this request -- as low a
priority as it may be -- is to provide a product that remains strong in the
face of users' errors.
And since I'm the type of guy to put my mouth where my bug reports are,
here's a patch. This patch adds "requirement" support to configuration XML
documents. The completely optional <requires> container lists the
mandatory applications that the given configuration needs. DIMP, for
example, might read:
<requires>
<require app="imp" />
<require extension="imap" />
</requires>
All requirements must be satisfied, or a warning is emitted on the
configuration page. In this case, both the imp application and the PHP
imap extension must be installed and loaded. The parser also supports a
version attribute for the requirement element, but I do not immediately
know how to get the version information consistently from the registry or
from an extension, so that's left as an exercise for the reader.
More information about the bugs
mailing list