Closed LiMuBei closed 11 months ago
HEllo @LiMuBei . Regarding the checls failure, you need to add a changelog fragment so the tests can pass
Attention: 1 lines
in your changes are missing coverage. Please review.
Comparison is base (
7ab900f
) 71.07% compared to head (b910e81
) 71.03%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
HEllo @LiMuBei . Regarding the checls failure, you need to add a changelog fragment so the tests can pass
Hi. I added a fragment.
If there is no check for its presence, this will fail if a datasource is not configured with basic auth at all. In that case it would try to remove an entry from the dict that is not there resulting in a KeyError.
SUMMARY
When comparing the existing datasource with the should be state, basicAuth is handled incorrectly in the case when the datasource is not configured with basicAuth at all. This case would result in a KeyError which this change fixes.
ISSUE TYPE
COMPONENT NAME
grafana_datasource.py
See also https://github.com/ansible-collections/community.grafana/issues/248