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 #49

Open fitz99 opened 6 years ago

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 
7clem commented 5 years ago

I have the same issue. I expect my setup of atom may not be right and could be the reason.

mguala commented 5 years ago

[Enter steps to reproduce:]

Packages->Python-Debugger->Toggle Uncaught TypeError pops up

Atom: 1.33.0 x64 Electron: 2.0.11 OS: Microsoft Windows 10 Home Single Language Thrown From: python-debugger package 0.2.0

Stack Trace

Uncaught TypeError: Cannot read property 'file' of undefined

At C:\Users\Issa\.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:27)
    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.33.0/resources/app/static/<embedded>:11:349858)
    at CommandRegistry.dispatch (~/AppData/Local/atom/app-1.33.0/resources/app/static/<embedded>:11:348333)
    at AtomEnvironment.dispatchApplicationMenuCommand (~/AppData/Local/atom/app-1.33.0/resources/app/static/<embedded>:1:656662)
    at EventEmitter.t (~/AppData/Local/atom/app-1.33.0/resources/app/static/<embedded>:1:664046)
    at emitThree (events.js:136:13)
    at EventEmitter.emit (events.js:217:7)

Commands

  7x -5:28.9.0 intentions:highlight (input.hidden-input)
     -5:28.3.0 core:copy (input.hidden-input)
  2x -5:23.4.0 editor:newline (input.hidden-input)
     -5:22.9.0 intentions:highlight (input.hidden-input)
     -5:22.9.0 core:paste (input.hidden-input)
  2x -5:19.2.0 core:backspace (input.hidden-input)
     -5:16.9.0 editor:newline (input.hidden-input)
     -5:16.5.0 core:move-down (input.hidden-input)
  2x -5:15.8.0 core:delete (input.hidden-input)
     -5:13 intentions:highlight (input.hidden-input)
     -5:12.6.0 core:save (input.hidden-input)
     -5:02.1.0 atom-beautify:beautify-editor (input.hidden-input)
     -3:09.3.0 atom-beautify:open-settings (input.hidden-input)
     -1:53.4.0 python-debugger:toggle (atom-workspace.workspace.scrollbars-visible-always.theme-GobbieGobGoo.theme-spotify-ui)
     -0:19.8.0 intentions:highlight (input.hidden-input)
     -0:19.4.0 core:save (input.hidden-input)

Non-Core Packages

autocomplete-python 1.11.0 
autocomplete-python-jedi 1.10.3-0 
busy-signal 1.4.3 
framer-syntax 1.1.0 
framer-ui 2.0.0 
github-utils 1.6.0 
GobbieGobGoo 1.0.4 
handsome-light-syntax 0.3.4 
intentions 1.1.5 
kite 0.131.0 
linter 2.2.0 
linter-gcc 0.7.1 
linter-ui-default 1.7.1 
python-debugger 0.2.0 
python-indent 1.1.6 
python-snippets 1.9.0 
python-tools 0.6.9 
run-python-simply 0.6.0 
spotify-ui 1.2.2 
annamartinez21284 commented 4 years ago

So what is the solution? I have the same problem. I literally insalled atom 3 days ago, so should be up to date... Thanks!

Gostguest commented 3 years ago

I am facing the same problem. Please, any solutions!

bluecheez commented 2 years ago

Is this problem going to be fixed? I also have this issue...

drewbroadley commented 2 years ago

Same issue here, installed only a week ago.

adupree126 commented 2 years ago

I had installed atom with OSX's package manager brew. Uninstalling it with brew and then re-installing it directly from atom.io worked for me.