OPM / opm-parser

http://www.opm-project.org
11 stars 44 forks source link

WIP: Added ParseContext::IGNORE_EXTRA_RECORDS #1187

Closed stefoss23 closed 6 years ago

stefoss23 commented 6 years ago

Adding a new keyword for handling reading of eclipse .DATA files. When reading a keyword whose length was specified in the previous keyword, an exception is thrown if there are more records than expected.

With the new PARSE_EXTRA_RECORDS field, these extra records can be ignored.

GitPaean commented 6 years ago

One question about how to use it. I am not familiar with ParseContext. The default behavior will still throw an exception, right? How to make it not throw? Thanks.

atgeirr commented 6 years ago

The ParseContext.hpp provides some documentation. Basically you can override the settings chosen (by Flow for example) by setting environment variables.

https://github.com/OPM/opm-parser/blob/master/lib/eclipse/include/opm/parser/eclipse/Parser/ParseContext.hpp

joakim-hove commented 6 years ago

The default behavior will still throw an exception, right? How to make it not throw? Thanks.

The default beavior will still be to throw yes; but downstream really determines - so in addition to setting the environment variable one could envisage flow having commandline options for this?

joakim-hove commented 6 years ago

This looks fine - I assume the mentioned reordering of test conditions will solve the test problems, and then this can be merged!

joakim-hove commented 6 years ago

jenkins build this with downstreams please

joakim-hove commented 6 years ago

jenkins build this with downstreams please

joakim-hove commented 6 years ago

OK - the summaryconfigTest is fixed in master; the ParseContext test I do not understand.

joakim-hove commented 6 years ago

jenkins build this with downstreams please