diff --git a/ebos/eclproblem.hh b/ebos/eclproblem.hh index e5769f7a4..c08f2ea14 100644 --- a/ebos/eclproblem.hh +++ b/ebos/eclproblem.hh @@ -991,9 +991,11 @@ public: eclWriter_->evalSummaryState(isSubStep); auto& schedule = simulator.vanguard().schedule(); + auto& ecl_state = simulator.vanguard().eclState(); int episodeIdx = simulator.episodeIndex(); this->applyActions(episodeIdx, simulator.time() + simulator.timeStepSize(), + ecl_state, schedule, simulator.vanguard().summaryState()); } @@ -1058,8 +1060,9 @@ public: void applyActions(int reportStep, double sim_time, + Opm::EclipseState& ecl_state, Opm::Schedule& schedule, - const Opm::SummaryState& summaryState) { + Opm::SummaryState& summaryState) { const auto& actions = schedule.actions(reportStep); if (actions.empty()) return; @@ -1076,6 +1079,10 @@ public: ts = os.str(); } + for (const auto& pyaction : actions.pending_python()) { + pyaction->run(ecl_state, schedule, reportStep, summaryState); + } + auto simTime = schedule.simTime(reportStep); for (const auto& action : actions.pending(simTime)) { auto actionResult = action->eval(simTime, context);