Drop array custom-variable name from tracking fixture for matomo-php-tracker 3.4.0 - #137
Open
sgiehl wants to merge 2 commits into
Open
Drop array custom-variable name from tracking fixture for matomo-php-tracker 3.4.0#137sgiehl wants to merge 2 commits into
sgiehl wants to merge 2 commits into
Conversation
matomo-php-tracker 3.4.0 types setCustomVariable()'s $name as string, so the deliberately-invalid array name now raises a TypeError. The id (6) is already out of the valid range and not tracked, so the string variant on the line above keeps the same coverage and the expected output is unchanged.
2 tasks
The invalid (array) custom-variable name can no longer be passed through the type-safe setCustomVariable(); inject it directly into the public visitorCustomVar payload so the fixture still verifies a malformed cvar is not tracked. Cannot use a raw _cvar param (custom param / debug append) because it would duplicate and override the valid cvars in the request.
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.
matomo-php-tracker 3.4.0 types
setCustomVariable()'s$nameparameter asstring. The tracking fixture deliberately passed an array name for an out-of-range custom-variable id (6), which now raises aTypeError.Since id 6 is already out of the valid range and not tracked, the string variant on the preceding line keeps the same coverage and the processed/expected output is unchanged.
Part of the Matomo 6 preparation (core bumps matomo-php-tracker to ~3.4.0).
Review