Skip Menu |

This queue is for tickets about the Module-Pluggable CPAN distribution.

Report information
The Basics
Id: 90317
Status: resolved
Priority: 0/
Queue: Module-Pluggable

People
Owner: Nobody in particular
Requestors: djerius [...] cpan.org
Cc: haarg [...] haarg.org
AdminCc:

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



Subject: fatpack'ed binaries don't find packed plugins
App::FatPacker uses hooks in @INC to perform its magic. Unfortunately Module::Pluggable doesn't pay attention to those, so fat packed plugins won't be found. Attached is an archive which exhibits the (mis?)behavior. % perl tfp required tfp::plugin required tfp::plugin required tfp::plugin % perl packed/tfp (I'm not quite sure why the plugin is required three times, but that's another mystery). It'd be downright fabulous if hooks in @INC would be processed. Thanks! Diab
Subject: tfp.zip
Download tfp.zip
application/zip 10k

Message body not shown because it is not plain text.

On Tue Nov 12 17:46:09 2013, DJERIUS wrote: Show quoted text
> App::FatPacker uses hooks in @INC to perform its magic. Unfortunately > Module::Pluggable doesn't pay attention to those, so fat packed > plugins won't be found.
After further thought this is more complicated than I first thought. The API for hooks doesn't have a means of querying the hook for the modules it can provide; it only responds to fully specified module file name. One way around this would be for the hook to be an object with a defined method for querying module names. That obviously requires cooperation from App::FatPacker. If I can arrive at an API that seems logical, would you be interested in an implementation (dependent of course on getting the other parties approval)? Thanks, Diab
On Wed Nov 13 11:38:09 2013, DJERIUS wrote: Show quoted text
> One way around this would be for the hook to be an object with a > defined method for querying module names. That obviously requires > cooperation from App::FatPacker. > > If I can arrive at an API that seems logical, would you be interested > in an implementation (dependent of course on getting the other parties > approval)?
See https://rt.cpan.org/Ticket/Display.html?id=90335
An attempt at making this work https://github.com/simonwistow/Module-Pluggable/commit/755b7837569f14acb4bb288672979bcef99915b7 however it requires that the packed script changes my %fatpacked; to our %fatpacked; On Wed Nov 13 11:47:17 2013, DJERIUS wrote: Show quoted text
> On Wed Nov 13 11:38:09 2013, DJERIUS wrote:
> > One way around this would be for the hook to be an object with a > > defined method for querying module names. That obviously requires > > cooperation from App::FatPacker. > > > > If I can arrive at an API that seems logical, would you be interested > > in an implementation (dependent of course on getting the other parties > > approval)?
> > See https://rt.cpan.org/Ticket/Display.html?id=90335
On Thu Nov 14 07:20:00 2013, SIMONW wrote: Show quoted text
> An attempt at making this work > > https://github.com/simonwistow/Module- > Pluggable/commit/755b7837569f14acb4bb288672979bcef99915b7 > > however it requires that the packed script changes my %fatpacked; to > our %fatpacked; > > On Wed Nov 13 11:47:17 2013, DJERIUS wrote:
> > On Wed Nov 13 11:38:09 2013, DJERIUS wrote:
> > > One way around this would be for the hook to be an object with a > > > defined method for querying module names. That obviously requires > > > cooperation from App::FatPacker. > > > > > > If I can arrive at an API that seems logical, would you be > > > interested > > > in an implementation (dependent of course on getting the other > > > parties > > > approval)?
> > > > See https://rt.cpan.org/Ticket/Display.html?id=90335
My latest take on this is here: https://github.com/djerius/Module-Pluggable This includes tests. I've tested it under perls 5.6.2, 5.8.9, 5.10.1, 5.14.2, 5.16.2, 5.18.0. It works with the modifications to App::FatPacker here: https://github.com/djerius/App-FatPacker
I've released a new version of App::FatPacker using djerius's patch.
On Wed Nov 27 16:50:21 2013, haarg wrote: Show quoted text
> I've released a new version of App::FatPacker using djerius's patch.
I've verified that my patched version of Module::Pluggable works with the latest released version of App::FatPacker.
On Mon Dec 16 15:11:25 2013, DJERIUS wrote: Show quoted text
> On Wed Nov 27 16:50:21 2013, haarg wrote:
> > I've released a new version of App::FatPacker using djerius's patch.
> > I've verified that my patched version of Module::Pluggable works with > the latest released version of App::FatPacker.
More importantly, I've pushed a test against App::FatPacker to https://github.com/djerius/Module-Pluggable Thanks, Diab
Great! Thanks. I'll try and get a release out tomorrow. On Tue Dec 17 12:26:14 2013, DJERIUS wrote: Show quoted text
> > More importantly, I've pushed a test against App::FatPacker to > > https://github.com/djerius/Module-Pluggable > > Thanks, > > Diab
It took me a couple of days longer than I wanted but version 5.0 is in master on GitHub. If you want to test just to make sure then go for it - otherwise I'll release over the weekend. On Tue Dec 17 21:32:07 2013, SIMONW wrote: Show quoted text
> Great! Thanks. > > I'll try and get a release out tomorrow. > > On Tue Dec 17 12:26:14 2013, DJERIUS wrote:
> > > > More importantly, I've pushed a test against App::FatPacker to > > > > https://github.com/djerius/Module-Pluggable > > > > Thanks, > > > > Diab
> >
On Fri Dec 20 19:45:06 2013, SIMONW wrote: Show quoted text
> It took me a couple of days longer than I wanted but version 5.0 is in > master on GitHub. > > If you want to test just to make sure then go for it - otherwise I'll > release over the weekend. >
Sorry for the delay; I popped version 5.0 in my application and it works. Thanks, Diab