Skip to content

Running actions before initializing observers? #259

@ehuelsmann

Description

@ehuelsmann

@jonasbn, @oliwel, this code:

if ( $state->autorun ) {
my $state_name = $state->state;
$self->log->info( "State '$state_name' marked to be run ",
"automatically; executing that state/action..." );
$wf->_auto_execute_state($state);
}
$self->associate_observers_with_workflow($wf);
$self->_associate_transaction_observer_with_workflow($wf, $persister);
$wf->notify_observers('create');

seems to run actions before associating observers. It has done so forever, but still, it seems broken to run any actions before observers are attached, because how are observers to know about the state changes in the workflow if they're not allowed to observe?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions