benjaminRomano / todo-manager

Manage TODOs, NOTEs, etc. from inside Atom.
https://atom.io/packages/todo-manager
MIT License
4 stars 2 forks source link

Uncaught TypeError: Cannot read property 'dataTransfer' of null #9

Closed tsbarnes closed 9 years ago

tsbarnes commented 9 years ago

This occurs any time I close the last tab in the editor.

Atom Version: 1.0.7 System: Ubuntu 15.04 Thrown From: tabs package, v0.82.0

Stack Trace

Uncaught TypeError: Cannot read property 'dataTransfer' of null

At /opt/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:518

TypeError: Cannot read property 'dataTransfer' of null
  at TabBarView.module.exports.TabBarView.onDragStart (/opt/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:518:26)
  at tabs-tab.<anonymous> (/opt/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:3:61)
  at space-pen-ul.jQuery.event.dispatch (/opt/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4435:9)
  at space-pen-ul.$event.dispatch (/home/scott/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:374:19)
  at space-pen-ul.<anonymous> (/home/scott/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:259:40)
  at Function.jQuery.extend.each (/opt/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:374:23)
  at [object Object].jQuery.fn.jQuery.each (/opt/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:139:17)
  at Object.$special.drag.hijack (/home/scott/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:253:44)
  at HTMLDocument.$special.drag.handler (/home/scott/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:185:10)
  at HTMLDocument.jQuery.event.dispatch (/opt/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4435:9)
  at HTMLDocument.$event.dispatch (/home/scott/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:374:19)
  at HTMLDocument.elemData.handle (/opt/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4121:28)

Commands

Config

{
  "core": {
    "projectHome": "/home/scott/Documents/Code",
    "disabledPackages": [
      "language-ruby"
    ],
    "themes": [
      "metro-ui",
      "ax-monokai-syntax"
    ]
  }
}

Installed Packages

# User
atom-django, v0.3.0
autocomplete-php, v0.3.7
autocomplete-python, v0.5.3
autocomplete-ruby, v0.1.0
autocomplete-sass, v0.1.0
ax-monokai-syntax, v0.1.0
bottom-dock, v0.3.2
browser-refresh, v0.9.0
color-picker, v2.0.11
django-templates, v0.5.0
file-icon-supplement, v0.8.3
file-icons, v1.6.9
flex-tool-bar, v0.5.0
git-tab-status, v1.9.2
grunt-runner, v0.11.0
language-apache, v1.3.0
language-autotools, v2.0.0
language-cmake, v0.1.4
language-conky, v0.2.0
language-cpp14, v0.4.0
language-dart, v0.2.0
language-diff, v0.3.1
language-dotenv, v1.0.0
language-gettext, v0.6.1
language-gitignore, v0.2.0
language-haml, v0.21.0
language-htaccess, v0.1.1
language-ini, v1.11.0
language-log, v0.6.0
language-lua, v0.9.4
language-ppd, v0.3.1
language-qml, v1.0.0
language-rspec, v0.3.0
language-ruby-without-erb, v0.52.0
language-svg, v0.8.0
linter, v1.4.3
linter-bootlint, v0.0.6
linter-coffeelint, v1.0.2
linter-cpplint, v0.1.4
linter-csslint, v1.0.5
linter-erb, v0.1.1
linter-haml, v1.0.0
linter-js-yaml, v1.1.1
linter-jshint, v1.1.5
linter-less, v2.1.0
linter-lua, v1.0.0
linter-pep8, v1.0.1
linter-ruby, v1.0.2
linter-scss-lint, v2.0.0
linter-shellcheck, v1.0.1
linter-xmllint, v0.0.7
metro-ui, v2.2.2
minimap, v4.13.1
minimap-git-diff, v4.1.8
pigments, v0.11.0
recent-projects, v0.8.6
tabs-to-spaces, v0.11.1
todo-manager, v0.2.2
tool-bar, v0.1.8
travis-ci-status, v0.16.0
tree-view-git-status, v0.1.2

# Dev
No dev packages
tsbarnes commented 9 years ago

I should add, this only occurs if "Open files" is the current tab in the TODO pane.

benjaminRomano commented 9 years ago

Unfortunately, I'm not able to reproduce the bug locally, and I'm not sure why this would happen when "Open Files" is selected in the TODO pane...

If you have time, could you log the value of the event passed into the onDragStart function in the tab-bar-view.js file.

Otherwise, for now I'll just wait and see if someone working on the tabs package can figure out this error.

p-ho commented 9 years ago

Re: @benjaminRomano at atom/tabs#203 Unfortunately the bug isn't easily reproducible. It only happens from time to time. I'll post the error message as soon as it happens the next time.

The second bug I've described (no drag and drop possible) emits no error message at all including no output on the devconsole. It simply doesn't work.

p-ho commented 9 years ago

Now it's happened:

Atom Version: 1.0.7 System: "openSUSE 13.2 Thrown From: tabs package, v0.82.0

Stack Trace

Uncaught TypeError: Cannot read property 'dataTransfer' of null

At /usr/share/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:518

TypeError: Cannot read property 'dataTransfer' of null
  at TabBarView.module.exports.TabBarView.onDragStart (/usr/share/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:518:26)
  at tabs-tab.<anonymous> (/usr/share/atom/resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:3:61)
  at space-pen-ul.jQuery.event.dispatch (/usr/share/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4435:9)
  at space-pen-ul.$event.dispatch (/home/pho/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:374:19)
  at space-pen-ul.<anonymous> (/home/pho/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:259:40)
  at Function.jQuery.extend.each (/usr/share/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:374:23)
  at [object Object].jQuery.fn.jQuery.each (/usr/share/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:139:17)
  at Object.$special.drag.hijack (/home/pho/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:253:44)
  at HTMLDocument.$special.drag.handler (/home/pho/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:185:10)
  at HTMLDocument.jQuery.event.dispatch (/usr/share/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4435:9)
  at HTMLDocument.$event.dispatch (/home/pho/.atom/packages/todo-manager/node_modules/atom-bottom-dock/node_modules/slickgrid/lib/jquery.event.drag-2.2.js:374:19)
  at HTMLDocument.elemData.handle (/usr/share/atom/resources/app.asar/node_modules/jquery/dist/jquery.js:4121:28)

Commands

  3x -0:51.9.0 core:backspace (atom-text-editor.editor.is-focused)
     -0:50.8.0 editor:newline (atom-text-editor.editor.is-focused)
     -0:49.6.0 core:save (atom-text-editor.editor.is-focused)
  2x -0:33.8.0 editor:newline (atom-text-editor.editor.is-focused)
     -0:32.8.0 core:backspace (atom-text-editor.editor.is-focused)
     -0:27.3.0 core:save (atom-text-editor.editor.is-focused)
     -0:10.9.0 core:undo (atom-text-editor.editor.is-focused)
  3x -0:05.2.0 core:backspace (atom-text-editor.editor.is-focused)
     -0:03.6.0 core:save (atom-text-editor.editor.is-focused)

Config

{
  "core": {
    "autoHideMenuBar": true,
    "disabledPackages": [
      "metrics"
    ]
  },
  "tabs": {}
}

Installed Packages

# User
atom-beautify, v0.28.11
autocomplete-python, v0.5.3
bottom-dock, v0.3.3
file-types, v0.5.1
jshint, v1.6.1
language-bison, v1.0.0
language-cython, v0.3.0
language-flex, v0.3.0
language-haskell, v1.4.1
language-latex, v0.6.1
language-nsis, v2.5.0
minimap, v4.13.2
pdf-view, v0.23.0
react, v0.12.6
symbols-tree-view, v0.9.3
todo-manager, v0.2.2

# Dev
No dev packages
benjaminRomano commented 9 years ago

Can you try updating atom to v1.0.11 and see if that helps

p-ho commented 9 years ago

Drag and drop is NOT fixed. The TypeError-issue must be awaited of course.

benjaminRomano commented 9 years ago

I just pushed out a new version (v0.2.4). Can you check and see if drag and drop is working for you guys now.

p-ho commented 9 years ago

drag and drop is working now :) Thank you very much.