Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow JavaScript error tracking to be filtered #218

Merged
merged 4 commits into from Sep 1, 2015

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Aug 13, 2015

Don’t track javascript errors generated by files that don’t match a specified filter. eg external files included by browser plugins.

Non gov.uk error events are currently tracked ~40,000 times per day (30% of error events tracked).

Usage:

GOVUK.analyticsPlugins.error({filenameMustMatch: /gov\.uk/});
fofr added 4 commits Aug 13, 2015
Don’t track javascript errors generated by files that don’t match the
specified filter. eg external files included by browser plugins.
While this works in browser, the test runner fails on the `new Event()`
constructor.
@edds
Copy link
Contributor

@edds edds commented Aug 25, 2015

Would it be better to do this in GA rather than doing it in code? That way we can still have a view with all the events incase it is useful in the future.

@fofr
Copy link
Contributor Author

@fofr fofr commented Aug 26, 2015

Good suggestion @edds.

Speaking with Paul Cronk about the filters we'd need for this, and the volume of events we're collecting we are going to try doing this in GA first.

Closing PR

@fofr fofr closed this Aug 26, 2015
@fofr
Copy link
Contributor Author

@fofr fofr commented Sep 1, 2015

Re-opening this PR. After investigating doing this in GA we've found it's not currently possible. You cannot filter both on an event action and an event label, and you cannot limit this to just one aspect of a profile. An emailed report could be generated, but this wouldn't be suitable for all use cases – eg a deploy where real time events are checked to see if JavaScript errors are affected.

Going back to the original approach.

@fofr fofr reopened this Sep 1, 2015
jamiecobbett added a commit that referenced this pull request Sep 1, 2015
Allow JavaScript error tracking to be filtered
@jamiecobbett jamiecobbett merged commit d93743c into master Sep 1, 2015
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@jamiecobbett jamiecobbett deleted the filtered-error-tracking branch Sep 1, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.