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

Allow with_variant to take TypeEngine instance as well as the TypeEngine type directly like Column #245

Merged
merged 1 commit into from
Dec 20, 2022

Conversation

tapetersen
Copy link
Contributor

Description

Allow with_variant to take TypeEngine instance as well as the TypeEngine type directly like Column. This to allow documented usage as in https://docs.sqlalchemy.org/en/14/core/type_basics.html#using-uppercase-and-backend-specific-types-for-multiple-backends

Fixes: #244

Checklist

This pull request is:

  • A documentation / typographical error fix
    • Good to go, no issue or tests are needed
  • A short code fix
    • please include the issue number, and create an issue if none exists, which
      must include a complete example of the issue. one line code fixes without an
      issue and demonstration will not be accepted.
    • Please include: Fixes: #<issue number> in the commit message
    • please include tests. one line code fixes without tests will not be accepted.
  • A new feature implementation
    • please include the issue number, and create an issue if none exists, which must
      include a complete example of how the feature would look.
    • Please include: Fixes: #<issue number> in the commit message
    • please include tests.

Have a nice day!

Copy link
Member

@CaselIT CaselIT left a comment

Choose a reason for hiding this comment

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

Thanks for the fix.

will release the fix shortly

@CaselIT CaselIT merged commit 7870b7e into sqlalchemy:main Dec 20, 2022
@CaselIT
Copy link
Member

CaselIT commented Dec 20, 2022

@tapetersen
Copy link
Contributor Author

Thanks for a fast response I hope I placed the tests in a reasonable place.

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.

TypeEngine.with_variant should accept TypeEngine for type argument instances as well as Type[TypeEngine]
2 participants