Skip Menu |

This queue is for tickets about the MooseX-POE CPAN distribution.

Report information
The Basics
Id: 43423
Status: resolved
Priority: 0/
Queue: MooseX-POE

People
Owner: Nobody in particular
Requestors: frank.mayer [...] knapp.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: bug or intentional omission in MooseX::POE::Meta::Instance?
Date: Thu, 19 Feb 2009 11:09:26 +0100
To: bug-moosex-poe [...] rt.cpan.org
From: Frank Mayer <frank.mayer [...] knapp.com>
Hello, I like your Moose-Extension very much and think it simplifies using POE very much. I found, however, that I could not use the "predicate"- and "clearer"-options with MooseX::POE as I could with plain Moose: the attributes did not get cleared at all After some searching, I think I found out why: You seem to overwrite is_slot_initialized from Class::MOP... to use the $instance->{heap]{$slot_name} instead of $instance->{$slot_name}, but you did not implement deinitialize_slot accordingly. For starters, I have added a deinitialize_slot function to my installation of MooseX::POE::Meta::Instance, and things seem to work as expected now. Did you omit deinitialize_slot intentionally, and if so: what's the motivation for this? What other functions did you not implement? Best Regards, Frank Mayer
On Thu Feb 19 05:51:57 2009, frank.mayer@knapp.com wrote: Show quoted text
> Hello, > > I like your Moose-Extension very much and think it simplifies using POE > very much. > > I found, however, that I could not use the "predicate"- and > "clearer"-options with MooseX::POE as I could with plain Moose: the > attributes did not get cleared at all > After some searching, I think I found out why: > You seem to overwrite > is_slot_initialized > from Class::MOP... to use the $instance->{heap]{$slot_name} instead of > $instance->{$slot_name}, but you did not implement > deinitialize_slot > accordingly. > > For starters, I have added a deinitialize_slot function to my
installation Show quoted text
> of MooseX::POE::Meta::Instance, and things seem to work as expected now. > > Did you omit deinitialize_slot intentionally, and if so: what's the > motivation for this? > What other functions did you not implement? > > Best Regards, > Frank Mayer
[NOTE: I've deleted the two duplicates of this ticket] I have no clue what other functions I didn't implement. MooseX::POE was originally a proof of concept and based on a conversation had with Yuval Kogman, and has grown a little organically since then as others like yourself have found it useful and adopted it. Part of that initial discussion was making Moose objects that read from the POE $_[HEAP] so they could integrate better with existing POE practices, hence the overriding of some of the core Moose functions. The source is on github (http://github.com/perigrin/moosex-poe/tree/master) specifically to make it easier for others to clone and patch changes in so I can accept them back into the core. If you can provide me tests that fail I'll take a look at attempting to fix them, if you can provide me a patch that fixes them I'll happily apply it. If you provide documentation, I'll even buy you a drink next time we're in some establishment that offers such things. -Chris
Please re-open with failing tests.