Releases: pgcentralfoundation/pgrx
v0.3.3
Upgrading
Please make sure to run cargo install cargo-pgx
and update all the pgx
extension Cargo.toml
's pgx*
versions to 0.3.3
.
What's Changed
v0.3.2
v0.3.1
v0.3.0
Upgrading
Please make sure to run cargo install cargo-pgx
and update all the pgx
extension Cargo.toml
's pgx*
versions to 0.3.0
.
We do not expect users to require additional actions on upgrade, but we recommend any usage of the pgxsql
be converted to use the new sql = "some string"
available on the macros. We expect pgxsql
support to be removed in the future, before 1.0.0.
Features
- Aggregates are now supported. Explore the Rustdocs of
pgx::Aggregate
andpgx::pg_aggregate
, or theaggregate
example to learn more. (#230, #406, #418, #428) cargo pgx
has a new coat of paint as Clap was upgraded to 3.0. (#368)cargo pgx
will now do some validation that it is being run on a crate which uses a compatiblepgx
version. (#389)cargo pgx
and thesql-generator
have more observability and improved error handling. Try exploring--verbose
! (#372)cargo pgx
related commands now treat thepgversion
as optional if somepgversion
is part of the extension'sdefault
features. (#402)- You can now have extensions which are
#[no_std]
. Whilepgx
still usesstd
, this can be a partial measure to limiting what an extension (or, for exampleplrust
) might be able to do on a system. (#385) pgx::Internal
has an expanded API likeget_or_insert_default()
. (#419)- Most
pgx
related attribute macros now supportsql = false
,sql = "string"
, orsql = some::func::path
to configure how they generate SQL. (#410, #422) - Nix users will find
lib.buildPgxExtension
in theflake.nix
. (#358, #360, #361)
Other changes
PgBox
acquirednew()
andnew_in_context()
functions. (#421)- The
pg_sys::TimestampTz
type alias now has an SQL mapping. (#400) pgx::memcxt::PgMemoryContexts
related closures now take aFnOnce
, this makes them considerably more flexible as they can capture their environment. (#390)pgx-pg-sys
should hopefully be able to build on Docs.rs! (#386)default!()
macros can now handle negative values. (63f5e6e)- The new
cargo pgx schema --skip-build
flag uses existing artifacts. (#255) @CARGO_VERSION@
in the.control
file is now supported in the SQL generation. (#409)- Fixed some help text in
cargo pgx init
. (https://github.com/zombodb/pgx/pull/415)\ - For users who already have
PGUSER
set, it was previously possible to encounter some issues duringcargo pgx
use. (#380) - For
x86_64-unknown-linux-musl
andaarch64-unknown-linux-musl
users, schema generation is now supported. (#362, #365) - For Nix users,
debug
anddoCheck
are now supported. (#349, #401) - For Mac Nix users,
glibc
was broken, it's no longer include it on Mac. (#335) - For Mac ARM users,
cargo pgx
will now handle removing libraries when needed due to code-signing. (#333, #420) - For CentOS 7 or other older-distro users, some problems were noted with GCC 4. (#387)
- General dependency updates and lint fixing. (#339, #364, #405, #414)
Thanks!
Thanks to @JamesGuthrie (from @timescale), @bitwalker (from @timescale), @robins , and @volks73 for their contributions!
v0.2.6
v0.2.5
pgx
v0.2.5 fixes an issue where Spi::get_one_with_args()
would cause Postgres to segfault if one of the query arguments is NULL (None
). It also improves our Nix support.
Thanks
Thanks to @bbigras for finding the SPI issue and also for the Nix support improvements!
What's Changed
- nix template: hoverbear -> zombodb by @bbigras in #296
- nix: use the registry by @bbigras in #301
- nix template: bump pgx by @bbigras in #302
- nix template: nmattia -> nix-community by @bbigras in #298
- fix crashes with NULL Datums in
SPI::get_one_with_args()
-> b2820a1
New Contributors
Full Changelog: v0.2.4...v0.2.5
v0.2.4
This is pgx
v0.2.4. It resolves (as best as possible) a compilation performance regression (#287) by only compiling the sql-generator binary when it's required. It also adds a few more Postgres headers for additional bindings around time/date and non-UTF8 encodings (PR #289).
Please make sure to run cargo install cargo-pgx
along with updating your extension's Cargo.toml
dependencies to point to this version.
v0.2.3
This is pgx
v0.2.3. It is a minor bugfix release that fixes an issue with doing "special token" replacements in the generated (and copied) .sql files.
v0.2.2
This is pgx
v0.2.2. It fixes an issue where #[pg_extern]
functions that return a (rust) tuple would forget their attribute values.