Skip to content

Conversation

randomjunk
Copy link
Contributor

Description

CheckNamedValue was returning a hard error instead of driver.ErrSkip if it couldn't convert the type. This commit intercepts the error and returns driver.ErrSkip to fix the use of Valuers.

Added a test that Valuer types are handled correctly. This test fails without the fix.

CheckNamedValue code was included recently:
#690

Issue was reported in:
#708

Checklist

  • Code compiles correctly
  • Created tests which fail without the change (if possible)
  • All tests passing
  • [-] Extended the README / documentation, if necessary
  • Added myself / the copyright holder to the AUTHORS file

…rnally

Added a test that Valuer types are handled correctly. This test fails without the fix.

CheckNamedValue code was included recently and breaks existing applications:
go-sql-driver#690

Reported in:
go-sql-driver#708
@julienschmidt julienschmidt merged commit b816f3d into go-sql-driver:master Nov 16, 2017
@julienschmidt
Copy link
Member

Thanks for the quick fix!

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