Skip to content

PostgreSQL Ipnetwork support #2395

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

Merged
merged 4 commits into from
Mar 30, 2025
Merged

PostgreSQL Ipnetwork support #2395

merged 4 commits into from
Mar 30, 2025

Conversation

Leo1003
Copy link
Contributor

@Leo1003 Leo1003 commented Oct 16, 2024

TODO:

  • Add some tests
  • Add codegen support
  • std::net::IpAddr support?
  • ipnet::IpNet support?
    • Requires sea-ql to support first

PR Info

New Features

  • Postgres network types support
    • Introduce new feature: with-ipnetwork

@Leo1003 Leo1003 marked this pull request as ready for review October 25, 2024 04:23
Copy link
Member

@tyt2y3 tyt2y3 left a comment

Choose a reason for hiding this comment

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

thank you. I think it looks good

@tyt2y3 tyt2y3 requested a review from billy1624 December 26, 2024 12:08
@Leo1003
Copy link
Contributor Author

Leo1003 commented Jan 15, 2025

Recently, ipnetwork published new breaking change 0.21 version. This makes us have to support different version of ipnetwork.

Does anyone have any thought on how to deal with this issue?

@Leo1003 Leo1003 force-pushed the ipnetwork-support branch from fee320f to ebd700a Compare March 13, 2025 05:44
@Leo1003
Copy link
Contributor Author

Leo1003 commented Mar 13, 2025

I resolved the conflicts and rebased on the latest commit.

Recently, ipnetwork published new breaking change 0.21 version. This makes us have to support different version of ipnetwork.

Does anyone have any thought on how to deal with this issue?

I think this required to wait for the upstream release: launchbadge/sqlx#3670.

Then, wait for sea-query to publish a release.

@Razican
Copy link

Razican commented Mar 14, 2025

Recently, ipnetwork published new breaking change 0.21 version. This makes us have to support different version of ipnetwork.

Does anyone have any thought on how to deal with this issue?

The way Diesel does this is by allowing more than one version: https://github.com/diesel-rs/diesel/blob/a5325d0d70c33c1952448121e1e52f4f5be6e9e5/diesel/Cargo.toml#L36

ipnetwork = { version = ">=0.12.2, <0.22.0", optional = true }

@tyt2y3 tyt2y3 merged commit c004532 into SeaQL:master Mar 30, 2025
36 checks passed
@tyt2y3
Copy link
Member

tyt2y3 commented Mar 30, 2025

Thank you, sadly we're bound by sqlx's type support, so can't upgrade before sqlx

Copy link

🎉 Released In 1.1.8 🎉

Thank you everyone for the contribution!
This feature is now available in the latest release. Now is a good time to upgrade!
Your participation is what makes us unique; your adoption is what drives us forward.
You can support SeaQL 🌊 by starring our repos, sharing our libraries and becoming a sponsor ⭐.

hjarraya pushed a commit to sambaclab/sea-orm that referenced this pull request Apr 29, 2025
* Support ipnetwork::IpNetwork

* Fix clippy unused_macros warning

* Add host_network_tests

* Add ipnetwork support for codegen
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.

Support Postgres network types (inet)
3 participants