Private
Public Access
0
0
Files
manual_slop/scripts
ed 3c839c910a feat(scripts): Heuristic A - Result-returning recovery = INTERNAL_COMPLIANT
Phase 11.2. Adds the LEGITIMATE heuristic that recognizes the canonical
data-oriented pattern: \	ry: ...; except: return Result(data=...,
errors=[...])\ is the convention's canonical recovery pattern.

Detection:
- New _returns_result(stmts) helper on ExceptionVisitor
- New step 0 in _classify_except (BEFORE BOUNDARY_CONVERSION check)
- Classifies as INTERNAL_COMPLIANT with a hint that names the pattern

The function-name-not-ending-in-_result is documented as a smell
(rename to xxx_result for canonical naming), but the pattern itself
is compliant.

Tests:
- 2 new tests in test_audit_exception_handling_heuristics.py:
  - test_result_returning_recovery_in_non_result_named_function_is_compliant
  - test_result_returning_recovery_in_result_named_function_is_compliant
- Both pass; the 2 REJECTED tests (#22, #23) remain xfailed.

Per conductor/tracks/result_migration_small_files_20260617/plan.md
section 11.2.
2026-06-18 00:00:42 -04:00
..
2026-06-06 12:47:41 -04:00
2026-06-07 11:51:36 -04:00
2026-06-07 11:51:36 -04:00
2026-06-15 20:10:18 -04:00