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

Update to Postgres 17 #54

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open

Update to Postgres 17 #54

wants to merge 18 commits into from

Conversation

HRKings
Copy link
Contributor

@HRKings HRKings commented Oct 29, 2024

This is a big PR, to make it work with PG17 I had to rewrite many of the automatic functions from derive manually, but it works wonders with the latest version of Postgres. The biggest problem is the name conflict with the ulid package

@HRKings HRKings changed the base branch from pg17 to master October 29, 2024 21:57
@HRKings HRKings mentioned this pull request Oct 29, 2024
.github/workflows/release.yml Outdated Show resolved Hide resolved
Cargo.toml Outdated Show resolved Hide resolved
@@ -1,5 +1,5 @@
comment = 'ulid type and methods'
Copy link
Owner

Choose a reason for hiding this comment

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

Why are we renaming the extension?

Copy link
Contributor Author

@HRKings HRKings Dec 6, 2024

Choose a reason for hiding this comment

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

I'm only renaming the crate, because of the conflict, the build will generate a package that will provide 100% compatibility with the old name, so it won't break any existing Postgres extension

src/lib.rs Outdated Show resolved Hide resolved
@@ -1,30 +1,32 @@
[package]
name = "ulid"
name = "pgx_ulid"
Copy link
Owner

Choose a reason for hiding this comment

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

You shouldn't have a name conflict at all. Can you please describe the issue more?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

pgrx is trying to load the dynamic library ulid.so, but it is encountering the one from the ulid package and not from our extension, so I've renamed the crate to avoid any conflicts with the libraries generated

}
}
let inner = InnerUlid::from_string(val)
.unwrap_or_else(|err| panic!("invalid input syntax for type ulid: \"{val}\": {err}"));
Copy link
Owner

Choose a reason for hiding this comment

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

Don't we need to do ereport?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We don't

@pksunkara pksunkara linked an issue Dec 5, 2024 that may be closed by this pull request
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.

Request pg17 support
2 participants