-
-
Notifications
You must be signed in to change notification settings - Fork 105
Watching plus Unicode #65
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
Conversation
oleg-nenashev
left a comment
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.
Minor comments so far. Need to finalize the upstream PT's review before approval
|
|
||
| public static final String defaultEncoding = "UTF-8"; | ||
|
|
||
| public FormValidation doCheckEncoding(@QueryParameter boolean returnStdout, @QueryParameter String encoding) { |
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.
Restrict it?
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.
Not part of this PR, but sure.
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.
(for #64)
| public static final String defaultEncoding = "UTF-8"; | ||
|
|
||
| public FormValidation doCheckEncoding(@QueryParameter boolean returnStdout, @QueryParameter String encoding) { | ||
| if (encoding.isEmpty()) { |
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.
Check for null just in case the form is messed up. Ideally it makes sense to use StringUtils.isBlank() here and in the constructor
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.
If the form is messed up, there is a product bug and validation will fail. No need to be unreasonably defensive.
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.
(for #64)
| } catch (UnsupportedOperationException x) { | ||
| getContext().onFailure(x); | ||
| } catch (Exception x) { // as below | ||
| LOGGER.log(Level.FINE, node + " is evidently offline now", x); |
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.
Apparently it's not documented in jenkinsci/durable-task-plugin#60
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.
Execution link in the log would be helpful
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.
(for #63)
| if (!directory) { | ||
| throw new AbortException("missing workspace " + remote + " on " + node); | ||
| } | ||
| LOGGER.log(Level.FINE, "{0} seems to be online", node); |
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.
DEBUG/FINEST? maybe also makes sense to print Execution#toString() to the log so we understand from where it comes
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.
Sure.
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.
(#63)
|
|
||
| @DataBoundSetter public void setEncoding(String encoding) { | ||
| this.encoding = encoding; | ||
| this.encoding = Util.fixEmpty(encoding); |
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.
Does not handle blank strings 🐜
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.
Sorry, what?
Convert empty string to null.
That is exactly what I want here.
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.
(anyway for #64)
Jenkinsfile
Outdated
| @@ -1 +1 @@ | |||
| buildPlugin(jenkinsVersions: [null, '2.73.1']) | |||
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.
Test with 2.107 instead?
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.
(obsolete)
oleg-nenashev
left a comment
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.
|
Please do not perform line-by-line reviews in this PR. Rather, review component PRs. |
|
Now covered by #63. |
Integrates #63 & #64. Downstream of jenkinsci/durable-task-plugin#62.
@reviewbybees