Ticket #968 (assigned defect)

Opened 4 years ago

Last modified 20 months ago

Padre::Plugin::Catalyst crash

Reported by: zenogantner Owned by: garu
Priority: major Milestone:
Component: plugins Version: trunk
Keywords: Cc:

Description

How to reproduce:

  1. Install Padre+Catalyst plugin from trunk.
  2. Start Padre.
  3. Make sure Catalyst plugin is activated
  4. Close "Catalyst Dev Server" tab
  5. Select the About menu entry of the plugin.

Output:

Panel tool Padre::Plugin::Catalyst::Panel does define 'view_close' method at /mnt/data/src/padre/Padre/lib/Padre/Wx/Bottom.pm line 156.
Unknown page type: 'Padre::Plugin::Catalyst::Panel'
This method is read-only at /usr/local/lib/perl/5.10.1/Class/MOP/Class/Immutable/Trait.pm line 26

Class::MOP::Class:::around('CODE(0xf4ccfc8)', 'Class::MOP::Class::Immutable::Moose::Meta::Class=HASH(0xf6cc930)', 'Moose::Object') called at /usr/local/lib/perl/5.10.1/Class/MOP/Method/Wrapped.pm line 159
Class::MOP::Method::Wrapped::ANON('Class::MOP::Class::Immutable::Moose::Meta::Class=HASH(0xf6cc930)', 'Moose::Object') called at /usr/local/lib/perl/5.10.1/Class/MOP/Method/Wrapped.pm line 89
Class::MOP::Class::Immutable::Moose::Meta::Class::superclasses('Class::MOP::Class::Immutable::Moose::Meta::Class=HASH(0xf6cc930)', 'Moose::Object') called at /usr/local/lib/perl/5.10.1/Moose.pm line 226
Moose::init_meta('Moose', 'for_class', 'Catalyst', 'metaclass', undef) called at /usr/local/lib/perl/5.10.1/Moose/Exporter.pm line 354
Moose::Exporter::ANON('Moose') called at /usr/local/share/perl/5.10.1/Catalyst.pm line 3
Catalyst::BEGIN() called at /usr/local/share/perl/5.10.1/Catalyst.pm line 3
eval {...} called at /usr/local/share/perl/5.10.1/Catalyst.pm line 3
require Catalyst.pm called at /usr/local/share/perl/5.10.1/Padre/Plugin/Catalyst.pm line 546
Padre::Plugin::Catalyst::on_show_about('Padre::Plugin::Catalyst=HASH(0xaf8f190)') called at /usr/local/share/perl/5.10.1/Padre/Plugin/Catalyst.pm line 259
Padre::Plugin::Catalyst::ANON('Padre::Wx::Main=HASH(0xab536b8)', 'Wx::CommandEvent?=SCALAR(0xae69b08)') called at /mnt/data/src/padre/Padre/lib/Padre.pm line 243
eval {...} called at /mnt/data/src/padre/Padre/lib/Padre.pm line 243
Padre::run('Padre=HASH(0x9c49b40)') called at /mnt/data/src/padre/Padre/script/padre line 152

BEGIN failed--compilation aborted at /usr/local/share/perl/5.10.1/Catalyst.pm line 3.
Compilation failed in require at /usr/local/share/perl/5.10.1/Padre/Plugin/Catalyst.pm line 546.
Perl exited with active threads:

3 running and unjoined
0 finished and unjoined
0 running and detached

I use Moose 1.08 and Catalyst 5.80024.

PS: Just found out that I get the same crash when opening the ABout box twice.

Change History

comment:1 Changed 3 years ago by zenogantner

  • Summary changed from Catalyst plugin: crash to [Catalyst plugin] crash

comment:2 Changed 3 years ago by bowtie

here is fix for above issue

just comment out Class::Unload->unload('Catalyst');

in file: Padre::Plugin::Catalyst.pm

sub on_show_about {
    require Catalyst;
    require Class::Unload;
    my $about = Wx::AboutDialogInfo->new;
    $about->SetName("Padre::Plugin::Catalyst");
    $about->SetDescription( Wx::gettext('Catalyst support for Padre') . "\n\n"
            . Wx::gettext('This system is running Catalyst version')
            . " $Catalyst::VERSION\n" );
    $about->SetVersion($Padre::Plugin::Catalyst::VERSION);
    # Class::Unload->unload('Catalyst');

    Wx::AboutBox($about);
    return;
}

can an sys-opp please apply

comment:3 Changed 3 years ago by waxhead

  • Owner set to garu
  • Status changed from new to assigned

comment:4 Changed 20 months ago by bowtie

  • Summary changed from [Catalyst plugin] crash to Padre::Plugin::Catalyst crash
Note: See TracTickets for help on using tickets.