Repository navigation
Say MAX_TAG_LENGTH bounds the install ID too; close leaked test clients - #14
Merged
Merged
Conversation
MAX_TAG_LENGTH's comment named only the program version, though it also bounds install_id= and the ID lines install_id_from_file accepts. In the tests, close the three enabled clients the blank-install-ID loop left running, and set DO_NOT_TRACK through mock.patch.dict rather than writing os.environ directly. Closes #12 Closes #13 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
Author
|
Self-review rubric (scored against CI run 38223873286 and
Judgment call, left as is:
Scope note: Do-not-auto-merge check: no protected path is touched (no This review was drafted during a Gardener session (https://github.com/Stephenson-Software/gardener). drafted by Claude on behalf of Daniel Stephenson |
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
MAX_TAG_LENGTH's#:comment now names both values the client sets and limits: the program version and the installation ID (install_id=and the linesinstall_id_from_fileaccepts). Only the comment changed; behaviour is the same. The README already gave both limits.test_blank_install_id_is_none_and_an_overlong_one_is_rejectednow closes the three enabled clients built in its loop, so their sender threads stop when the test ends. The assertion message also names which blank value failed.test_a_disabled_client_never_makes_up_or_writes_an_install_idnow setsDO_NOT_TRACKthroughmock.patch.dict(os.environ, ...), like the rest of the suite, instead of setting and deleting it onos.environdirectly.Closes #12
Closes #13
No bug fixes, so no regression tests were added. The test changes keep every existing assertion.
trace-client-java: nothing a Java user could see has changed (comment and test changes only). No matching change is needed.
Test plan
python3 -m compileall -q trace_client testspython3 -m unittest: 45 tests run, OK (local interpreter)Buildmatrix:test (3.8),test (3.10),test (3.12)This PR description was drafted during a Gardener session (https://github.com/Stephenson-Software/gardener).
🤖 Generated with Claude Code
drafted by Claude on behalf of Daniel Stephenson