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

Feature/string db credentials #2062

Merged
merged 2 commits into from
Mar 15, 2024

Conversation

acelaya
Copy link
Member

@acelaya acelaya commented Mar 15, 2024

Closes #2058

Make sure database user and password are casted to string when read as env vars.

This is a workaround for a problem caused by how env vars are read and type-casted in Shlink. Right now, they are converted to a specific type based in their value, while they should probably be type-casted based on the context they are going to be used on.

However, this requires more changes and considerations, and it could end up introducing other problems.

This just fixes the specific problems reported in #2058, and delays any further changes.

Copy link

codecov bot commented Mar 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.34%. Comparing base (a3d5060) to head (293725f).
Report is 3 commits behind head on develop.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #2062   +/-   ##
==========================================
  Coverage      97.34%   97.34%           
  Complexity      1363     1363           
==========================================
  Files            251      251           
  Lines           4826     4826           
==========================================
  Hits            4698     4698           
  Misses           128      128           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@acelaya acelaya merged commit 74180a4 into shlinkio:develop Mar 15, 2024
23 checks passed
@acelaya acelaya deleted the feature/string-db-credentials branch March 15, 2024 17:33
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.

Numeric env vars are casted to int, failing if a string is expected
1 participant