Skip to content

Validate TrackManager boolean controls - #5343

Merged
FlorianPfaff merged 2 commits into
mainfrom
agent/validate-track-manager-boolean-controls
Aug 18, 2026
Merged

Validate TrackManager boolean controls#5343
FlorianPfaff merged 2 commits into
mainfrom
agent/validate-track-manager-boolean-controls

Conversation

@FlorianPfaff

Copy link
Copy Markdown
Owner

Summary

  • validate allow_births, extract_confirmed_only, and keep_history as scalar booleans instead of applying Python truthiness
  • reuse the tracker logging flag validator so NumPy/backend boolean scalars remain accepted consistently
  • add focused regression coverage for truthy non-boolean strings, numeric values, and NumPy boolean scalars

Root cause

TrackManager.__init__ called bool(...) on three public controls. That silently turns values such as "False" into True, so configuration data can invert behavior without an error. Most importantly, allow_births="False" leaves births enabled; the same coercion also affects confirmed-track extraction and history recording.

Scope

The production diff is limited to one shared-validator import and the three flag assignments. The branch is based on current main and adds one focused test file.

Validation

  • compared the branch against main: 2 changed files, 10 production-line changes plus 31 lines of regression coverage
  • verified the branch is 2 commits ahead and 0 behind main
  • full pytest/lint execution is left to GitHub Actions because this execution environment cannot clone/install the repository dependencies

@github-actions

Copy link
Copy Markdown
Contributor

MegaLinter analysis: Success

Descriptor Linter Files Fixed Errors Max errors Warnings Elapsed time
✅ COPYPASTE jscpd yes no no 5.38s
✅ JSON prettier 7 0 0 0 0.49s
✅ JSON v8r 7 0 0 1.85s
✅ MARKDOWN markdownlint 68 0 0 0 1.08s
✅ MARKDOWN markdown-table-formatter 68 0 0 0 0.22s
✅ PYTHON black 1984 10 0 0 52.58s
✅ PYTHON isort 1984 21 0 0 2.38s
✅ REPOSITORY betterleaks yes no no 1.26s
✅ REPOSITORY checkov yes no no 44.21s
✅ REPOSITORY git_diff yes no no 0.09s
✅ REPOSITORY secretlint yes no no 80.14s
✅ REPOSITORY syft yes no no 2.18s
✅ REPOSITORY trivy-sbom yes no no 1.4s
✅ YAML prettier 11 0 0 0 0.44s
✅ YAML v8r 11 0 0 7.94s
✅ YAML yamllint 11 0 0 0.76s

Notices

⚠️ Your configuration references items that have been removed from MegaLinter and are ignored: MAKEFILE_CHECKMAKE. See Removed linters to find their replacements.

See detailed reports in MegaLinter artifacts

Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining FLAVOR_SUGGESTIONS: false)

  • Documentation: Custom Flavors
  • Command: npx mega-linter-runner@10.0.0 --custom-flavor-setup --custom-flavor-linters PYTHON_BLACK,PYTHON_ISORT,COPYPASTE_JSCPD,JSON_V8R,JSON_PRETTIER,MARKDOWN_MARKDOWNLINT,MARKDOWN_MARKDOWN_TABLE_FORMATTER,REPOSITORY_CHECKOV,REPOSITORY_GIT_DIFF,REPOSITORY_BETTERLEAKS,REPOSITORY_SECRETLINT,REPOSITORY_SYFT,REPOSITORY_TRIVY_SBOM,YAML_PRETTIER,YAML_YAMLLINT,YAML_V8R

MegaLinter is provided by OX Security
Show us your support by starring ⭐ the repository

@FlorianPfaff
FlorianPfaff marked this pull request as ready for review August 18, 2026 19:16
@FlorianPfaff
FlorianPfaff merged commit dacd231 into main Aug 18, 2026
15 of 26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant