afrog icon indicating copy to clipboard operation
afrog copied to clipboard

Deleting an open file from the tree view causes an exception in the console

Open cmatthew opened this issue 12 years ago • 5 comments

In Atom 0.98.0, deleting a file from the tree view which is also open causes the below exception. It probably should not.

Uncaught TypeError: Cannot call method 'getBufferPosition' of undefined /Applications/Atom.app/Contents/Resources/app/src/editor.js:1321 module.exports.Editor.getCursorBufferPosition /Applications/Atom.app/Contents/Resources/app/src/editor.js:1321 StatusBarView.render statusbar-view.coffee:18 LinterView.displayStatusBar linter-view.coffee:163 (anonymous function) linter-view.coffee:41 jQuery.event.dispatch /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4676 elemData.handle /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4360 jQuery.event.trigger /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4594 (anonymous function) /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:5119 jQuery.extend.each /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:590 jQuery.fn.jQuery.each /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:237 jQuery.fn.extend.trigger /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:5118 module.exports.PaneView.onActiveItemChanged /Applications/Atom.app/Contents/Resources/app/src/pane-view.js:305 (anonymous function) /Applications/Atom.app/Contents/Resources/app/src/pane-view.js:3 (anonymous function) /Applications/Atom.app/Contents/Resources/app/node_modules/emissary/lib/emitter.js:133 module.exports.Emitter.emit /Applications/Atom.app/Contents/Resources/app/node_modules/emissary/lib/emitter.js:132 module.exports.Behavior.emit /Applications/Atom.app/Contents/Resources/app/node_modules/emissary/lib/behavior.js:44 module.exports.Signal.emitValue /Applications/Atom.app/Contents/Resources/app/node_modules/emissary/lib/signal.js:82 module.exports.Model.set /Applications/Atom.app/Contents/Resources/app/node_modules/theorist/lib/model.js:166 accessor.set /Applications/Atom.app/Contents/Resources/app/node_modules/theorist/lib/model.js:57 module.exports.Pane.activateItem /Applications/Atom.app/Contents/Resources/app/src/pane.js:175 _results.push._this.(anonymous function) /Applications/Atom.app/Contents/Resources/app/node_modules/delegato/lib/delegator.js:67 (anonymous function) /Applications/Atom.app/Contents/Resources/app/node_modules/tabs/lib/tab-bar-view.js:148 jQuery.event.dispatch /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4676 elemData.handle /Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4360

cmatthew avatar May 26 '14 22:05 cmatthew

Duplicate of atom/tree-view#150. I don't know if the Issue should be open here or on Tree View given that there are a lot of repros showing up that don't necessarily have to do with the tree view.

Also duplicate of #2404 et al

lee-dohm avatar May 26 '14 23:05 lee-dohm

Suspecting this is an issue with the Linter package, based on these lines in the stack trace:

...
module.exports.Editor.getCursorBufferPosition /Applications/Atom.app/Contents/Resources/app/src/editor.js:1321
StatusBarView.render statusbar-view.coffee:18
LinterView.displayStatusBar linter-view.coffee:163
(anonymous function) linter-view.coffee:41
...

Can you reproduce this issue with the Linter package disabled? Try starting Atom from the terminal like this at let us know if you can still reproduce this:

$ atom --safe

izuzak avatar May 29 '14 09:05 izuzak

I get a single exception in safe mode when I delete the file: Uncaught TypeError: Cannot call method 'getScreenRow' of undefined in /Applications/Atom.app/Contents/Resources/app/src/editor.js:1311

cmatthew avatar May 29 '14 17:05 cmatthew

I get a single exception in safe mode when I delete the file: Uncaught TypeError: Cannot call method 'getScreenRow' of undefined in /Applications/Atom.app/Contents/Resources/app/src/editor.js:1311

Thanks @cmatthew! The error you're getting now seems like something that was fixed yesterday in atom/bracket-matcher#35.

If you're building Atom from source, try pulling the latest version and rebuild -- that should solve the issue. If you're using released versions -- this issue should be fixed in 0.100.0 once it's released. Please post a comment here if it isn't, I'm closing this issue for now.

izuzak avatar May 29 '14 19:05 izuzak

This issue has been automatically locked since there has not been any recent activity after it was closed. If you can still reproduce this issue in Safe Mode then please open a new issue and fill out the entire issue template to ensure that we have enough information to address your issue. Thanks!

lock[bot] avatar Jan 26 '19 10:01 lock[bot]