Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uncaught TypeError: undefined is not a function #212

Closed
poberherr opened this issue Jan 9, 2015 · 6 comments
Closed

Uncaught TypeError: undefined is not a function #212

poberherr opened this issue Jan 9, 2015 · 6 comments

Comments

@poberherr
Copy link

Hey there,
I just updated the Minimap and I am getting this error. (Everytime I open files over the fuzzy finder.)

[Enter steps to reproduce below:]

  1. ...
  2. ...

Atom Version: 0.165.0
System: Mac OS X 10.10.2
Thrown From: minimap package, v3.5.4

Stack Trace

Uncaught TypeError: undefined is not a function

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

TypeError: undefined is not a function
  at /Users/patrickoberherr/.atom/packages/minimap/lib/mixins/view-management.coffee:85:7
  at atom-workspace.attachedCallback (/Applications/Atom.app/Contents/Resources/app/src/workspace-view.js:94:18)
  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:243: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:156: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:180: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:250:22)
  at Pane.module.exports.Pane.activateItem (/Applications/Atom.app/Contents/Resources/app/src/pane.js:314:21)
  at /Applications/Atom.app/Contents/Resources/app/src/workspace.js:494:16
  at _fulfilled (/Applications/Atom.app/Contents/Resources/app/node_modules/pathwatcher/node_modules/q/q.js:787:54)
  at self.promiseDispatch.done (/Applications/Atom.app/Contents/Resources/app/node_modules/pathwatcher/node_modules/q/q.js:816:30)
  at Promise.promise.promiseDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/pathwatcher/node_modules/q/q.js:749:13)
  at /Applications/Atom.app/Contents/Resources/app/node_modules/pathwatcher/node_modules/q/q.js:557:44
  at flush (/Applications/Atom.app/Contents/Resources/app/node_modules/pathwatcher/node_modules/q/q.js:108:17)
  at process._tickCallback (node.js:378:11)

Commands

     -0:26.0 fuzzy-finder:toggle-file-finder (input.hidden-input)
  5x -0:21.7 core:backspace (input.hidden-input)
     -0:16.8 core:confirm (input.hidden-input)
     -0:05.1 fuzzy-finder:toggle-file-finder (input.hidden-input)
  2x -0:00.7 core:move-down (input.hidden-input)
     -0:00.0 core:confirm (input.hidden-input)

Config

{
  "core": {
    "disabledPackages": [
      "metrics"
    ],
    "ignoredNames": [
      "*.pyc"
    ],
    "themes": [
      "seti-ui",
      "seti-syntax"
    ]
  }
}

Installed Packages

# User
atom-lint, v0.20.1
autocomplete-plus, v1.1.0
jshint, v1.1.3
minimap, v3.5.4
seti-syntax, v0.2.1
seti-ui, v0.6.1

# Dev
No dev packages

/cc @atom/core

@abe33
Copy link
Contributor

abe33 commented Jan 14, 2015

Can you try the same thing with the v4 preview setting enabled? (it'll need a restart to be effective)

@poberherr
Copy link
Author

I activated v4 preview and couldn't replicate the issue till now.
I think (at least till now) that this solved the issue.
Thanks!

@despairblue
Copy link

Happens again after upgrade to version 4 and restarting atom:

TypeError: undefined is not a function
  at Main.minimapForEditor (/home/despairblue/.atom/packages/minimap/lib/main.coffee:230:21)
  at Main.getActiveMinimap (/home/despairblue/.atom/packages/minimap/lib/main.coffee:241:25)
  at FakeEditor.getActiveMinimap (/home/despairblue/.atom/packages/minimap-highlight-selected/lib/minimap-highlight-selected-view.coffee:10:35)
  at FakeEditor.getActiveTextEditor (/home/despairblue/.atom/packages/minimap-highlight-selected/lib/minimap-highlight-selected-view.coffee:21:29)
  at MinimapHighlightSelectedView.handleSelection (/home/despairblue/.atom/packages/minimap-highlight-selected/lib/minimap-highlight-selected-view.coffee:29:21)
  at atom-workspace.<anonymous> (/home/despairblue/.atom/packages/highlight-selected/lib/highlighted-area-view.coffee:1:1)
  at atom-workspace.handler (/usr/share/atom/resources/app/src/space-pen-extensions.js:112:34)
  at atom-workspace.jQuery.event.dispatch (/usr/share/atom/resources/app/node_modules/space-pen/vendor/jquery.js:4681:9)
  at atom-workspace.elemData.handle (/usr/share/atom/resources/app/node_modules/space-pen/vendor/jquery.js:4359:46)
  at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/usr/share/atom/resources/app/src/command-registry.js:243:29)

@despairblue
Copy link

By the way, for it to go away I had to disable not only minimap, but also every minimap plugin as well.

@abe33 abe33 closed this as completed in ca01a30 Feb 3, 2015
@abe33
Copy link
Contributor

abe33 commented Feb 3, 2015

Hmm, I had meddled a bit with require/instantiation sequence which could explained that issue: If a plugin require the minimap for a text editor before the minimap model class was required this is what happen.

@despairblue
Copy link

Ah ok. Works again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants