feat: implement issue #168 — SonarCloud: cognitive complexity (S3776)

DO
1mo ago
+617-433

Problem

SonarCloud: cognitive complexity (S3776)

From the issue: 14 open SonarCloud finding(s) in petry-projects/incubator, worst severity CRITICAL. Generated by the org SonarCloud Audit.

Risk

Low — 8 file(s) changed; no CI- or runtime-critical paths touched.

Test plan

No test files were added or updated. Verification: bash scripts/dev-lead-lint.sh (shellcheck --severity=warning) ran pre-commit; the existing CI (bats + lint) guards the change.

Rollback

Revert this PR. No non-revertible side effects (no tags, migrations, or external state).

Monitoring

This PR's CI checks (Lint + bats) are the success/regression signal.

Closes #168