From: Jérôme Benoit Date: Mon, 22 Jun 2026 12:36:33 +0000 (+0200) Subject: style(quickadapter): tighten tail probe docstring clause (c) X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=f1acbdb7284fca21d76094d393996638dd1c083b;p=freqai-strategies.git style(quickadapter): tighten tail probe docstring clause (c) The (c) clause previously named both `ValueError` and `UnicodeDecodeError` plus their subclass relationship. The exception classes are visible at the `except ValueError` line below — keep the behavioral description in the docstring ("not parseable by json.loads (malformed JSON or invalid UTF-8)") and let the code document the catch surface. --- diff --git a/quickadapter/user_data/freqaimodels/QuickAdapterRegressorV3.py b/quickadapter/user_data/freqaimodels/QuickAdapterRegressorV3.py index 399120f..e49e1f3 100644 --- a/quickadapter/user_data/freqaimodels/QuickAdapterRegressorV3.py +++ b/quickadapter/user_data/freqaimodels/QuickAdapterRegressorV3.py @@ -4274,11 +4274,10 @@ class QuickAdapterRegressorV3(BaseRegressionModel): Bounded tail probe (last ``_OPTUNA_JOURNAL_TAIL_PROBE_BYTES``). Return True iff the file is non-empty AND its trailing record is (a) missing the newline, (b) empty (bare ``\\n``), or - (c) ``json.loads``-unparseable (malformed JSON, ``ValueError``, - or invalid UTF-8, ``UnicodeDecodeError`` — both are - ``ValueError`` subclasses). Fail-open when the probe window - cuts a single line larger than the window; defer to the - post-construction handler. + (c) not parseable by ``json.loads`` (malformed JSON or + invalid UTF-8). Fail-open when the probe window cuts a single + line larger than the window; defer to the post-construction + handler. """ if not journal_path.exists(): return False