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
Decoders/encoders for Network Addres Types #68
Comments
Simply no research has been commenced on the according binary codecs. You can take it on if you want. The according PRs will be merged. |
I will give it a try.. I just cloned project and used
Do I have to create local database? |
No. It seems like you're missing the default "postgres" schema. The tests assume that you have it. It doesn't matter what the contents of it are though. |
I have default postgres schema. Also, not all tests are failing. |
This is definitely due to your local Postgres configuration, the tests run fine on the default Travis configuration. I think the following should help with your issue: http://dba.stackexchange.com/q/106057/52225. Also please notice that all Hasql codecs are actually implemented in a separate project: https://github.com/nikita-volkov/postgresql-binary. Hasql merely provides wrappers. |
Yes, it was my local Postgres configuration. The roundtrip test is working for the |
@nikita-volkov
Similar for IP6. |
Since there's no standard package for those types, it's best to have the neutral option. Hence is my vote for this. |
I agree. Another question. I'm almost there 😄 |
Hmm, when I use Using lazy byte strings ('binary' package does not have strict version): not enough writing and reading bytes |
Nevermind, I will try another solution, maybe with 'cereal' package. |
No. There's no need for either of those packages. All the tools you need are in "bytestring". Please look at the implementations of other codecs in https://github.com/nikita-volkov/postgresql-binary. |
I have it working for IP4 with and without netmask. Tests are passing. Point is, for IP6 I need function to go from |
Thanks for your tip. I'm making progress again, hopefully I see all tests passing soon. |
It's done 😄 |
I can not find encoders and decoders for network address types as
inet
andcidr
. Is there specific reason they are missing?The text was updated successfully, but these errors were encountered: