Add snowplow metrics for failing masked variable validation
What does this MR do and why?
This MR adds the Snowplow events for the validation errors during the variable creation in the ci_cariable_modal
.
The events are:
-
label: 'ci_variable_modal', action: 'validation_error', property: 'displaysMaskedError'
for the error masking the variable. It is checked on the variable change and on the Mask variable checkbox toggle. -
label: 'ci_variable_modal', action: 'validation_error', property: 'displaysVariableReferenceError'
for the case when variable contains$
character.
The events are sent only once after the modal is opened. It will be sent once more if the user closes and opens the modal for the second time.
Screenshots or screen recordings
No visual changes. Adding screenshots for the context.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
- Go to Settings -> CI/CD -> Variables
- Try creating a variable that contains
$
or doesn't match the masked variables rules. - For the events testing you can use the Chrome Extension
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #346395 (closed)
Edited by Anna Vovchenko