Skip to content

fix(python): Return None from get() on 404 to match Rust client#570

Open
jan-auer wants to merge 1 commit into
mainfrom
fix/python-get-none-on-404
Open

fix(python): Return None from get() on 404 to match Rust client#570
jan-auer wants to merge 1 commit into
mainfrom
fix/python-get-none-on-404

Conversation

@jan-auer

Copy link
Copy Markdown
Member

Session.get() now returns None when the object does not exist, matching
the behavior of head() and the Rust client. Previously it raised
RequestError with status 404, forcing callers to catch and inspect the
exception for the common not-found case.

This is a breaking change for callers that catch RequestError to detect
missing objects — they should check for None instead.

Fixes FS-427

@jan-auer
jan-auer requested a review from a team as a code owner July 22, 2026 09:36
@linear-code

linear-code Bot commented Jul 22, 2026

Copy link
Copy Markdown

FS-427

@codecov

codecov Bot commented Jul 22, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.66%. Comparing base (e88b7f8) to head (4bc81f4).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #570      +/-   ##
==========================================
- Coverage   87.67%   87.66%   -0.02%     
==========================================
  Files          93       93              
  Lines       15113    15116       +3     
==========================================
  Hits        13251    13251              
- Misses       1862     1865       +3     
Components Coverage Δ
Rust Backend 92.45% <ø> (ø)
Rust Client 79.89% <ø> (ø)
Python Client 90.25% <100.00%> (+0.04%) ⬆️

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit b5fcdf5. Configure here.

Comment thread clients/python/src/objectstore_client/client.py
Comment thread clients/python/src/objectstore_client/client.py
@jan-auer
jan-auer force-pushed the fix/python-get-none-on-404 branch from b5fcdf5 to 4bc81f4 Compare July 22, 2026 09:45
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