Skip to content

Fix bugs: sleep mismatch, hardcoded timeout, missing DB timeouts, wrong log names#22

Merged
rverk merged 1 commit intomainfrom
fix/bugs-sleep-timeout-logging
Mar 13, 2026
Merged

Fix bugs: sleep mismatch, hardcoded timeout, missing DB timeouts, wrong log names#22
rverk merged 1 commit intomainfrom
fix/bugs-sleep-timeout-logging

Conversation

@rverk
Copy link
Collaborator

@rverk rverk commented Mar 13, 2026

Summary

  • Sleep mismatch in daemon error handlers (vestigingen, vestigingsprofiel): time.sleep(interval) was 60× too short on error — caused rapid API-hammering after failures. Fixed to time.sleep(interval * 60).
  • Hardcoded timeout=60 in get_vestigingen_raw while all other API methods use self.timeout (600s). Fixed to self.timeout.
  • Missing DB connection timeout in vestigingen, vestigingsprofiel and mutatie-reader: added connect_args={"timeout": 30} to match basisprofiel and prevent indefinite hangs on DB outage.
  • Copy-paste log messages: SignaalWriter, VestigingsProfielWriter and KvKVestigingenWriter all logged "Initializing BasisProfielWriter". Fixed to correct class names.
  • f-string logging in mutatie-reader daemon loop: replaced with lazy %s formatting per coding standards.

Test plan

  • just check-all passes (190 tests, 0 pyright errors, ruff clean)

🤖 Generated with Claude Code

…ng log names

- Fix daemon error handlers in vestigingen and vestigingsprofiel: sleep(interval)
  was 60x too short on error; now correctly sleeps sleep(interval * 60)
- Fix hardcoded timeout=60 in get_vestigingen_raw; use self.timeout (600s) like
  all other API methods
- Add connect_args={"timeout": 30} to DB engine in vestigingen, vestigingsprofiel
  and mutatie-reader to match basisprofiel and prevent indefinite hangs
- Fix copy-paste log messages in SignaalWriter, VestigingsProfielWriter and
  KvKVestigingenWriter (all said "Initializing BasisProfielWriter")
- Fix f-string logging in mutatie-reader daemon loop (use lazy %s formatting)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@rverk rverk merged commit 5a51640 into main Mar 13, 2026
1 check passed
@rverk rverk deleted the fix/bugs-sleep-timeout-logging branch March 13, 2026 15:48
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