buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Victor Hugo Borja" <>
Subject Re: 'super' doesn't invoke super method under drb?
Date Tue, 21 Oct 2008 03:14:25 GMT
On Mon, Oct 20, 2008 at 5:44 AM, Ittay Dror <> wrote:

> I have a class that overrides invoke_prerequisites, and at the end calls
> 'super'. Without drb all works fine. When used under drb, it is as if the
> super method is not called (trace doesn't show the tasks being invoked and
> even a print debug in rake isn't printed). Trying to get the method via
> self.class.superclass.instance_method returns the right method). Any hints
> as to why this might happen?

I suppose that was because the first implementation of
DRbApplication#clear_invoked_tasks used to clear the tasks hash and recreate
each of then with something like .. original_task.class.define_task(...), so
if a task had been extended with a module or set some ivars, that
information was being lost.
The current implementation just reenables the task allowing it to execute
again, and restores the original task prerequisites/actions. See the
code/specs if you need more details.

The current drb impl, recreates only tasks created by buildr itself, those
tasks created by your buildfile are just reenabled with clear_invoked_tasks.


Quaerendo invenietis.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message