-
Notifications
You must be signed in to change notification settings - Fork 122
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
Support Postgres Interval, Range, Bit, and BitVarying #2010
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Are there any other PG column types that we should add here?
👍 I took a cursory look based on this and found that these were
I can add them to this PR. I didn't dig far enough to see if these would work already or not: |
I tested these three new columns however |
@alex-tan It seems to fall under this category, so perhaps you can just declare it in
class Point < Struct.new(:x, :y)
sig { returns(FloatButImNotSure) } # TODO: Fill in correct types
def x; end
sig { params(x:FloatButImNotSure).returns(FloatButImNotSure) }
def x=(x); end
sig { returns(FloatButImNotSure) }
def y; end
sig { params(x:FloatButImNotSure).returns(FloatButImNotSure) }
def y=(x); end
end |
But that file doesn't end up in the shims for the project using tapioca right? |
Ahh, you're right, these are just shims for Tapioca's own internal use. Hmmm... I'll ask for guidance internally. To get you unblocked quicker, would you like to roll this PR back to just the original support for |
Sounds good, thanks 👍 |
28b06aa
to
ef2cd57
Compare
Head branch was pushed to by a user without write access
ef2cd57
to
790fa63
Compare
I went back and added Bit/BitVarying support again and also support for Range. It looks like there's a PR out to fix CI so I'll rebase when that gets merged. |
Hi, @alextan! We just fixed CI on Ruby 3.3.5. Would you mind rebasing on main and force pushing your branch? |
6e6d6cd
to
a51fcbd
Compare
@egiurleo sure thing, done 👍 |
Motivation
Adds support for this column type.
Implementation
I followed the other implementations of the postgres column types.
Tests
No tests since there's not an established way of doing that in the repo for this type of feature.