Skip to content

Comments

fix: narrow parse and prefetch exception handling#29

Merged
fmueller merged 1 commit intomainfrom
fix/phase-c-exception-hardening
Feb 23, 2026
Merged

fix: narrow parse and prefetch exception handling#29
fmueller merged 1 commit intomainfrom
fix/phase-c-exception-hardening

Conversation

@fmueller
Copy link
Owner

Summary

  • replace broad parse-time except Exception blocks in note/body loaders with targeted parser exceptions (yaml.YAMLError, TypeError, ValueError)
  • tighten translation prefetch fallback handling to catch expected runtime failures (RuntimeError, PostEditAborted) instead of swallowing all exceptions
  • reduce language detection fallback catches to targeted runtime/value/type/attribute failure classes
  • add regression tests for loader parse error mapping and for preserving unexpected prefetch exceptions

Validation

  • uv run ruff check
  • uv run mypy
  • uv run pytest

@fmueller fmueller force-pushed the fix/phase-c-exception-hardening branch from 7c78968 to b47811b Compare February 23, 2026 19:29
@fmueller fmueller merged commit a407e19 into main Feb 23, 2026
1 check passed
@fmueller fmueller deleted the fix/phase-c-exception-hardening branch February 23, 2026 19:29
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