Repository navigation
fix: delete recordings instead of proxy rules in DELETE recordings/:id - #243
Merged
alexliesenfeld merged 4 commits intoAug 31, 2026
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
danieleades
force-pushed
the
fix/delete-recording-endpoint
branch
3 times, most recently
from
August 10, 2026 10:24
d925384 to
0f3ab94
Compare
danieleades
force-pushed
the
fix/delete-recording-endpoint
branch
4 times, most recently
from
August 16, 2026 12:32
89d6120 to
704a1f8
Compare
handle_delete_recording called state.delete_proxy_rule, so deleting a recording via the admin API removed a proxy rule instead. Also fix copy-pasted log messages in the forwarding-rule and recording deletion paths.
The regression test connects to the standalone server so the deletion goes through the HTTP handler; it fails against the previous handler (404) and passes with the fix.
Covers the remaining changed lines: the forwarding-rule deletion log path and the 404 branches for deleting unknown forwarding-rule and recording ids through the admin API.
danieleades
force-pushed
the
fix/delete-recording-endpoint
branch
from
August 17, 2026 18:51
704a1f8 to
16aeea4
Compare
Member
|
Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
handle_delete_recording(the handler behindDELETE /__httpmock__/recordings/:id) calledstate.delete_proxy_rule(...)instead ofdelete_recording(...)— an apparent copy-paste slip. Deleting a recording via the admin API silently removed a proxy rule with the same id (or returned 404 based on proxy-rule existence), and the recording itself was never deleted.StateManager::delete_recordingwas unreachable from the server.Fix
delete_recordinginhandle_delete_recording(src/server/handler.rs).Behaviour change
The endpoint now actually deletes the recording and returns 204/404 based on whether the recording exists.
Verification
Adds a regression test that connects to the standalone server (so the deletion goes through the HTTP admin handler), creates a recording, and deletes it — it fails with a 404 panic against the previous handler and passes with the fix.
Full
cargo test --all-featuressuite passes locally (122 unit, 137 integration, 138 doc tests).