-
Notifications
You must be signed in to change notification settings - Fork 173
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
[SCM-937] replace deprecated methods #101
Conversation
BufferedReader r = new BufferedReader( new FileReader( gitlog ) ); | ||
|
||
try | ||
try ( BufferedReader r = new BufferedReader( new FileReader( gitlog ) ) ) |
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.
We should create another issue here because it is subject to character conversion.
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.
good point. fixed.
Seeing some flakiness in our windows builds for this plugin in multiple PRs: Error Message Command failed.The svn tag command failed. Stacktrace org.apache.maven.plugin.MojoExecutionException: Command failed.The svn tag command failed. Standard Output Test command line: cmd.exe /X /C "svnadmin create repository" |
This cannot be real: C:\Windows\system32\config\systemprofile\AppData\Local\Temp\maven-scm-173513893.commit Writing into |
@@ -52,7 +53,8 @@ | |||
{ | |||
GitStatusConsumer consumer = new GitStatusConsumer( new DefaultLog(), null, relativeRepoPath ); | |||
|
|||
try ( BufferedReader r = new BufferedReader( new FileReader( gitlog ) ) ) | |||
try ( BufferedReader r = new BufferedReader( | |||
new InputStreamReader ( new FileInputStream( gitlog ), StandardCharsets.UTF_8 ) ) ) |
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 don't know whether this is better. If we read from stdin or the stdin has been redirected and the encoding was not UTF-8 and did contain multibyte characters the reader will show errors.
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.
#99 to update Plexus didn't flake, so possibly the plexus-utils update there fixes this?
I don't think. It might be node specific that |
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 it's the Temp directory that's at fault, there might be a way to avoid that.
What is your proposal then? |
@eolivelli