Skip to content

Error on glide project #13

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

Open
Ivan-Veselov opened this issue Aug 28, 2018 · 5 comments
Open

Error on glide project #13

Ivan-Veselov opened this issue Aug 28, 2018 · 5 comments
Labels
bug Something isn't working RefactoringDetectionTools

Comments

@Ivan-Veselov
Copy link
Contributor

Error happened during processing of commit bumptech/glide@86ea385

ERROR [org.jetbrains.research.groups.ml_methods.refactoring.detection.tools.DefaultBranchesDetectionTool.detect] - Error occurred during refactoring detection for repository: https://github.com/bumptech/glide.git
java.lang.RuntimeException: org.eclipse.jgit.api.errors.CheckoutConflictException: Checkout conflict with files: 
third_party/disklrucache
	at org.refactoringminer.api.RefactoringHandler.handleException(RefactoringHandler.java:50)
	at org.refactoringminer.rm1.GitHistoryRefactoringMinerImpl.detect(GitHistoryRefactoringMinerImpl.java:102)
	at org.refactoringminer.rm1.GitHistoryRefactoringMinerImpl.detectAll(GitHistoryRefactoringMinerImpl.java:280)
	at org.jetbrains.research.groups.ml_methods.refactoring.detection.tools.RMiner.detect(RMiner.java:181)
	at org.jetbrains.research.groups.ml_methods.refactoring.detection.tools.RMiner.detect(RMiner.java:35)
	at org.jetbrains.research.groups.ml_methods.refactoring.detection.tools.DefaultBranchesDetectionTool.detect(DefaultBranchesDetectionTool.java:46)
	at org.jetbrains.research.groups.ml_methods.refactoring.detection.RefactoringDetectionApplication.run(RefactoringDetectionApplication.java:71)
	at org.jetbrains.research.groups.ml_methods.refactoring.detection.RefactoringDetectionApplication.main(RefactoringDetectionApplication.java:31)
Caused by: org.eclipse.jgit.api.errors.CheckoutConflictException: Checkout conflict with files: 
third_party/disklrucache
	at org.eclipse.jgit.api.CheckoutCommand.call(CheckoutCommand.java:276)
	at org.refactoringminer.util.GitServiceImpl.checkout(GitServiceImpl.java:120)
	at org.refactoringminer.rm1.GitHistoryRefactoringMinerImpl.detectRefactorings(GitHistoryRefactoringMinerImpl.java:134)
	at org.refactoringminer.rm1.GitHistoryRefactoringMinerImpl.detect(GitHistoryRefactoringMinerImpl.java:97)
	... 6 more
Caused by: org.eclipse.jgit.errors.CheckoutConflictException: Checkout conflict with files: 
third_party/disklrucache
	at org.eclipse.jgit.dircache.DirCacheCheckout.doCheckout(DirCacheCheckout.java:467)
	at org.eclipse.jgit.dircache.DirCacheCheckout.checkout(DirCacheCheckout.java:449)
	at org.eclipse.jgit.api.CheckoutCommand.call(CheckoutCommand.java:272)
	... 9 more
@Ivan-Veselov Ivan-Veselov added bug Something isn't working RefactoringDetectionTools labels Aug 28, 2018
@Ivan-Veselov Ivan-Veselov self-assigned this Aug 28, 2018
@Ivan-Veselov
Copy link
Contributor Author

The problem is in git submodules.
Git.cloneRepository().setDirectory(new File("/tmp/glide")).setURI("https://github.com/bumptech/glide.git").setCloneAllBranches(true).call();
Such code with Eclipse git API clones repository with deleted submodules. This is exactly what happens inside RMiner. After that the problem arises only on mentioned commit.

@Ivan-Veselov
Copy link
Contributor Author

Adding setCloneSubmodules(true) to command builder solves the problem.

@Ivan-Veselov
Copy link
Contributor Author

But after that new problems arise.

@Ivan-Veselov
Copy link
Contributor Author

error: The following untracked working tree files would be overwritten by checkout:
	third_party/disklrucache/LICENSE
	third_party/disklrucache/README.third_party
Please move or remove them before you switch branches.
Aborting

@Ivan-Veselov
Copy link
Contributor Author

Problem is due to the fact that third_party/disklrucache/LICENSE and third_party/disklrucache/README.third_party were in repository until bumptech/glide@86ea385. This raises conflicts during checkout on parent of that commit.

@Ivan-Veselov Ivan-Veselov removed their assignment Aug 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working RefactoringDetectionTools
Projects
None yet
Development

No branches or pull requests

1 participant