Forum OpenACS Development: Re: APM auto-mount feature

Collapse
Posted by Don Baccus on
Lars ... when adding the capability to autogenerate trees of mounted acs-subsite packages to the "populate" package I've been working on, I ran into an issue that will need addressing if you're going to do the above work.

acs-subsite, at least, expects its "post-intantiate" proc to be called AFTER MOUNTING, not simply after instantiation.  It fails if you call the apm package installation proc, you have to call the site node package's install and mount proc.

We really need both "post-instantiate" and "post-mount" procs, as these are separate actions and packages may reasonably want  to execute certain code only after the package is mounted.  acs-subsite, for instance, finds its parent subsite in order to properly construct the composition relation that relates members of the just-mounted subsite to the members of the enclosing subsite.

Not many packages have post-instantiate procs so there won't be much package-whacking needed if you write the code to call both procs at the appropriate time.  If you do so, I volunteer to fix acs-subsite at least (just as soon as you get done) and maybe the rest of the packages, too (which might not require any work).