<p dir="auto">When changing branches in git while one of the files that are being rewritten (due to the branch switch) is open in atom this happens:</p>
<p dir="auto"><strong>Atom Version</strong>: 0.199.0<br>
<strong>System</strong>: linux 3.14.39-1-lts<br>
<strong>Thrown From</strong>: Atom Core</p>
<h3 dir="auto">Stack Trace</h3>
<p dir="auto">Uncaught Error: ENOENT: no such file or directory, open '/home/despairblue/vcs/git/scegratoo3/app/scripts/services/treenodeattribute.js'</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At events.js:141

Error: ENOENT: no such file or directory, open '/home/despairblue/vcs/git/scegratoo3/app/scripts/services/treenodeattribute.js'
  at Error (native)
"><pre class="notranslate"><code class="notranslate">At events.js:141

Error: ENOENT: no such file or directory, open '/home/despairblue/vcs/git/scegratoo3/app/scripts/services/treenodeattribute.js'
  at Error (native)

</code></pre></div>
<h3 dir="auto">Commands</h3>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="     -0:48.2.0 symbols-view:toggle-file-symbols (atom-text-editor.editor.is-focused)
     -0:47.5.0 editor:consolidate-selections (atom-text-editor.editor.mini.is-focused)
     -0:47.5.0 core:cancel (atom-text-editor.editor.mini.is-focused)
     -0:46.1.0 command-palette:toggle (atom-text-editor.editor.is-focused)
     -0:43 core:backspace (atom-text-editor.editor.mini.is-focused)
     -0:40.9.0 core:confirm (atom-text-editor.editor.mini.is-focused)
     -0:40.9.0 git-plus:new-branch (atom-text-editor.editor)
  6x -0:36.8.0 core:backspace (atom-text-editor.editor.mini.is-focused)
  3x -0:27.5.0 editor:move-to-beginning-of-word (atom-text-editor.editor.mini.is-focused)
     -0:25 core:confirm (atom-text-editor.editor.mini.is-focused)"><pre class="notranslate"><code class="notranslate">     -0:48.2.0 symbols-view:toggle-file-symbols (atom-text-editor.editor.is-focused)
     -0:47.5.0 editor:consolidate-selections (atom-text-editor.editor.mini.is-focused)
     -0:47.5.0 core:cancel (atom-text-editor.editor.mini.is-focused)
     -0:46.1.0 command-palette:toggle (atom-text-editor.editor.is-focused)
     -0:43 core:backspace (atom-text-editor.editor.mini.is-focused)
     -0:40.9.0 core:confirm (atom-text-editor.editor.mini.is-focused)
     -0:40.9.0 git-plus:new-branch (atom-text-editor.editor)
  6x -0:36.8.0 core:backspace (atom-text-editor.editor.mini.is-focused)
  3x -0:27.5.0 editor:move-to-beginning-of-word (atom-text-editor.editor.mini.is-focused)
     -0:25 core:confirm (atom-text-editor.editor.mini.is-focused)
</code></pre></div>
<h3 dir="auto">Config</h3>
<div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{
  &quot;core&quot;: {
    &quot;excludeVcsIgnoredPaths&quot;: false,
    &quot;disabledPackages&quot;: [
      &quot;welcome&quot;,
      &quot;metrics&quot;,
      &quot;autocomplete&quot;,
      &quot;incremental-search&quot;,
      &quot;Tern&quot;,
      &quot;grunt-runner&quot;,
      &quot;tree-view-open-files&quot;,
      &quot;tree-view-breadcrumb&quot;,
      &quot;atomatigit&quot;,
      &quot;themed-settings&quot;,
      &quot;linter-scspell&quot;,
      &quot;filetype-color&quot;,
      &quot;atom-pair&quot;,
      &quot;linter-eslint&quot;,
      &quot;es-navigation&quot;,
      &quot;autocomplete&quot;,
      &quot;tab-smart-sort&quot;,
      &quot;starred-package-installer&quot;,
      &quot;zentabs&quot;,
      &quot;linter-jshint&quot;,
      &quot;block-cursor&quot;,
      &quot;test-status&quot;,
      &quot;minimap&quot;,
      &quot;minimap-color-highlight&quot;,
      &quot;minimap-find-and-replace&quot;,
      &quot;minimap-git-diff&quot;,
      &quot;minimap-highlight-selected&quot;,
      &quot;travis-ci-status&quot;,
      &quot;pane-layout-plus&quot;,
      &quot;symbols-tree-view&quot;,
      &quot;package-cop&quot;,
      &quot;navigate&quot;
    ],
    &quot;projectHome&quot;: &quot;/home/despairblue/vcs/git/&quot;,
    &quot;destroyEmptyPanes&quot;: false,
    &quot;themes&quot;: [
      &quot;one-dark-ui&quot;,
      &quot;solarized-dark-syntax&quot;
    ],
    &quot;autoHideMenuBar&quot;: true
  },
  &quot;editor&quot;: {
    &quot;fontFamily&quot;: &quot;Source Code Pro, Symbola, Droid Sans Fallback&quot;,
    &quot;lineHeight&quot;: 1.4,
    &quot;showIndentGuide&quot;: true,
    &quot;scrollPastEnd&quot;: true,
    &quot;invisibles&quot;: {},
    &quot;fontSize&quot;: 13,
    &quot;softWrap&quot;: true
  }
}"><pre class="notranslate">{
  <span class="pl-ent">"core"</span>: {
    <span class="pl-ent">"excludeVcsIgnoredPaths"</span>: <span class="pl-c1">false</span>,
    <span class="pl-ent">"disabledPackages"</span>: [
      <span class="pl-s"><span class="pl-pds">"</span>welcome<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>metrics<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>autocomplete<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>incremental-search<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>Tern<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>grunt-runner<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>tree-view-open-files<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>tree-view-breadcrumb<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>atomatigit<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>themed-settings<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>linter-scspell<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>filetype-color<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>atom-pair<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>linter-eslint<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>es-navigation<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>autocomplete<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>tab-smart-sort<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>starred-package-installer<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>zentabs<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>linter-jshint<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>block-cursor<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>test-status<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>minimap<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>minimap-color-highlight<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>minimap-find-and-replace<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>minimap-git-diff<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>minimap-highlight-selected<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>travis-ci-status<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>pane-layout-plus<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>symbols-tree-view<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>package-cop<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>navigate<span class="pl-pds">"</span></span>
    ],
    <span class="pl-ent">"projectHome"</span>: <span class="pl-s"><span class="pl-pds">"</span>/home/despairblue/vcs/git/<span class="pl-pds">"</span></span>,
    <span class="pl-ent">"destroyEmptyPanes"</span>: <span class="pl-c1">false</span>,
    <span class="pl-ent">"themes"</span>: [
      <span class="pl-s"><span class="pl-pds">"</span>one-dark-ui<span class="pl-pds">"</span></span>,
      <span class="pl-s"><span class="pl-pds">"</span>solarized-dark-syntax<span class="pl-pds">"</span></span>
    ],
    <span class="pl-ent">"autoHideMenuBar"</span>: <span class="pl-c1">true</span>
  },
  <span class="pl-ent">"editor"</span>: {
    <span class="pl-ent">"fontFamily"</span>: <span class="pl-s"><span class="pl-pds">"</span>Source Code Pro, Symbola, Droid Sans Fallback<span class="pl-pds">"</span></span>,
    <span class="pl-ent">"lineHeight"</span>: <span class="pl-c1">1.4</span>,
    <span class="pl-ent">"showIndentGuide"</span>: <span class="pl-c1">true</span>,
    <span class="pl-ent">"scrollPastEnd"</span>: <span class="pl-c1">true</span>,
    <span class="pl-ent">"invisibles"</span>: {},
    <span class="pl-ent">"fontSize"</span>: <span class="pl-c1">13</span>,
    <span class="pl-ent">"softWrap"</span>: <span class="pl-c1">true</span>
  }
}</pre></div>
<h3 dir="auto">Installed Packages</h3>
<div class="highlight highlight-source-coffee notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# User
angularjs, v0.1.0
atom-alignment, v0.12.1
atom-color-highlight, v3.0.9
atom-ternjs, v0.5.30
atom-zeal, v0.1.0
autocomplete-emojis, v2.2.2
autocomplete-paths, v1.0.2
block-travel, v1.0.2
bug-report, v0.7.0
color-picker, v1.7.0
compare-files, v0.4.1
docblockr, v0.7.1
editorconfig, v1.0.0
file-icons, v1.5.5
git-log, v0.3.0
git-plus, v4.5.0
go-plus, v3.3.11
grammar-token-limit, v0.1.1
highlight-selected, v0.9.3
indentation-indicator, v0.5.1
javascript-snippets, v1.0.0
keybinding-cheatsheet, v0.0.9
language-dockerfile, v0.1.0
language-dot, v1.6.0
language-fish-shell, v1.0.2
language-haskell, v1.0.0
language-javascript-better, v1.5.0
language-latex, v0.6.1
language-nimrod, v0.1.0
language-puppet, v0.12.0
language-tss, v0.1.0
latex, v0.23.4
linter, v0.12.2
linter-coffeelint, v0.2.3
linter-htmlhint, v0.0.15
linter-js-standard, v0.2.5
linter-js-yaml, v1.0.1
linter-puppet-lint, v0.2.9
linter-shellcheck, v0.0.7
markdown-scroll-sync, v0.3.3
open-last-project, v0.4.1
pdf-view, v0.22.0
project-manager, v1.15.5
regex-railroad-diagram, v0.7.4
tabs-to-spaces, v0.10.0

# Dev
No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span>
angularjs, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span>
atom<span class="pl-k">-</span>alignment, v0.<span class="pl-ii">12</span>.<span class="pl-ii">1</span>
atom<span class="pl-k">-</span>color<span class="pl-k">-</span>highlight, v3.<span class="pl-ii">0</span>.<span class="pl-ii">9</span>
atom<span class="pl-k">-</span>ternjs, v0.<span class="pl-ii">5</span>.<span class="pl-ii">30</span>
atom<span class="pl-k">-</span>zeal, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span>
autocomplete<span class="pl-k">-</span>emojis, v2.<span class="pl-ii">2</span>.<span class="pl-ii">2</span>
autocomplete<span class="pl-k">-</span>paths, v1.<span class="pl-ii">0</span>.<span class="pl-ii">2</span>
block<span class="pl-k">-</span>travel, v1.<span class="pl-ii">0</span>.<span class="pl-ii">2</span>
bug<span class="pl-k">-</span>report, v0.<span class="pl-ii">7</span>.<span class="pl-ii">0</span>
color<span class="pl-k">-</span>picker, v1.<span class="pl-ii">7</span>.<span class="pl-ii">0</span>
compare<span class="pl-k">-</span>files, v0.<span class="pl-ii">4</span>.<span class="pl-ii">1</span>
docblockr, v0.<span class="pl-ii">7</span>.<span class="pl-ii">1</span>
editorconfig, v1.<span class="pl-ii">0</span>.<span class="pl-ii">0</span>
file<span class="pl-k">-</span>icons, v1.<span class="pl-ii">5</span>.<span class="pl-ii">5</span>
git<span class="pl-k">-</span>log, v0.<span class="pl-ii">3</span>.<span class="pl-ii">0</span>
git<span class="pl-k">-</span>plus, v4.<span class="pl-ii">5</span>.<span class="pl-ii">0</span>
go<span class="pl-k">-</span>plus, v3.<span class="pl-ii">3</span>.<span class="pl-ii">11</span>
grammar<span class="pl-k">-</span>token<span class="pl-k">-</span>limit, v0.<span class="pl-ii">1</span>.<span class="pl-ii">1</span>
highlight<span class="pl-k">-</span>selected, v0.<span class="pl-ii">9</span>.<span class="pl-ii">3</span>
indentation<span class="pl-k">-</span>indicator, v0.<span class="pl-ii">5</span>.<span class="pl-ii">1</span>
javascript<span class="pl-k">-</span>snippets, v1.<span class="pl-ii">0</span>.<span class="pl-ii">0</span>
keybinding<span class="pl-k">-</span>cheatsheet, v0.<span class="pl-ii">0</span>.<span class="pl-ii">9</span>
language<span class="pl-k">-</span>dockerfile, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>dot, v1.<span class="pl-ii">6</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>fish<span class="pl-k">-</span>shell, v1.<span class="pl-ii">0</span>.<span class="pl-ii">2</span>
language<span class="pl-k">-</span>haskell, v1.<span class="pl-ii">0</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>javascript<span class="pl-k">-</span>better, v1.<span class="pl-ii">5</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>latex, v0.<span class="pl-ii">6</span>.<span class="pl-ii">1</span>
language<span class="pl-k">-</span>nimrod, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>puppet, v0.<span class="pl-ii">12</span>.<span class="pl-ii">0</span>
language<span class="pl-k">-</span>tss, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span>
latex, v0.<span class="pl-ii">23</span>.<span class="pl-ii">4</span>
linter, v0.<span class="pl-ii">12</span>.<span class="pl-ii">2</span>
linter<span class="pl-k">-</span>coffeelint, v0.<span class="pl-ii">2</span>.<span class="pl-ii">3</span>
linter<span class="pl-k">-</span>htmlhint, v0.<span class="pl-ii">0</span>.<span class="pl-ii">15</span>
linter<span class="pl-k">-</span>js<span class="pl-k">-</span>standard, v0.<span class="pl-ii">2</span>.<span class="pl-ii">5</span>
linter<span class="pl-k">-</span>js<span class="pl-k">-</span>yaml, v1.<span class="pl-ii">0</span>.<span class="pl-ii">1</span>
linter<span class="pl-k">-</span>puppet<span class="pl-k">-</span>lint, v0.<span class="pl-ii">2</span>.<span class="pl-ii">9</span>
linter<span class="pl-k">-</span>shellcheck, v0.<span class="pl-ii">0</span>.<span class="pl-ii">7</span>
markdown<span class="pl-k">-</span>scroll<span class="pl-k">-</span>sync, v0.<span class="pl-ii">3</span>.<span class="pl-ii">3</span>
open<span class="pl-k">-</span>last<span class="pl-k">-</span>project, v0.<span class="pl-ii">4</span>.<span class="pl-ii">1</span>
pdf<span class="pl-k">-</span>view, v0.<span class="pl-ii">22</span>.<span class="pl-ii">0</span>
project<span class="pl-k">-</span>manager, v1.<span class="pl-ii">15</span>.<span class="pl-ii">5</span>
regex<span class="pl-k">-</span>railroad<span class="pl-k">-</span>diagram, v0.<span class="pl-ii">7</span>.<span class="pl-ii">4</span>
tabs<span class="pl-k">-</span>to<span class="pl-k">-</span>spaces, v0.<span class="pl-ii">10</span>.<span class="pl-ii">0</span>

<span class="pl-c"><span class="pl-c">#</span> Dev</span>
<span class="pl-en">No</span> <span class="pl-en">dev</span> packages</pre></div>
<p dir="auto">Some repro steps that I gathered from the existing issues:</p>
<ol dir="auto">
<li>Have a file open in branch <code class="notranslate">something</code> that doesn't exist in branch <code class="notranslate">atom</code></li>
<li><code class="notranslate">git checkout atom</code></li>
<li>ENOENT <g-emoji class="g-emoji" alias="boom" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f4a5.png">💥</g-emoji><br>
OR</li>
<li>Have a file open in Atom that will be affected by <code class="notranslate">git rebase</code></li>
<li><code class="notranslate">git rebase</code></li>
<li>ENOENT <g-emoji class="g-emoji" alias="-1" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f44e.png">👎</g-emoji><br>
OR<br>
Just simply rename a file outside of Atom that's currently open inside of Atom.</li>
</ol>