dpo / atom-python-debugger

IDE-like Python debugger for Atom
MIT License
42 stars 13 forks source link

Uncaught TypeError: Cannot read property 'file' of undefined #9

Closed zakkhoyt closed 7 years ago

zakkhoyt commented 8 years ago

[Enter steps to reproduce below:]

Just tried to open the python debugger from the packages menu

Atom Version: 1.9.2 System: Mac OS X 10.11.6 Thrown From: python-debugger package, v0.1.0

Stack Trace

Uncaught TypeError: Cannot read property 'file' of undefined

At /Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger-view.coffee:19

TypeError: Cannot read property 'file' of undefined
    at PythonDebuggerView.module.exports.PythonDebuggerView.getCurrentFilePath (/Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger-view.coffee:19:26)
    at PythonDebuggerView.module.exports.PythonDebuggerView.initialize (/Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger-view.coffee:156:26)
    at PythonDebuggerView.View [as constructor] (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-space-pen-views/node_modules/space-pen/lib/space-pen.js:184:25)
    at new PythonDebuggerView (/Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger-view.coffee:12:3)
    at Object.module.exports.PythonDebugger.createDebuggerView (/Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger.coffee:18:33)
    at atom-workspace.subscriptions.add.atom.commands.add.python-debugger:toggle (/Users/zakkhoyt/.atom/packages/python-debugger/lib/python-debugger.coffee:28:37)
    at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:260:29)
    at CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:3:61)
    at CommandRegistry.module.exports.CommandRegistry.dispatch (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:160:19)
    at AtomEnvironment.module.exports.AtomEnvironment.dispatchApplicationMenuCommand (/Applications/Atom.app/Contents/Resources/app.asar/src/atom-environment.js:1104:28)
    at EventEmitter.outerCallback (/Applications/Atom.app/Contents/Resources/app.asar/src/application-delegate.js:327:25)
    at emitTwo (events.js:100:13)
    at EventEmitter.emit (events.js:185:7)

Commands

     -0:00.2.0 python-debugger:toggle (table.package-keymap-table.table.native-key-bindings.text)

Config

{
  "core": {
    "projectHome": "~/Code/repositories"
  }
}

Installed Packages

# User
language-python, v0.45.0 (active)
python-debugger, v0.1.0 (inactive)
atom-dark-syntax, v0.27.0 (inactive)
atom-dark-ui, v0.51.0 (inactive)
atom-light-syntax, v0.28.0 (inactive)
atom-light-ui, v0.43.0 (inactive)
base16-tomorrow-dark-theme, v1.1.0 (inactive)
base16-tomorrow-light-theme, v1.1.1 (inactive)
one-dark-ui, v1.3.2 (active)
one-light-ui, v1.3.2 (inactive)
one-dark-syntax, v1.2.0 (active)
one-light-syntax, v1.2.0 (inactive)
solarized-dark-syntax, v1.0.2 (inactive)
solarized-light-syntax, v1.0.2 (inactive)
about, v1.5.2 (active)
archive-view, v0.61.1 (active)
autocomplete-atom-api, v0.10.0 (active)
autocomplete-css, v0.11.1 (active)
autocomplete-html, v0.7.2 (active)
autocomplete-plus, v2.31.0 (active)
autocomplete-snippets, v1.11.0 (active)
autoflow, v0.27.0 (inactive)
autosave, v0.23.1 (active)
background-tips, v0.26.0 (active)
bookmarks, v0.41.0 (active)
bracket-matcher, v0.82.1 (active)
command-palette, v0.38.0 (inactive)
deprecation-cop, v0.54.1 (active)
dev-live-reload, v0.47.0 (active)
encoding-selector, v0.22.0 (active)
exception-reporting, v0.38.1 (active)
fuzzy-finder, v1.3.0 (active)
git-diff, v1.1.0 (active)
find-and-replace, v0.198.0 (inactive)
go-to-line, v0.31.0 (inactive)
grammar-selector, v0.48.1 (active)
image-view, v0.58.0 (active)
incompatible-packages, v0.26.1 (active)
keybinding-resolver, v0.35.0 (active)
line-ending-selector, v0.5.0 (active)
link, v0.31.1 (inactive)
markdown-preview, v0.158.0 (active)
metrics, v0.53.1 (active)
notifications, v0.64.1 (active)
open-on-github, v1.2.0 (inactive)
package-generator, v1.0.0 (inactive)
settings-view, v0.238.0 (active)
snippets, v1.0.2 (active)
spell-check, v0.67.1 (active)
status-bar, v1.4.0 (active)
styleguide, v0.46.0 (active)
symbols-view, v0.113.0 (inactive)
tabs, v0.98.0 (active)
timecop, v0.33.1 (active)
tree-view, v0.208.0 (active)
update-package-dependencies, v0.10.0 (active)
welcome, v0.34.0 (active)
whitespace, v0.32.2 (active)
wrap-guide, v0.38.1 (active)
language-c, v0.52.1 (active)
language-clojure, v0.21.0 (active)
language-coffee-script, v0.47.0 (active)
language-csharp, v0.12.1 (active)
language-css, v0.36.2 (active)
language-gfm, v0.86.0 (active)
language-git, v0.13.0 (active)
language-go, v0.42.0 (active)
language-html, v0.44.1 (active)
language-hyperlink, v0.16.0 (active)
language-java, v0.22.0 (active)
language-javascript, v0.119.0 (active)
language-json, v0.18.0 (active)
language-less, v0.29.3 (active)
language-make, v0.22.2 (active)
language-mustache, v0.13.0 (active)
language-objective-c, v0.15.1 (active)
language-perl, v0.35.0 (active)
language-php, v0.37.0 (active)
language-property-list, v0.8.0 (active)
language-python, v0.45.0 (active)
language-ruby, v0.68.5 (active)
language-ruby-on-rails, v0.25.0 (active)
language-sass, v0.52.0 (active)
language-shellscript, v0.22.3 (active)
language-source, v0.9.0 (active)
language-sql, v0.21.1 (active)
language-text, v0.7.1 (active)
language-todo, v0.28.0 (active)
language-toml, v0.18.0 (active)
language-xml, v0.34.8 (active)
language-yaml, v0.26.0 (active)

# Dev
No dev packages
dpo commented 8 years ago

I'm currently traveling and I'll look into this when I return. In the meantime, if you find how to fix the issue, I'll definitely welcome a pull request.

dpo commented 7 years ago

Sorry for the long wait. I'm not able to reproduce this. Are you still having the same issue? (I'm on Atom 1.10.2.) Thanks.

zakkhoyt commented 7 years ago

No worries, I understand. It can be hard to tend to all projects all the time.

Sorry, but I don't have any feedback for you at this time. I was using your tool for a quick project and have since moved on. I'll let you know if I come back to it and am having issue.

Thanks, -Zakk

On Tue, Sep 20, 2016 at 3:08 PM, Dominique notifications@github.com wrote:

Sorry for the long wait. I'm not able to reproduce this. Are you still having the same issue? (I'm on Atom 1.10.2.) Thanks.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/dpo/atom-python-debugger/issues/9#issuecomment-248450006, or mute the thread https://github.com/notifications/unsubscribe-auth/ACIEoLYCVyVgRJ-RlF_y8BtXn9XvsfbBks5qsFl6gaJpZM4JcTh3 .

dpo commented 7 years ago

Ok thanks. I'll go ahead and close this but feel free to open a new issue if problems persist.

fdobrovolny commented 7 years ago

I still have this issue. @dpo

Steps to reproduce

  1. Select Packages > Python-debugger > Toggle on Search page

Atom Version: 1.10.2 Electron Version: 0.37.8 System: "Fedora release Thrown From: python-debugger package, v0.1.0

Stack Trace

Uncaught TypeError: Cannot read property 'file' of undefined

At /home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger-view.coffee:19

TypeError: Cannot read property 'file' of undefined
    at PythonDebuggerView.module.exports.PythonDebuggerView.getCurrentFilePath (/home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger-view.coffee:19:26)
    at PythonDebuggerView.module.exports.PythonDebuggerView.initialize (/home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger-view.coffee:156:26)
    at PythonDebuggerView.View [as constructor] (/home/fdobrovo/.atom/packages/python-debugger/node_modules/space-pen/lib/space-pen.js:184:25)
    at new PythonDebuggerView (/home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger-view.coffee:12:3)
    at Object.module.exports.PythonDebugger.createDebuggerView (/home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger.coffee:18:33)
    at atom-workspace.subscriptions.add.atom.commands.add.python-debugger:toggle (/home/fdobrovo/.atom/packages/python-debugger/lib/python-debugger.coffee:28:37)
    at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/usr/share/atom/resources/app.asar/src/command-registry.js:260:29)
    at CommandRegistry.handleCommandEvent (/usr/share/atom/resources/app.asar/src/command-registry.js:3:61)
    at CommandRegistry.module.exports.CommandRegistry.dispatch (/usr/share/atom/resources/app.asar/src/command-registry.js:160:19)
    at AtomEnvironment.module.exports.AtomEnvironment.dispatchApplicationMenuCommand (/usr/share/atom/resources/app.asar/src/atom-environment.js:1109:28)
    at EventEmitter.outerCallback (/usr/share/atom/resources/app.asar/src/application-delegate.js:329:25)
    at emitTwo (events.js:100:13)
    at EventEmitter.emit (events.js:185:7)

Commands

     -0:26.3.0 settings-view:open (atom-text-editor.editor.is-focused)
     -0:18.6.0 core:confirm (atom-text-editor.editor.mini.is-focused)
     -0:00.2.0 python-debugger:toggle (ol.tree-view.full-menu.list-tree.has-collapsable-children.focusable-panel)

Config

{
  "core": {
    "themes": [
      "one-light-ui",
      "one-light-syntax"
    ]
  }
}

Installed Packages

# User
autocomplete-python, v1.8.12 (active)
linter, v1.11.18 (active)
linter-flake8, v2.1.1 (active)
linter-pydocstyle, v0.4.3 (active)
minimap, v4.25.6 (active)
minimap-bookmarks, v0.4.2 (active)
minimap-cursorline, v0.2.0 (active)
minimap-find-and-replace, v4.5.1 (active)
minimap-highlight-selected, v4.4.0 (active)
minimap-linter, v1.6.0 (active)
python-debugger, v0.1.0 (inactive)
python-indent, v1.0.0 (active)
python-isort, v0.0.7 (active)
python-tools, v0.6.8 (active)
atom-dark-syntax, v0.27.0 (inactive)
atom-dark-ui, v0.52.0 (inactive)
atom-light-syntax, v0.28.0 (inactive)
atom-light-ui, v0.44.0 (inactive)
base16-tomorrow-dark-theme, v1.1.0 (inactive)
base16-tomorrow-light-theme, v1.1.1 (inactive)
one-dark-ui, v1.5.0 (inactive)
one-light-ui, v1.5.0 (active)
one-dark-syntax, v1.3.0 (inactive)
one-light-syntax, v1.3.0 (active)
solarized-dark-syntax, v1.0.2 (inactive)
solarized-light-syntax, v1.0.2 (inactive)
about, v1.5.3 (active)
archive-view, v0.61.1 (active)
autocomplete-atom-api, v0.10.0 (active)
autocomplete-css, v0.11.2 (active)
autocomplete-html, v0.7.2 (active)
autocomplete-plus, v2.31.1 (active)
autocomplete-snippets, v1.11.0 (active)
autoflow, v0.27.0 (inactive)
autosave, v0.23.1 (active)
background-tips, v0.26.1 (active)
bookmarks, v0.41.0 (active)
bracket-matcher, v0.82.1 (active)
command-palette, v0.38.0 (inactive)
deprecation-cop, v0.54.1 (active)
dev-live-reload, v0.47.0 (active)
encoding-selector, v0.22.0 (active)
exception-reporting, v0.39.0 (active)
find-and-replace, v0.201.0 (active)
fuzzy-finder, v1.3.0 (active)
git-diff, v1.1.0 (active)
go-to-line, v0.31.0 (inactive)
grammar-selector, v0.48.1 (active)
image-view, v0.58.2 (active)
incompatible-packages, v0.26.1 (active)
keybinding-resolver, v0.35.0 (active)
line-ending-selector, v0.5.0 (active)
link, v0.31.1 (inactive)
markdown-preview, v0.158.0 (active)
metrics, v0.53.1 (active)
notifications, v0.65.0 (active)
open-on-github, v1.2.0 (inactive)
package-generator, v1.0.0 (inactive)
settings-view, v0.242.2 (active)
snippets, v1.0.2 (active)
spell-check, v0.67.1 (active)
status-bar, v1.4.1 (active)
styleguide, v0.47.0 (active)
symbols-view, v0.113.0 (inactive)
tabs, v0.100.2 (active)
timecop, v0.33.2 (active)
tree-view, v0.208.2 (active)
update-package-dependencies, v0.10.0 (active)
welcome, v0.34.0 (active)
whitespace, v0.33.0 (active)
wrap-guide, v0.38.1 (active)
language-c, v0.52.1 (active)
language-clojure, v0.21.0 (active)
language-coffee-script, v0.47.2 (active)
language-csharp, v0.12.1 (active)
language-css, v0.37.1 (active)
language-gfm, v0.88.0 (active)
language-git, v0.15.0 (active)
language-go, v0.42.1 (active)
language-html, v0.45.1 (active)
language-hyperlink, v0.16.0 (active)
language-java, v0.23.0 (active)
language-javascript, v0.119.0 (active)
language-json, v0.18.2 (active)
language-less, v0.29.5 (active)
language-make, v0.22.2 (active)
language-mustache, v0.13.0 (active)
language-objective-c, v0.15.1 (active)
language-perl, v0.35.0 (active)
language-php, v0.37.2 (active)
language-property-list, v0.8.0 (active)
language-python, v0.45.0 (active)
language-ruby, v0.69.0 (active)
language-ruby-on-rails, v0.25.0 (active)
language-sass, v0.56.0 (active)
language-shellscript, v0.22.4 (active)
language-source, v0.9.0 (active)
language-sql, v0.23.0 (active)
language-text, v0.7.1 (active)
language-todo, v0.28.0 (active)
language-toml, v0.18.0 (active)
language-xml, v0.34.9 (active)
language-yaml, v0.26.0 (active)

# Dev
No dev packages
dpo commented 6 years ago

Sorry for the long delay. Should be fixed in #38.

fitz99 commented 6 years ago

I'm having this issue now. Is there a work-around?

fitz99 commented 6 years ago

[Enter steps to reproduce:]

  1. Packages->Python-Debugger->Toggle
  2. Uncaught TypeError pops up

Atom: 1.26.0 x64 Electron: 1.7.11 OS: Microsoft Windows 7 Professional Thrown From: python-debugger package 0.2.0

Stack Trace

Uncaught TypeError: Cannot read property 'file' of undefined

At C:\Users\Stephen.Fitzgerald\.atom\packages\python-debugger\lib\python-debugger-view.coffee:19

TypeError: Cannot read property 'file' of undefined
    at PythonDebuggerView.module.exports.PythonDebuggerView.getCurrentFilePath (/packages/python-debugger/lib/python-debugger-view.coffee:19:26)
    at PythonDebuggerView.module.exports.PythonDebuggerView.initialize (/packages/python-debugger/lib/python-debugger-view.coffee:156:26)
    at /packages/autocomplete-python/node_modules/space-pen/lib/space-pen.js:184:25)
    at /packages/python-debugger/lib/python-debugger-view.coffee:11:7)
    at Object.createDebuggerView (/packages/python-debugger/lib/python-debugger.coffee:19:29)
    at /packages/python-debugger/lib/python-debugger.coffee:29:37)
    at CommandRegistry.handleCommandEvent (~/AppData/Local/atom/app-1.26.0/resources/app/src/command-registry.js:384:49)
    at CommandRegistry.dispatch (~/AppData/Local/atom/app-1.26.0/resources/app/src/command-registry.js:273:23)
    at AtomEnvironment.dispatchApplicationMenuCommand (~/AppData/Local/atom/app-1.26.0/resources/app/src/atom-environment.js:1347:25)
    at EventEmitter.outerCallback (~/AppData/Local/atom/app-1.26.0/resources/app/src/application-delegate.js:339:53)
    at emitThree (events.js:116:13)
    at EventEmitter.emit (events.js:197:7)

Commands

     -3:51.2.0 debugger:show (atom-workspace.workspace.scrollbars-visible-always.theme-one-dark-syntax.theme-one-dark-ui)
     -3:45 debugger:show-launch-dialog (atom-workspace.workspace.scrollbars-visible-always.theme-one-dark-syntax.theme-one-dark-ui)
     -3:40 core:cancel (atom-workspace.workspace.scrollbars-visible-always.theme-one-dark-syntax.theme-one-dark-ui)
     -3:21.8.0 python-debugger:toggle (atom-workspace.workspace.scrollbars-visible-always.theme-one-dark-syntax.theme-one-dark-ui)

Non-Core Packages

atom-ide-ui 0.11.0 
atom-python-run 0.9.6 
autocomplete-python 1.10.5 
ide-python 0.9.2 
python-debugger 0.2.0 
python-indent 1.1.5 
python-tools 0.6.9