Repository navigation
feat(trace)!: report argument types instead of values - #7
Merged
Merged
Conversation
🏹 Robin✅ Review done. Nothing worth flagging — looks clean to me. Push fixes whenever you like, then comment Robin v2.9.0 · antongulin/robin@main (f97948f) · diff-only review (agent mode off) |
There was a problem hiding this comment.
🏹 Robin
Heads up: this is a point-in-time review. Push fixes freely, then comment
/robinwhenever you want another pass.
✅ No issues found
Robin — the Robin Hood of code review. Free for every PR.
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.
Summary
Trace frame
argsnow carries type names only, one per argument, in order, instead of sanitized values.get_debug_type()names every value, except arrays, which split intovec(list) anddict(associative).SensitiveParameterValueis unwrapped withgetValue()and its inner value typed, so the protected value's type is reported but never the value.Why
No argument value can ever reach the response or the trace. That removes the entire sanitizer: no depth/item/length limits, no cycle detection, no
__toStringavoidance, and no redaction markers.Changes
src/Trace/ArgumentTyper.php— the whole feature is one method.src/Trace/TraceFactory.php— depends onArgumentTyper;args()maps each argument to its type.src/Document/Frame.php—argsis nowlist<string>|null.src/ExceptionHandler.php— wiring.src/Trace/ArgumentSanitizer.php,src/Document/SanitizedMap.php,src/Document/SanitizedObject.php.ArgumentTyperTest; updatedTraceFactoryTest/FrameTest; removed the sanitizer tests and fixtures./typesroute;recursionno longer builds a cyclic graph.Breaking change
The
argsmember's contents change from sanitized values to type-name strings.Validation
composer run verify— format, lint, analyze, 83 tests, 100% coverage.Note: this branch also carries the pre-existing local
chore: clean up comments and namescommit (fa84bfb), which was already onmainlocally and could not be cleanly separated.