-
-
Notifications
You must be signed in to change notification settings - Fork 374
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
Fix travis #324
Merged
Merged
Fix travis #324
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
b30c81a
Fix TravisCI for Ruby < 2
ghoneycutt 132ce39
Explicitly support Puppet v4.3, 4.4 and 4.5
ghoneycutt 880d2b3
Simplify CI tests by ensuring the use of a newer puppetlabs_spec_helper
ghoneycutt ca88207
Fix existing bug in spec tests
ghoneycutt dd9af35
Fix style
ghoneycutt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This should be converted to just be default => $python::version rather than disabling the line message. Placing the variable in quotes like this does not cast it to a string, and the behavior both ways is identical. You would need to use sprintf to cast it to a string, but that would actually change the current behavior.
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.
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.
And doing it another way just to demonstrate the "universality" of how puppet likes to put things into their little boxes:
In order to actually cast it into a string, you would need to do something weird like this:
But again, doing that with sprintf would actually change the current behavior of the module as the current behavior is to treat the $python::version variable as either an int or a str depending on it's contents. Removing the quotes and curly braces will resolve the lint issue while preserving that behavior.
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.
@cryptk My only concern is that
$python
is stringified on purpose and by changing the current behavior it will break something that is expecting that$python
is a string.I'm in favor of doing it your way, though that needs to be tested. Please send a PR that changes the behavior.
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.
I think you misunderstood what I am saying. Placing the variable in quotes like that does NOT stringify it. It is still an integer (assuming that the input is just digits) or a string (if the input is not just digits) either way.
Changing it to read
is behaviorally identical to the quoted and braced version, just more stylistically correct. Please read my previous line comments which demonstrate this.