tvooo / scope-inspector

Inspect your JavaScript scope in Atom
MIT License
19 stars 3 forks source link

Uncaught TypeError: Cannot read property 'getHoistedIdentifiers' of null #16

Open joshlong opened 9 years ago

joshlong commented 9 years ago

[Enter steps to reproduce below:]

  1. ...
  2. ...

Atom Version: 0.187.0 System: Mac OS X 10.10.2 Thrown From: scope-inspector package, v0.2.1

Stack Trace

Uncaught TypeError: Cannot read property 'getHoistedIdentifiers' of null

At /Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:128

TypeError: Cannot read property 'getHoistedIdentifiers' of null
  at Inspection.module.exports.Inspection.updateHoistingIndicators (/Users/jlong/.atom/packages/scope-inspector/lib/inspection.coffee:103:31)
  at /Users/jlong/.atom/packages/scope-inspector/lib/inspection.coffee:43:8
  at Config.module.exports.Config.observeKeyPath (/Applications/Atom.app/Contents/Resources/app/src/config.js:621:7)
  at Config.module.exports.Config.observe (/Applications/Atom.app/Contents/Resources/app/src/config.js:133:21)
  at Inspection.module.exports.Inspection.registerEvents (/Users/jlong/.atom/packages/scope-inspector/lib/inspection.coffee:42:17)
  at new Inspection (/Users/jlong/.atom/packages/scope-inspector/lib/inspection.coffee:27:6)
  at ScopeInspector.updateInspection (/Users/jlong/.atom/packages/scope-inspector/lib/scope-inspector.coffee:24:22)
  at /Users/jlong/.atom/packages/scope-inspector/lib/scope-inspector.coffee:17:8
  at atom-workspace.<anonymous> (/Applications/Atom.app/Contents/Resources/app/src/workspace-view.js:99:22)
  at atom-workspace.handler (/Applications/Atom.app/Contents/Resources/app/src/space-pen-extensions.js:110:34)
  at atom-workspace.jQuery.event.dispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4681:9)
  at atom-workspace.elemData.handle (/Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/vendor/jquery.js:4359:46)
  at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:246:29)
  at CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61)
  at CommandRegistry.module.exports.CommandRegistry.dispatch (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:159:19)
  at TextEditorView.jQuery.fn.trigger (/Applications/Atom.app/Contents/Resources/app/src/space-pen-extensions.js:64:23)
  at TextEditorView.module.exports.TextEditorView.afterAttach (/Applications/Atom.app/Contents/Resources/app/src/text-editor-view.js:178:19)
  at callAttachHooks (/Applications/Atom.app/Contents/Resources/app/node_modules/space-pen/lib/space-pen.js:342:67)
  at atom-pane.PaneElement.activeItemChanged (/Applications/Atom.app/Contents/Resources/app/src/pane-element.js:111:9)
  at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:82:11)
  at Pane.module.exports.Pane.setActiveItem (/Applications/Atom.app/Contents/Resources/app/src/pane.js:264:22)
  at Pane.module.exports.Pane.addItem (/Applications/Atom.app/Contents/Resources/app/src/pane.js:353:14)
  at Pane.module.exports.Pane.activateItem (/Applications/Atom.app/Contents/Resources/app/src/pane.js:327:14)
  at /Applications/Atom.app/Contents/Resources/app/src/workspace.js:534:16
  at _fulfilled (/Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:794:54)
  at self.promiseDispatch.done (/Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:823:30)
  at Promise.promise.promiseDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:756:13)
  at /Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:817:14
  at flush (/Applications/Atom.app/Contents/Resources/app/node_modules/q/q.js:110:17)
  at process._tickCallback (node.js:366:11)

Commands

     -1:00.9 core:cut (atom-text-editor.editor.is-focused)
     -0:58.7 core:paste (atom-text-editor.editor.is-focused)
     -0:56.1 core:save (atom-text-editor.editor.is-focused)
     -0:31.3 core:paste (atom-text-editor.editor.is-focused)
     -0:30.7 core:undo (atom-text-editor.editor.is-focused)
     -0:29.5 core:paste (atom-text-editor.editor.is-focused)
  5x -0:28.6 editor:select-to-beginning-of-word (atom-text-editor.editor.is-focused)
     -0:27.2 core:backspace (atom-text-editor.editor.is-focused)
     -0:26.6 core:save (atom-text-editor.editor.is-focused)
     -0:21.9 core:copy (atom-text-editor.editor.is-focused)
     -0:19.0 core:paste (atom-text-editor.editor.is-focused)
  2x -0:15.5 core:save (atom-text-editor.editor.is-focused)
     -0:01.6 command-palette:toggle (atom-text-editor.editor)
     -0:00.7 core:confirm (atom-text-editor.editor.mini)
     -0:00.7 markdown-preview:toggle (atom-text-editor.editor)
     -0:00.3 core:confirm (atom-pane.pane.active)

Config

{
  "core": {
    "disabledPackages": [
      "language-coffee-script",
      "archive-view",
      "atom-terminal",
      "autoflow",
      "github-issues",
      "gitignore-snippets",
      "color-picker",
      "travis-ci-status",
      "terminal-status"
    ],
    "themes": [
      "atom-light-ui",
      "atom-light-syntax"
    ]
  },
  "scope-inspector": {
    "userId": "7a2778c694210ff2ce6ea44d5362c989957fa3fb",
    "showSidebar": false
  }
}

Installed Packages

# User
asciidoc-preview, v0.4.3
git-log, v0.3.0
language-asciidoc, v0.11.1
linter, v0.12.0
markdown-format, v2.5.0
scope-inspector, v0.2.1
script, v2.18.0
script-runner, v1.7.1

# Dev
No dev packages
tvooo commented 9 years ago

Thanks for the report. Scope Inspector isn't quite up-to-date with recent API changes, which is what might break it for you. Hopefully I have some time on the weekend to fix it.

tvooo commented 9 years ago

I brought the package up to date and fixed all deprecation errors. I guess this will get rid of this one as well, but I am not sure as I could not reproduce it. If it still occurs, please reopen this issue (or file a new one).

temsa commented 9 years ago

I still have the issue when opening a file just after Atom start

ryanpcmcquen commented 7 years ago

Still happening on Atom 1.16.0.

meylor commented 6 years ago

Seeing this issue with the latest version of Atom 1.25.0.

[Enter steps to reproduce:]

1. ...
2. ...

**Atom**: 1.25.0 x64
**Electron**: 1.7.11
**OS**: Mac OS X 10.13.3
**Thrown From**: [scope-inspector](https://github.com/tvooo/scope-inspector) package 1.0.1

Stack Trace

Failed to activate the scope-inspector package

At Cannot read property 'getHoistedIdentifiers' of null

TypeError: Cannot read property 'getHoistedIdentifiers' of null
    at Inspection.module.exports.Inspection.updateHoistingIndicators (/packages/scope-inspector/lib/inspection.coffee:101:31)
    at /packages/scope-inspector/lib/inspection.coffee:41:8
    at Config.observeKeyPath (/Applications/Atom.app/Contents/Resources/app/src/config.js:1012:11)
    at Config.observe (/Applications/Atom.app/Contents/Resources/app/src/config.js:481:25)
    at Inspection.module.exports.Inspection.registerEvents (/packages/scope-inspector/lib/inspection.coffee:40:17)
    at /packages/scope-inspector/lib/inspection.coffee:25:6)
    at ScopeInspector.updateInspection (/packages/scope-inspector/lib/scope-inspector.coffee:23:18)
    at /packages/scope-inspector/lib/scope-inspector.coffee:17:8
    at Workspace.observeTextEditors (/Applications/Atom.app/Contents/Resources/app/src/workspace.js:637:59)
    at ScopeInspector.registerInspections (/packages/scope-inspector/lib/scope-inspector.coffee:13:20)
    at ScopeInspector.activate (/packages/scope-inspector/lib/scope-inspector.coffee:60:26)
    at Package.activateNow (/Applications/Atom.app/Contents/Resources/app/src/package.js:230:33)
    at measure (/Applications/Atom.app/Contents/Resources/app/src/package.js:206:33)
    at Package.measure (/Applications/Atom.app/Contents/Resources/app/src/package.js:88:25)
    at activationPromise.Promise (/Applications/Atom.app/Contents/Resources/app/src/package.js:200:20)
    at Promise (<anonymous>)
    at Package.activate (/Applications/Atom.app/Contents/Resources/app/src/package.js:198:38)
    at PackageManager.activatePackage (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:695:42)
    at config.transactAsync (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:670:36)
    at Config.transactAsync (/Applications/Atom.app/Contents/Resources/app/src/config.js:862:28)
    at PackageManager.activatePackages (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:668:23)
    at PackageManager.activate (/Applications/Atom.app/Contents/Resources/app/src/package-manager.js:647:50)
    at loadStatePromise.loadState.then (/Applications/Atom.app/Contents/Resources/app/src/atom-environment.js:867:27)
    at <anonymous>

Commands

     -2:22.2.0 core:copy (atom-notification.fatal.icon.icon-bug.native-key-bindings.has-detail.has-close.has-stack)

Non-Core Packages

busy-signal 1.4.3 
intentions 1.1.5 
linter 2.2.0 
linter-ui-default 1.7.1 
nuclide 0.288.0 
prettier-atom 0.52.0 
scope-inspector 1.0.1 

Just attempted to install scope-inspector.

ryanpcmcquen commented 6 years ago

This project seems dead, I switched to: https://github.com/lejsue/symbols-navigator

The developer there is very responsive.