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

add filters to report_definition #48

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

rickiesmooth
Copy link

Fixes #47

@sonarcloud
Copy link

sonarcloud bot commented Jul 5, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@pnadolny13 pnadolny13 self-requested a review July 6, 2022 12:58
@@ -122,6 +122,15 @@ def _generate_report_definition(report_def_raw):
{"expression": metric.replace("ga_", "ga:")}
)

for filter in report_def_raw["filters"]:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rickiesmooth thanks for the PR!

It looks like this is making filters a required entry in the report definition file. If someone upgrades to this version they'd need to update their definitions before it will run without error.

What do you think about making filters optional so its backwards compatible for users that already have the tap running and have no filters defined? It should be a simple change to use .get("filters", []) or a similar safety check.

@tayloramurphy
Copy link

@rickiesmooth do you still want to try and get this PR merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support filters
3 participants