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

fix: Include url.Parse error in DsnParseError #52

Merged
merged 1 commit into from
Sep 5, 2019

Commits on Sep 4, 2019

  1. fix: Include url.Parse error in DsnParseError

    Go 1.11.13 and 1.12.8 received backported fixes for security issues with
    url.Parse. One of the fixes includes stricter port validation.
    
    With those minor versions of Go running in Travis,
    TestInvalidDsnInvalidPort fails because url.Parse returns an error when
    it previously didn't, thus NewDsn returns &DsnParseError{"invalid url"}
    instead of &DsnParseError{"invalid port"}.
    
    Including the error from url.Parse in the message both provides more
    context for SDK users to understand why their DSN string was refused,
    and fixes the test because "invalid port" is part of the now included
    error message from url.Parse.
    rhcarvalho committed Sep 4, 2019
    Configuration menu
    Copy the full SHA
    78c6e14 View commit details
    Browse the repository at this point in the history