Skip to Content.
Sympa Menu

sm-grimoire - [SM-Grimoire] Generalized Depends (WAS: Version Dependancy)

sm-grimoire AT lists.ibiblio.org

Subject: Discussion of Spells and Grimoire items

List archive

Chronological Thread  
  • From: Dufflebunk <dufflebunk AT dufflebunk.homeip.net>
  • To: Arwed von Merkatz <v.merkatz AT gmx.net>
  • Cc: Grimoire <sm-grimoire AT lists.ibiblio.org>
  • Subject: [SM-Grimoire] Generalized Depends (WAS: Version Dependancy)
  • Date: Mon, 23 Jun 2003 22:38:06 -0000

My objection is that optional_requires is an oxymoron.
There is a potential problem with generalising depends to merge requires
with depends. A requires lookup is much more expensive operation. Not a
big deal, just look for the spell first, then a provides. There is
another problem of name collisions between spells and provides. Again,
not very serious, I think there have been no cases of that yet.

We could extend the spell indexing to also create a provides index which
would speed the checking up. It would be updated when 'gaze reindex' is
run and would slow down the reindexing (and thus the end of an update) a
little, probably not more than a couple of seconds though, I'm not sure.

Any thoughts?

On Mon, 2003-06-23 at 18:13, Arwed von Merkatz wrote:
> On Mon, Jun 23, 2003 at 03:10:17PM -0700, Eric Sandall wrote:
> > Jason Flatt said:
> > > I think that implementing optional_requires is far more useful than
> > > versioning. There. I said it. Happy? :^)
> >
> > I am very much agreed. Is optional_requires hard to implement? Shouldn't
> > it be relatively easy; just use optional_depends (I'm not a bash hacker,
> > so my opinion is uneducated)?
>
> While we're on that issue, shouldn't we just drop the difference between
> depends and requires? Just replace everything by depends and
> optional_depends and have sorcery look for a provides when the
> dependency isn't known as a spell.
>
> Another thing about requires/provides, how about having a file
> /var/state/sorcery/provides that lists all spells that 'provide'
> something with the services they provide? With new entries added when a
> spell with provides is installed. That would make using provides much
> faster than it is now (takes quite some time to search all grimoires for
> a specific required service).





Archive powered by MHonArc 2.6.24.

Top of Page