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

chore(config): replace unmaintained envconfig #181

Merged
merged 5 commits into from
Sep 8, 2023
Merged

Conversation

shini4i
Copy link
Owner

@shini4i shini4i commented Sep 7, 2023

Replace unmaintained kelseyhightower/envconfig with maintained caarlos0/env, and move some logic to envConfig.Parse.

@codecov
Copy link

codecov bot commented Sep 7, 2023

Codecov Report

Merging #181 (bffa8c7) into main (54549d6) will increase coverage by 0.18%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##             main     #181      +/-   ##
==========================================
+ Coverage   46.01%   46.19%   +0.18%     
==========================================
  Files          16       16              
  Lines        1230     1223       -7     
==========================================
- Hits          566      565       -1     
+ Misses        602      596       -6     
  Partials       62       62              
Files Changed Coverage Δ
cmd/argo-watcher/argo_api.go 20.95% <33.33%> (+1.13%) ⬆️
cmd/argo-watcher/config/config.go 82.35% <100.00%> (-0.99%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

📢 Have feedback on the report? Share it here.

@sonarcloud
Copy link

sonarcloud bot commented Sep 7, 2023

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
No Duplication information No Duplication information

@shini4i shini4i marked this pull request as ready for review September 7, 2023 22:30
@shini4i shini4i merged commit 81eb64f into main Sep 8, 2023
6 checks passed
@shini4i shini4i deleted the chore/replace-envconfig branch September 8, 2023 14:54
@@ -72,7 +73,8 @@ func init() {
mux.HandleFunc("/api/v1/session/userinfo", getUserInfoHandler)
mux.HandleFunc("/api/v1/applications/test", getApplicationHandler)
server = httptest.NewServer(mux)
api = &ArgoApi{baseUrl: server.URL, client: server.Client()}
parsedURL, _ := url.Parse(server.URL) // we assume that the server.URL is valid
Copy link
Collaborator

Choose a reason for hiding this comment

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

We might want to not assume, but throw errors here

Copy link
Owner Author

Choose a reason for hiding this comment

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

It is a URL coming from the default library, If it will return an invalid url it would be the least of our problems.

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.

2 participants