Skip to content
This repository has been archived by the owner on Nov 15, 2022. It is now read-only.

Diff - Editor is not responding #355

Closed
tststs opened this issue Dec 27, 2015 · 8 comments
Closed

Diff - Editor is not responding #355

tststs opened this issue Dec 27, 2015 · 8 comments

Comments

@tststs
Copy link

tststs commented Dec 27, 2015

As the title says, the editor is unresponsive every time i trigger Diff via the package menu.
Caused by any file that has changes.

Nothing is thrown before the editor is becoming unresponsive. Just the dialog with keep waiting and close appears after some time.

  • Atom 1.3.2
  • git-plus 5.8.2
  • OSX 10.11.2 (15C50)
@akonwi
Copy link
Owner

akonwi commented Dec 27, 2015

I can't reproduce this. You may be able to do some debugging for me though. Take a look at this file and maybe you can spot something that could be causing the problem. I'd also suggest, opening that file locally and adding some breakpoints to see where the problem starts

@akonwi
Copy link
Owner

akonwi commented Dec 27, 2015

I did notice there was an unresolved promise when there were no diffs to show. I'm not sure that was the problem though because it should have had the same effects for everyone

@tststs
Copy link
Author

tststs commented Dec 27, 2015

Sure thing. It's getting late here, so i'll have a look at this tomorrow.

If there are no diffs to show, the info notification pops up correctly and everything is working fine. It seems it only happens if there are diffs.

I'll come back to this tomorrow.

Greetings from Berlin.

@tststs
Copy link
Author

tststs commented Dec 28, 2015

It is caused by this line of code: splitPane.coffee.

The editor gets unresponsive if the returned method from directions[splitDirection] is executed.
In this case it is:

splitPane.coffee:14 () {
  return pane.splitRight(options);
}

After further investigation, the editor only is becoming unresponsive if options = { copyActiveItem: true } is set. If i set options = { copyActiveItem: false } it opens the pane (with no content) but the editor is not becoming unresponsive. Maybe that helps.

@tststs
Copy link
Author

tststs commented Dec 28, 2015

This is the content of the atom_git_plus.diff file.
The text editor with this content pops up right before the editor gets unresponsive.

diff --git a/www/js/controllers.js b/www/js/controllers.js
index 46c98fe..a48840d 100644
--- a/www/js/controllers.js
+++ b/www/js/controllers.js
@@ -16,6 +16,7 @@ angular.module('xxxxxx.controllers', [])
  this.goTo = function (state, params) {

    $state.go(state, params || {});

  };

  this.init();

@akonwi
Copy link
Owner

akonwi commented Dec 29, 2015

This does help a bit. Issue #354 is related to this splitPane module as well. I'm working to get rid of that module and have a more direct way of splitting the panes

@akonwi akonwi closed this as completed in 890d9d1 Jan 12, 2016
@tststs
Copy link
Author

tststs commented Jan 14, 2016

👍 works like a charm

@akonwi
Copy link
Owner

akonwi commented Jan 15, 2016

Awesome!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants