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

make epoch optional in package spec (a.k.a. epoch guessing) #393

Open
MichaelMraka opened this issue Aug 30, 2018 · 1 comment
Open

make epoch optional in package spec (a.k.a. epoch guessing) #393

MichaelMraka opened this issue Aug 30, 2018 · 1 comment
Labels
enhancement New feature or request

Comments

@MichaelMraka
Copy link
Contributor

Currently when specifying packge NEVRA (both in /updates and /packages API) we require epoch to be there otherwise it's set as epoch=0. On the other hand standard output of rpm -qa does not show the epoch so common mistake could be using just NVRA instead on NEVRA which will result in empty output for packages with epoch !=0 (see #382).

Possible solution to minimize such errors could be "guessing" epoch (if not specified).
I.e. there is only a couple of packages with the same NVR and different epoch
so we can actually lookup package only by NVR and if there's a unique hit that's it (99.9%).
And if not unique let's return e.g. the one with the lowest epoch (0.1%).

@jsvob
Copy link
Member

jsvob commented Aug 30, 2018

I just checked https://github.com/RedHatInsights/insights-core/blob/master/insights/specs/default.py#L28 and it seems Insights rules don't have access to the epoch currently either.

@jdobes jdobes added the enhancement New feature or request label Jul 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants