Skip to content

implement version_cmp for zypper - #31233

Merged
cachedout merged 3 commits into
saltstack:2015.8from
mcalmer:2015.8-zypperpy-add-version_cmp
Feb 17, 2016
Merged

cachedout merged 3 commits into
saltstack:2015.8from
mcalmer:2015.8-zypperpy-add-version_cmp

Conversation

@mcalmer

@mcalmer mcalmer commented Feb 16, 2016

Copy link
Copy Markdown
Contributor

version_cmp is used inside of the states. To work correctly with versions, zypper.py should implemt it.

@mcalmer
mcalmer force-pushed the 2015.8-zypperpy-add-version_cmp branch from 5e5b303 to 6ad6a90 Compare February 16, 2016 15:40
Comment thread salt/modules/zypper.py Outdated

# Import 3rd-party libs
# pylint: disable=import-error,redefined-builtin,no-name-in-module
import rpm

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We need to try/except this and then load this module in __virtual__ according to the results. Otherwise, this will stacktrace on installations without the rpm module installed.

@cachedout cachedout added the pending-changes The pull request needs additional changes before it can be merged label Feb 16, 2016
@mcalmer

mcalmer commented Feb 17, 2016

Copy link
Copy Markdown
Contributor Author

@cachedout - I have implemented an import check like the other pkg modules have them.

@cachedout

Copy link
Copy Markdown
Contributor

@mcalmer Much appreciated. Thank you!

cachedout pushed a commit that referenced this pull request Feb 17, 2016
@cachedout
cachedout merged commit fe9e5d2 into saltstack:2015.8 Feb 17, 2016
@mcalmer
mcalmer deleted the 2015.8-zypperpy-add-version_cmp branch March 1, 2020 15:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pending-changes The pull request needs additional changes before it can be merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants