diff --git a/CHANGELOG.md b/CHANGELOG.md index ffc9bd3786f76fcab8093a135297b8b0dd9a41d7..74bc3f04d0e1ffadfcceb54284dbf903dff1aebe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,7 +15,8 @@ SPDX-License-Identifier: GPL-3.0-or-later - Remove all flag value restrictions from the default flagging scheme `FloatTranslator` - Renamed `TranslationScheme.forward` to `TranslationScheme.toInternal` - Renamed `TranslationScheme.backward` to `TranslationScheme.toExternal` -- Changed Default value of the parameter `limit` for `SaQC.interpolateIndex` and `SaQC.interpolateInvalid` to ``None` +- Changed default value of the parameter `limit` for `SaQC.interpolateIndex` and `SaQC.interpolateInvalid` to ``None`` +- Changed default value of the parameter ``overwrite`` for ``concatFlags`` to ``False`` ### Removed ### Fixed diff --git a/saqc/funcs/resampling.py b/saqc/funcs/resampling.py index 5dce6b0094a4c9e81be706a16c398adba84fd38a..c7dcf511e5a25b0345ff65c4556993bee2d736ac 100644 --- a/saqc/funcs/resampling.py +++ b/saqc/funcs/resampling.py @@ -337,7 +337,7 @@ class ResamplingMixin: freq: str | None = None, drop: bool = False, squeeze: bool = False, - overwrite: bool = True, + overwrite: bool = False, **kwargs, ) -> "SaQC": """ @@ -395,7 +395,7 @@ class ResamplingMixin: If set to `True`, the appended flags frame will be squeezed - resulting in function specific flags informations getting lost. - overwrite: bool, default True + overwrite: bool, default False If set to True, the newly appended flags will overwrite exsiting flags. This might result in a loss of previous flagging information. @@ -471,6 +471,7 @@ class ResamplingMixin: "freq": freq, "drop": drop, "squeeze": squeeze, + "overwrite": overwrite, **kwargs, }, } diff --git a/tests/funcs/test_functions.py b/tests/funcs/test_functions.py index c898cb8af6658f1ca424a25564fb345e2faf5402..4ef82002ab488b0322ba50f531fcc03063a38231 100644 --- a/tests/funcs/test_functions.py +++ b/tests/funcs/test_functions.py @@ -101,7 +101,9 @@ def test_flagSesonalRange(data, field): flag=BAD, ) qc = qc.flagRange(newfield, min=test["min"], max=test["max"], flag=BAD) - qc = qc.concatFlags(newfield, method="match", target=field, flag=BAD) + qc = qc.concatFlags( + newfield, method="match", target=field, flag=BAD, overwrite=True + ) qc = qc.dropField(newfield) flagged = qc._flags[field] > UNFLAGGED assert flagged.sum() == expected