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
Fixes #29768 - Use debversion extension for sorting deb-versions #8708
Conversation
287b1a9
to
ebe7876
Compare
ebe7876
to
18a2a6b
Compare
18a2a6b
to
98090a3
Compare
98090a3
to
96d6a8a
Compare
7debb9d
to
d5995fb
Compare
OK, so the test fails because
Any ideas? |
d5995fb
to
b2ff5ff
Compare
b2ff5ff
to
d5e3899
Compare
Patched the |
@m-bucher what are the steps for me to test this? Just install the package and run a db:migrate/seed? |
@chris1984 yes, if the postgresql-debversion package is installed, the migration should work. |
Awesome will test it Monday |
To testing the sorting, do I just need to upload a few deb packages of different names, or the same name but with different versions? |
@chris1984, either that or you just sync any apt-repository (I do not recommend Debian stable repository because it is fairly large 😁 ).
Then you can compare the results of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK looks good to me based on the results being different:
name | version
---------------------------------------------+--------------------------------
libjson-c-dev | 0.13.1+dfsg-7ubuntu0.2
libjson-c4 | 0.13.1+dfsg-7ubuntu0.2
libjson-c-doc | 0.13.1+dfsg-7ubuntu0.2
libexif-doc | 0.6.21-6ubuntu0.1
libexif-dev | 0.6.21-6ubuntu0.1
libexif12 | 0.6.21-6ubuntu0.1
katello=# select name, version from katello_debs ORDER by version_sortable;
name | version
---------------------------------------------+--------------------------------
libexif-doc | 0.6.21-6ubuntu0.1
libexif12 | 0.6.21-6ubuntu0.1
libexif-dev | 0.6.21-6ubuntu0.1
libjson-c-dev | 0.13.1+dfsg-7ubuntu0.2
libjson-c4 | 0.13.1+dfsg-7ubuntu0.2
libjson-c-doc | 0.13.1+dfsg-7ubuntu0.2
@jturel any comments?
This looks good to me, just waiting on https://github.com/theforeman/puppet-katello/pull/341/files so we don't break nightlies |
I think this is good to go. Thanks @m-bucher ! |
This requires that
rh-postgresql12-postgresql-debversion
package is installed.Additionally the extension must be activated in the database:
Not sure if this can/should be done in the migration-script.
Having this merged would make it possible to merge/review #7961 and #8277, because they rely on a possibility to compare Debian version numbers.