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

Dashboard: Flavor filtering #224

Merged
merged 3 commits into from
Feb 14, 2024
Merged

Dashboard: Flavor filtering #224

merged 3 commits into from
Feb 14, 2024

Conversation

cbartz
Copy link
Collaborator

@cbartz cbartz commented Feb 13, 2024

Overview

Add support for flavor filtering by introducing a variable.

Screenshot from 2024-02-13 13-23-40

Screenshot from 2024-02-13 13-37-10

Rationale

Since canonical/grafana-agent-operator#47 has landed in the grafana agent, the juju_application variable no longer returns the application name of the principal charm (which is the flavor), so another mechanism for filtering by flavor is required.

Checklist

@cbartz cbartz added bug Something isn't working trivial labels Feb 13, 2024
@cbartz cbartz requested a review from a team as a code owner February 13, 2024 12:47
Copy link
Contributor

Test coverage for 2239db3

Name                         Stmts   Miss Branch BrPart  Cover   Missing
------------------------------------------------------------------------
src/charm.py                   468    104    121     24    76%   87-88, 95-96, 120-121, 125-127, 167-169, 178->190, 188, 224-243, 257-259, 260->264, 288-292, 323, 403-408, 431, 448-449, 463-464, 477-500, 524-527, 534, 542, 558, 562-567, 612->615, 628-629, 631-632, 666-673, 697-698, 731-732, 760-761, 763-764, 766-767, 841->843, 904-905, 921, 942-944, 948-951, 955
src/charm_state.py             138     18     22      3    86%   131-138, 221-224, 266-268, 279-280, 286-291, 302-304
src/errors.py                   41      0      0      0   100%
src/event_timer.py              63      9      6      1    86%   94-95, 103-104, 126, 143-144, 160-161
src/firewall.py                 52     18     20      0    61%   42-43, 66-69, 110-184
src/github_client.py            89     14     38      4    80%   38-45, 146, 169, 182-189, 207->242, 236
src/github_metrics.py           14      0      0      0   100%
src/github_type.py              50      0      0      0   100%
src/lxd_type.py                 37      0      2      0   100%
src/metrics.py                  73      2     10      1    96%   61->64, 170-171
src/metrics_type.py              6      0      0      0   100%
src/runner.py                  329     72     98     25    73%   46->48, 130, 183->197, 237-238, 264-265, 306-315, 339-344, 349, 369, 373-383, 432->435, 438-440, 447, 461, 471, 475, 477, 492, 526-531, 547-560, 571-610, 615, 653, 706-708, 712, 730, 765, 791, 796-808, 822, 827->829, 832-834
src/runner_logs.py              35      2      6      1    93%   62->61, 66-67
src/runner_manager.py          308     76    108      9    73%   123, 168-170, 183-184, 196-198, 204-209, 213-214, 224-225, 244, 287-288, 332-334, 399, 419-423, 448, 500-503, 535-553, 566-571, 592-597, 609-616, 711-724, 734, 739-750
src/runner_manager_type.py      40      0      6      0   100%
src/runner_metrics.py          123      8     20      2    93%   147-148, 160, 191-192, 307-311
src/runner_type.py              47      0     10      0   100%
src/shared_fs.py               116     16     20      0    88%   108-109, 133-134, 217-218, 241-242, 254-255, 260-261, 267-268, 292-293
src/utilities.py                68      5     20      7    86%   74->76, 78->84, 91, 121, 135, 175, 228
------------------------------------------------------------------------
TOTAL                         2097    344    507     77    81%

Static code analysis report

Run started:2024-02-13 12:49:15.830116

Test results:
  No issues identified.

Code scanned:
  Total lines of code: 4524
  Total lines skipped (#nosec): 0
  Total potential issues skipped due to specifically being disabled (e.g., #nosec BXXX): 7

Run metrics:
  Total issues (by severity):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
  Total issues (by confidence):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
Files skipped (0):

@cbartz cbartz merged commit f0699d6 into main Feb 14, 2024
57 checks passed
@cbartz cbartz deleted the flavor-filtering branch February 14, 2024 06:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Libraries: OK trivial
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants