From d4740ae249957a3b9992b5393cf09350f8efc4fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?B=C3=A5rd=20Skaflestad?= Date: Wed, 12 Dec 2018 12:40:18 +0100 Subject: [PATCH] Check Size Inconsistencies Only for Open Connections The previous logic was slightly incomplete in that it checked size inconsistencies for all connections, not just open connections. This, in turn would in turn generate diagnostics like Report step 19/247 at day 252/3312, date = 16-Jul-1998 Time step 0, stepsize 16 days. ERROR: Uncaught std::exception when running tasklet: Inconsistent number of open connections I in vector (3) in Well B-4H. Trying to continue. With this update we look for size inconsistencies between a well's open connections and data::Wells::connections only. --- src/opm/output/eclipse/AggregateConnectionData.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/opm/output/eclipse/AggregateConnectionData.cpp b/src/opm/output/eclipse/AggregateConnectionData.cpp index 17b674ead..0ce2f4ef4 100755 --- a/src/opm/output/eclipse/AggregateConnectionData.cpp +++ b/src/opm/output/eclipse/AggregateConnectionData.cpp @@ -323,7 +323,7 @@ captureDeclaredConnData(const Schedule& sched, it->second[connID] = &(xr->second.connections[rCInd]); rCInd+= 1; } - else if (rCInd >= xr->second.connections.size()) { + else if ((conns[connID].state() == Opm::WellCompletion::StateEnum::OPEN) && (rCInd >= xr->second.connections.size())) { throw std::invalid_argument { "Inconsistent number of open connections I in vector (" + std::to_string(xr->second.connections.size()) + ") in Well " + wl->name()