Skip to content

Code hygiene: unused import, raise exc drops traceback context #13

Description

@AndresL230

Summary

Two trivial fixes:

1. Unused import

ruff check reports F401 unused-import for MAX_BUCKETS in recost/_transport.py:23.

2. Traceback rebound

recost/_interceptor.py:148-156, 219-228, 266-275, 342-350 re-raise via raise exc rather than bare raise, rebinding the traceback. End users debugging SDK-wrapped errors see the SDK wrapper at the top of the stack, not their own call site.

Fix

  • Remove the unused import.
  • Replace every raise exc with bare raise.

Files

  • recost/_transport.py
  • recost/_interceptor.py

Priority

P2 — pure code hygiene; the traceback issue affects end-user debugging experience.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Polish / nice-to-havebugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions