Skip to content

fix: Do not specify version when creating extensions#144

Open
ardentperf wants to merge 1 commit intocloudnative-pg:mainfrom
ardentperf:pr-no-version
Open

fix: Do not specify version when creating extensions#144
ardentperf wants to merge 1 commit intocloudnative-pg:mainfrom
ardentperf:pr-no-version

Conversation

@ardentperf
Copy link

When create_extension=true, omit the version from the Database extensions spec so CNPG uses the extension's default_version from the control file. The OCI image version annotation reflects the package version, which can differ from the SQL extension version (e.g. pg_cron package 1.6.7 vs control default_version 1.6). This problem was encountered while working on #139

Also update the smoke test verification to check only that the extension exists, without requiring a specific version number.

When create_extension=true, omit the version from the Database
extensions spec so CNPG uses the extension's default_version from the
control file. The OCI image version annotation reflects the package
version, which can differ from the SQL extension version (e.g. pg_cron
package 1.6.7 vs control default_version 1.6). This problem was
encountered while working on cloudnative-pg#139

Also update the smoke test verification to check only that the extension
exists, without requiring a specific version number.

Signed-off-by: Jeremy Schneider <schneider@ardentperf.com>
@ardentperf ardentperf requested review from a team and NiccoloFei as code owners March 17, 2026 00:02
@gbartolini
Copy link
Contributor

I am not entirely convinced about skipping the version in the tests. Consider that at the moment we are not doing an important test, the upgrade one, and that at some point we must introduce it.

I was chatting with @NiccoloFei on Slack and he was suggesting to add a field called sql_version. By properly using renovate, we could control the version automatically, by selecting a different level from semantic versioning (e.g. patch or minor like in your case).

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.

2 participants