mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Add helpful message about termination due to unsupported keywords.
This commit is contained in:
parent
9ca6034388
commit
ca62d96714
@ -27,6 +27,7 @@
|
|||||||
|
|
||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
|
|
||||||
|
#include <opm/common/OpmLog/OpmLog.hpp>
|
||||||
#include <opm/common/utility/OpmInputError.hpp>
|
#include <opm/common/utility/OpmInputError.hpp>
|
||||||
#include <opm/input/eclipse/Deck/Deck.hpp>
|
#include <opm/input/eclipse/Deck/Deck.hpp>
|
||||||
#include <opm/input/eclipse/Deck/DeckKeyword.hpp>
|
#include <opm/input/eclipse/Deck/DeckKeyword.hpp>
|
||||||
@ -118,6 +119,10 @@ namespace KeywordValidation
|
|||||||
// Then report critical problems as an error.
|
// Then report critical problems as an error.
|
||||||
auto error_report = get_error_report(errors, false, true);
|
auto error_report = get_error_report(errors, false, true);
|
||||||
if (!error_report.empty()) {
|
if (!error_report.empty()) {
|
||||||
|
OpmLog::info("\nOPM Flow will terminate due to unsupported critical keywords.\n"
|
||||||
|
"These are keywords that would change the simulator results if supported.\n"
|
||||||
|
"If you need to override this behaviour, you can use the command line argument --parsing-strictness=low,\n"
|
||||||
|
"this will reduce the severity of this to a warning instead of an error.");
|
||||||
parse_context.handleError(
|
parse_context.handleError(
|
||||||
ParseContext::SIMULATOR_KEYWORD_NOT_SUPPORTED_CRITICAL, error_report, std::nullopt, error_guard);
|
ParseContext::SIMULATOR_KEYWORD_NOT_SUPPORTED_CRITICAL, error_report, std::nullopt, error_guard);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user