Conversation
|
For posterity, a terminal command I used to automate the removal of unnecessary |
|
Some of the spec assertion revisions here are made challenging by differences in how we assert logging: expect(@analytics).to receive(:track_event).with('...', kwargs)vs. expect(@analytics).to have_logged_event('...', kwargs)The former is outdated in that it doesn't benefit from all of the features of our FakeAnalytics helper class, which now notably includes It might be easier for me to do a separate pass at converting everything over to Edit: This has been addressed separately in #11001 and #11010. |
57b174b to
0c421d5
Compare
|
The build is passing here now, so it's ready for review. A couple related notes:
|
|
Nevermind, the build showed as green, but I think GitLab hadn't actually run. There's still some more errors to work through. |
|
Most of the spec changes involved simply dropping any A few were more complicated, particularly with shared examples where sometimes an analytics value is logged and sometimes it's not. In those cases, often I could call |
5846c53 to
28fe8a8
Compare
|
This will need to wait on a few revisions to dependent log metric queries before being able to merge (as discussed during this week's engineering huddle). |
5993668 to
71b5c98
Compare
|
This is unblocked now as of DevOps RC v388. |
changelog: Internal, Analytics, Avoid sending nil values for analytics events
71b5c98 to
d815f0a
Compare
…ID (#12177) * doc auth pass if transaction status passes changelog: Internal, Document Authentication, TrueIDReponse successful if transaction status passes * update spec response transaction status * update true id response spec * update fixtures product status for failed transactions * update product status * selfie must past * revert fixture changes * resolve rebase conflict * attention barcode does not have to be only error * update doc_auth_success to remove selfie in mock result response * happy linting * allow mock proofer to have multiple errors with barcode attn * remove dup test * add an error barcode fixture to barcode error trueid response * ensure attention_with_barcode? returns a boolean * update spec attention with barcode * error generator use transaction status to determine if doc auth passed when counting errors * consolidate checking if doc auth passed in error generator * doc_auth_passed not in scope for DocAuthErrorHandler * update mock to include transaction_status * rename error generator tests from 'DocAuthResult is ...' to 'TransactionStatus is ...' * resolve rebase conflict * resolve rebase conflict * resolve rebase conflict * resolve rebase conflict * update transaction_stauts in mock to reflect doc auth only * check transaction status to determine if doc auth is sucess for mock * assist with correcting case for transaction status and doc auth result in yml files * do not correct case * add transaction status to yml * add transaction status to yml * add transaction status to yml * add transaction result to inline yaml files * update yml fixtures to have transaction_status * update image upload presenter to use transaction status * resolve rebase conflict * remove stale comment * remove props as per PR #10987 * happy linting * TransactionCodes * happy linting * fix namespacing * remove billed attribute from transactin status * fix typo
🛠 Summary of changes
Updates
Analyticsto avoid trackingnilvalues forevent_properties.Why?
niland not sending anything at allnilcreates a lot of noise in specs, particularly when adding a new optional property to an existing analytics methods (currently dealing with this in Document all analytics logged through sign_in_spec #10966)AnalyticsEventswhich currently call.compactmanually, which is usually added as a workaround to the issued described in the point aboveRelated Slack discussion: https://gsa-tts.slack.com/archives/C0NGESUN5/p1706906370684589
📜 Testing Plan
Verify that the build passes.
Use
make watch_eventsto verify that any event which may log anilvalue (either defaulted or explicit from calling an analytics method) does not include the property in the logged output.