Skip to content

[ntuple] Throw instead of asserting in RMiniFileReader::ReadBuffer#20986

Merged
silverweed merged 1 commit intoroot-project:masterfrom
silverweed:rminifile_readbuffer_noassert
Jan 26, 2026
Merged

[ntuple] Throw instead of asserting in RMiniFileReader::ReadBuffer#20986
silverweed merged 1 commit intoroot-project:masterfrom
silverweed:rminifile_readbuffer_noassert

Conversation

@silverweed
Copy link
Contributor

Corrupted files may cause ReadBuffer to fail, so the proper way of handling it is by returning a RResult rather than asserting.
In the interest of not changing the many places using ReadBuffer, I made it wrap a TryReadBuffer function that returns RResult and simply call ThrowOnError on it.
This gives similar semantics as before, except ReadBuffer will throw rather than asserting.

@silverweed silverweed requested review from enirolf and hahnjo January 22, 2026 13:18
@silverweed silverweed self-assigned this Jan 22, 2026
@silverweed silverweed requested a review from jblomer as a code owner January 22, 2026 13:18
@github-actions
Copy link

github-actions bot commented Jan 22, 2026

Test Results

    22 files      22 suites   3d 11h 1m 19s ⏱️
 3 770 tests  3 768 ✅ 0 💤 2 ❌
74 989 runs  74 987 ✅ 0 💤 2 ❌

For more details on these failures, see this check.

Results for commit 6ef9cda.

♻️ This comment has been updated with latest results.

@silverweed silverweed force-pushed the rminifile_readbuffer_noassert branch from e742851 to 6ef9cda Compare January 26, 2026 10:49
@silverweed silverweed merged commit 40ab0aa into root-project:master Jan 26, 2026
27 of 30 checks passed
@silverweed silverweed deleted the rminifile_readbuffer_noassert branch January 26, 2026 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants