plumed / plumed2

Development version of plumed 2
https://www.plumed.org
GNU Lesser General Public License v3.0
324 stars 269 forks source link

Setting flags to default true makes no sense so I added a plumed_merr… #1021

Closed gtribello closed 4 months ago

gtribello commented 4 months ago
Description

Addressing @GiovanniBussi issue #1018.

I think you are correct @GiovanniBussi that it is not possible to set flags default true. I thus added a plumed_merror in keywords if anyone does set the second argument to addFlag to true. The better fix would be to get rid of the second argument but that is a massive change and I can't be bothered.

Target release

I don't particularly mind

Type of contribution
Copyright
Tests
codecov-commenter commented 4 months ago

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (60edd78) 84.19% compared to head (bf23c84) 84.17%.

:exclamation: Current head bf23c84 differs from pull request most recent head da0d459. Consider uploading reports for the commit da0d459 to get more accurate results

Files Patch % Lines
src/core/ActionWithValue.cpp 0.00% 1 Missing :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1021 +/- ## ========================================== - Coverage 84.19% 84.17% -0.03% ========================================== Files 613 613 Lines 56568 56567 -1 ========================================== - Hits 47628 47613 -15 - Misses 8940 8954 +14 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

GiovanniBussi commented 4 months ago

OK it makes sense. If I understand properly, this does not affect the way the code behaves, but anyway it fixes the documentation (currently in the manual some flags are shown as "default on", incorrectly). I will try to backport this so as to have the manual fixed.

GiovanniBussi commented 4 months ago

Backported in to v2.8 in 4736354aafd4ee7c0109a48a57224c3ac6132091, then merged to v2.9 and master