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

Update jgit #407

Merged
merged 2 commits into from
Jun 14, 2019
Merged

Update jgit #407

merged 2 commits into from
Jun 14, 2019

Conversation

wreulicke
Copy link
Contributor

@wreulicke wreulicke commented Jun 13, 2019

Update jgit

  • a summary of the change
  • either
    • a link to the issue you are resolving (for small changes)
    • a link to the PR you just created (for big changes likely to have discussion)

Note

The branch of this PR is based on #408.
rebased

@wreulicke wreulicke force-pushed the feature/update-jgit branch 2 times, most recently from b9ff352 to c676e4a Compare June 13, 2019 01:23
@nedtwigg
Copy link
Member

Is there a particular reason for the version bump? I've been hoping for https://git.eclipse.org/r/#/c/126454/ to land so that we can fix #75, but the change keeps getting buried in whitespace controversy.

@wreulicke
Copy link
Contributor Author

@nedtwigg

Is there a particular reason for the version bump?

jgit has dependency to httpcomponents.
It is so old version, so other gradle plugin that has dependency of httpcomponents is broken in the project with spotless on gradle.

@nedtwigg
Copy link
Member

nedtwigg commented Jun 13, 2019

Great! Can you add something to that effect in the changelog? For lib, plugin-gradle, and plugin-maven.

@wreulicke
Copy link
Contributor Author

Great! Can you add something to that effect in the changelog? For lib, plugin-gradle, and plugin-maven.

I will

@wreulicke
Copy link
Contributor Author

@nedtwigg
added.

@wreulicke
Copy link
Contributor Author

@nedtwigg
Could you review again?

@nedtwigg nedtwigg merged commit 286f7a8 into diffplug:master Jun 14, 2019
@nedtwigg
Copy link
Member

Thanks @wreulicke. I'm hoping we can get #328 into this release too. I'll publish on Monday either way.

@wreulicke
Copy link
Contributor Author

thanks a lot

@nedtwigg
Copy link
Member

Released in x.23.1

@wreulicke wreulicke deleted the feature/update-jgit branch June 18, 2019 16:15
@wreulicke
Copy link
Contributor Author

Congratulations! Thanks!
I will try it!

@basil
Copy link

basil commented Jul 24, 2019

FYI, this upgrade caused a hang for me when running Spotless, but only on NFS:

"Execution worker for ':' Thread 3" #31 prio=5 os_prio=0 tid=0x00007f87f25c3000 nid=0xbe8 waiting on condition [0x00007f872baf6000]
   java.lang.Thread.State: TIMED_WAITING (sleeping)
	at java.lang.Thread.sleep(Native Method)
	at java.lang.Thread.sleep(Thread.java:340)
	at java.util.concurrent.TimeUnit.sleep(TimeUnit.java:386)
	at org.eclipse.jgit.util.FS$FileStoreAttributeCache.<init>(FS.java:240)
	at org.eclipse.jgit.util.FS$FileStoreAttributeCache.getFsTimestampResolution(FS.java:211)
	at org.eclipse.jgit.util.FS.getFsTimerResolution(FS.java:321)
	at org.eclipse.jgit.internal.storage.file.FileSnapshot.<init>(FileSnapshot.java:186)
	at org.eclipse.jgit.internal.storage.file.FileSnapshot.save(FileSnapshot.java:122)
	at org.eclipse.jgit.storage.file.FileBasedConfig.load(FileBasedConfig.java:155)
	at com.diffplug.spotless.extra.GitAttributesLineEndings$FileState$$Lambda$109/391424876.run(Unknown Source)
	at com.diffplug.common.base.Errors.lambda$wrap$5(Errors.java:218)
	at com.diffplug.common.base.Errors$$Lambda$107/1270883703.run(Unknown Source)
	at com.diffplug.common.base.Errors.run(Errors.java:210)
	at com.diffplug.spotless.extra.GitAttributesLineEndings$FileState.<init>(GitAttributesLineEndings.java:180)
	at com.diffplug.spotless.extra.GitAttributesLineEndings$Policy.calculateState(GitAttributesLineEndings.java:92)
	at com.diffplug.spotless.extra.GitAttributesLineEndings$Policy.calculateState(GitAttributesLineEndings.java:79)
	at com.diffplug.spotless.LazyForwardingEquality.state(LazyForwardingEquality.java:56)
	- locked <0x00000000c1f6d918> (a com.diffplug.spotless.extra.GitAttributesLineEndings$Policy)
	at com.diffplug.spotless.LazyForwardingEquality.writeObject(LazyForwardingEquality.java:68)
[...]

I looked into it further and tracked the issue down to eclipse/jgit@b513b7747713a505e19e237ac2e7f8d9c699bc4d. When I downgraded to jgit 5.3.1.201904271842-r (which doesn't have that commit), the problem went away:

buildscript {
  configurations.classpath {
    resolutionStrategy {
      force 'org.eclipse.jgit:org.eclipse.jgit:5.3.1.201904271842-r'
    }
  }
}

@nedtwigg
Copy link
Member

Thanks for letting us know, especially the workaround. I assume that 5.4.0 won't help either, since it's only a few days newer than 5.3.2. Do you know if there's an existing bug in the jgit tracker for this?

@basil
Copy link

basil commented Jul 24, 2019

jgit bug 548188 has a reference to what appears to be a fix checked in on July 4. I haven't been able to determine if that fix has been released yet.

@nedtwigg
Copy link
Member

The very latest release was June 14, so it hasn't been released yet. We have another outstanding bug related to this jgit update in #410. Its fix was merged into jgit on July 17th. So I believe that both this and that will be resolved at the same time when the next jgit comes out.

@nedtwigg nedtwigg mentioned this pull request Aug 26, 2019
3 tasks
@nedtwigg
Copy link
Member

Updated to latest again in 3.24.3

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.

3 participants