jeremyramin / terminal-plus

A terminal package for Atom, complete with themes and more.
https://atom.io/packages/terminal-plus
MIT License
481 stars 254 forks source link

Uncaught TypeError: cannot read property 'toggle' of null (v0.12.5) #70

Closed objectkit closed 8 years ago

objectkit commented 8 years ago

Noted this was addressed in v0.12.3, but the issue appears in v0.12.5 for me. Hope this helps:

  1. Attempted to open a file in tree view after noticing its path mentioned in terminal-plus output after running an NPM script (unrelated I'm sure)
  2. File opens, but file contents are not displayed in Atom
  3. Close down terminal-plus, close file, open again
  4. File now shows normally.

Atom Version: 1.1.0 System: Mac OS X 10.9.5 Thrown From: terminal-plus package, v0.12.5

Stack Trace

Uncaught TypeError: Cannot read property 'toggle' of null

At /Users/user/.atom/packages/terminal-plus/lib/status-bar.coffee:66

TypeError: Cannot read property 'toggle' of null
  at /Users/user/.atom/packages/terminal-plus/lib/status-bar.coffee:66:23
  at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/event-kit/lib/emitter.js:86:11)
  at /Applications/Atom.app/Contents/Resources/app.asar/src/pane-container.js:333:27
  at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/event-kit/lib/emitter.js:86:11)
  at Pane.module.exports.Pane.setActiveItem (/Applications/Atom.app/Contents/Resources/app.asar/src/pane.js:247:22)
  at Pane.module.exports.Pane.activateItem (/Applications/Atom.app/Contents/Resources/app.asar/src/pane.js:311:21)
  at tabs-tab.<anonymous> (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/tabs/lib/tab-bar-view.js:210:24)
  at space-pen-ul.jQuery.event.dispatch (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/jquery/dist/jquery.js:4435:9)
  at space-pen-ul.elemData.handle (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/jquery/dist/jquery.js:4121:28)

Commands

  3x -4:23.3.0 terminal-plus:new (ol.tree-view.full-menu.list-tree.has-collapsable-children.focusable-panel)
     -2:22.4.0 core:save (atom-text-editor.editor.is-focused)

Config

{
  "core": {
    "projectHome": "/Users/user/Workspace/Ide/Atom",
    "disabledPackages": [
      "metrics"
    ],
    "themes": [
      "one-dark-ui",
      "base16-tomorrow-dark-theme"
    ]
  },
  "terminal-plus": {
    "core": {
      "mapTerminalsTo": "Folder",
      "workingDirectory": "Active File",
      "autoRunCommand": "source ~/.atom/.tprc"
    },
    "style": {
      "fontFamily": "Hack",
      "theme": "pro",
      "animationSpeed": 0,
      "fontSize": 12
    },
    "toggles": {
      "autoClose": true
    }
  }
}

Installed Packages

# User
atom-math, v0.0.3
coffee-refactor, v0.7.0
grunt-runner, v0.11.0
js-joiner, v0.7.3
latex, v0.28.0
linter, v1.10.0
linter-coffeelint, v1.1.2
refactor, v0.6.0
terminal-plus, v0.12.5
tool-bar, v0.1.9
tool-bar-main, v0.0.8

# user
No user packages
jeremyramin commented 8 years ago

Do you have terminal mapping enabled? If so, then:

  1. Are you mapped to Files or Folders?
  2. Do you have Auto Open a New Terminal enabled?
jeremyramin commented 8 years ago

Fixed as of v0.13.0. If the issue has been resolved, please close this issue. Otherwise, let me know and I will continue to work on it.

objectkit commented 8 years ago

Hey- thanks for getting back to me:

  1. Mapped to Folders
  2. No

It doesn't look like its resolved in v0.13.0 I'm afraid, for me at least. I'll try to pinpoint the configuration settings that affect this in the meantime and report back an overview.

jeremyramin commented 8 years ago

Make sure you refresh Atom after the update. You could still be running on the old code that has the issue.

jeremyramin commented 8 years ago

@objectkit Did the issue persist after restarting Atom?

jeremyramin commented 8 years ago

Closing issue as it has been confirmed and resolved as of v0.13.0

objectkit commented 8 years ago

Apologies @jeremyramin - time vampires sucked my time away and I didn't get back to you- yes indeed, it is resolved- thanks.