Skip to content

Fixes #34767 - #34768

Merged
terminalmage merged 8 commits into
2015.8from
unknown repository
Aug 1, 2016
Merged

terminalmage merged 8 commits into
2015.8from
unknown repository

Conversation

@ghost

@ghost ghost commented Jul 19, 2016 •

Copy link
Copy Markdown

What does this PR do?

Makes sure that pkg.installed works in accordance with the docs when it comes to refreshing the pkg db in Windows. Even if, for some reason, it's not a perfect fix it will only improve things, and it shouldn't break anything non-Windows.

What issues does this PR fix or reference?

#34767

Tests written?

No

@cachedout

Copy link
Copy Markdown
Contributor

@ghost

ghost commented Jul 19, 2016

Copy link
Copy Markdown
Author

Last commit was needed because it's not only the call to pkg.installed that might cause a refresh so, the test for refreshed had to be moved to the outer-most nesting level.

@cachedout

Copy link
Copy Markdown
Contributor

@terminalmage Could you take a look here as well please?

Comment thread salt/states/pkg.py Outdated
if not isinstance(version, six.string_types) and version is not None:
version = str(version)

refreshed = False

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.

Can we use something other than refreshed here? It's too close to refresh and will be confusing to maintain.

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.

Maybe already_refreshed?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

That sounds good to me. We'll go with that.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

@terminalmage, would you be ok with "was_refreshed"? That way when we do the test we'll end up seeing

if os.path.isfile(rtag) and was_refreshed:

I think that "was_refreshed" captures the meaning a bit more. However, if you still insist on "already_refreshed" I'll go with that, as I said.

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.

Sure, that'd be fine. That makes it sufficiently different from "refresh", I think.

@ghost

ghost commented Jul 22, 2016

Copy link
Copy Markdown
Author

Yo @cachedout this is ready to roll.

Move refreshed or refresh to different spot (just for code tidyness)
@ghost

ghost commented Jul 25, 2016

Copy link
Copy Markdown
Author

Hi @cachedout. For good measure, I put the pkg.latest version in a try/except (same as is don in the "latest" function, and I also moved one line of code to a better stop (from the point of view of code elegance). Can you please merge this soon?

@ghost

ghost commented Jul 27, 2016

Copy link
Copy Markdown
Author

@cachedout is there some reason why this isn't getting merged?

@cachedout

Copy link
Copy Markdown
Contributor

Hi @hrumph. Sorry this fell off my radar. Thanks for the bump. I'm looking at it now.

@cachedout

Copy link
Copy Markdown
Contributor

Go Go Jenkins!

@ghost

ghost commented Jul 29, 2016

Copy link
Copy Markdown
Author

@cachedout is there some reason why this can't be merged? I don't know what the failed tests mean.

@ghost

ghost commented Aug 1, 2016

Copy link
Copy Markdown
Author

@cachedout why no merge?

@ghost

ghost commented Aug 1, 2016

Copy link
Copy Markdown
Author

@cachedout can you give me some idea of what the typical merge schedule is? I would have thought that fixes for anything should get priority over all other pr's.

@ghost

ghost commented Aug 1, 2016

Copy link
Copy Markdown
Author

@terminalmage can you help me to get this thing merged?

@terminalmage
terminalmage merged commit 88a9fb1 into saltstack:2015.8 Aug 1, 2016
@terminalmage

Copy link
Copy Markdown
Contributor

@hrumph Sorry, we've been quite busy working on the upcoming Carbon release, so this took longer to get merged than we would have hoped.

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