subesokun / atom-tree-view-git-status

Shows the Git repository status in the Atom tree-view
MIT License
24 stars 2 forks source link

Uncaught Error: ENOENT: no such file or directory, lstat '/Users/xo/node/node-diskusage' #10

Closed OmgImAlexis closed 9 years ago

OmgImAlexis commented 9 years ago

[Enter steps to reproduce below:]

  1. Deleted the directory while Atom was still open
  2. Open the tree-view menu

Atom Version: 1.0.11 System: Mac OS X 10.10.5 Thrown From: tree-view-git-status package, v0.2.0

Stack Trace

Uncaught Error: ENOENT: no such file or directory, lstat '/Users/xo/node/node-diskusage'

At ATOM_SHELL_ASAR.js:50

Error: ENOENT: no such file or directory, lstat '/Users/xo/node/node-diskusage'
    at Error (native)
    at fs.lstatSync (fs.js:836:18)
    at Object.fs.lstatSync (ATOM_SHELL_ASAR.js:170:16)
    at Object.realpathSync (fs.js:1439:21)
    at Object.fs.realpathSync (ATOM_SHELL_ASAR.js:243:29)
    at Object.module.exports.TreeViewGitStatus.normalizePath (/Users/xo/.atom/packages/tree-view-git-status/lib/main.coffee:293:15)
    at Object.module.exports.TreeViewGitStatus.updateRootForRepo (/Users/xo/.atom/packages/tree-view-git-status/lib/main.coffee:210:19)
    at /Users/xo/.atom/packages/tree-view-git-status/lib/main.coffee:185:8
    at Emitter.module.exports.Emitter.emit (/opt/homebrew-cask/Caskroom/atom/latest/Atom.app/Contents/Resources/app.asar/node_modules/event-kit/lib/emitter.js:82:11)
    at Task.callback (/opt/homebrew-cask/Caskroom/atom/latest/Atom.app/Contents/Resources/app.asar/src/git-repository.js:419:34)

Commands

     -5:38.8.0 editor:select-to-first-character-of-line (atom-text-editor.editor.is-focused)
     -5:38.4.0 core:cut (atom-text-editor.editor.is-focused)
     -5:38 editor:select-to-first-character-of-line (atom-text-editor.editor.is-focused)
  2x -5:37.7.0 core:backspace (atom-text-editor.editor.is-focused)
     -5:37.3.0 core:save (atom-text-editor.editor.is-focused)
  4x -5:14.3.0 core:undo (atom-text-editor.editor.is-focused)
  5x -5:12 core:redo (atom-text-editor.editor.is-focused)
     -5:10.5.0 core:save (atom-text-editor.editor.is-focused)
     -4:49.9.0 editor:select-to-first-character-of-line (atom-text-editor.editor.is-focused)
     -4:49.8.0 core:cut (atom-text-editor.editor.is-focused)
     -4:49.4.0 editor:select-to-first-character-of-line (atom-text-editor.editor.is-focused)
  2x -4:49.1.0 core:backspace (atom-text-editor.editor.is-focused)
  2x -4:48.3.0 core:save (atom-text-editor.editor.is-focused)
     -4:23.8.0 application:new-file (ul.list-inline.tab-bar.inset-panel)
     -4:23.4.0 core:paste (atom-text-editor.editor.is-focused)
     -4:19.4.0 core:move-up (atom-text-editor.editor.is-focused)

Config

{
  "core": {
    "themes": [
      "seti-ui",
      "seti-syntax"
    ],
    "ignoredNames": [
      ".DS_Store",
      "Thumbs.db"
    ],
    "openEmptyEditorOnStart": false
  }
}

Installed Packages

# User
atom-jade, v0.3.0
autohide-tree-view, v0.24.3
language-mako, v0.5.0
language-python-django-templates, v0.1.0
merge-conflicts, vundefined
seti-syntax, v0.4.0
seti-ui, v0.8.0
tabs-to-spaces, v0.11.1
tree-view-git-status, v0.2.0
wakatime, v4.0.17

# Dev
No dev packages
subesokun commented 9 years ago

Hi @OmgImAlexis! In general tree-view-git-status is working for you and you get this error only when you manually delete the folder while Atom is still running or? I just want to make sure that you're not running into the same issue as in #9

I'll try to get this weekend a bug fix ready for that.

OmgImAlexis commented 9 years ago

Yes, that's what's happening. Other than the error message, it doesn't cause any problems it's just an inconvenience to close it.

subesokun commented 9 years ago

The error should be fixed now via https://github.com/subesokun/atom-tree-view-git-status/commit/631b99b0b7e9035e2235a5a3a86e51157d7aadcd but I've noticed that in your described scenario the tree-view doesn't get correctly cleaned up internally. I'll close this issue as soon as I've fixed that as well.

subesokun commented 9 years ago

I'll track the cleanup issue in #13 so I'll be closing this one.