t9md / atom-vim-mode-plus

vim-mode improved
https://atom.io/packages/vim-mode-plus
MIT License
1.4k stars 111 forks source link

Throws Uncaught TypeError with atom's new teletype installed + connected #968

Closed DavidLGoldberg closed 6 years ago

DavidLGoldberg commented 6 years ago

[Enter steps to reproduce:]

  1. apm install teletype # atom's new teletype from their home page...
  2. join a teletype
  3. hit escape after insert mode.

NOTE: Actually, everything seems to work otherwise, it just shows a red pop up! It might be as simple as a try/catch around this.

Atom: 1.22.0 x64 Electron: 1.6.15 OS: Mac OS X 10.11.6 Thrown From: vim-mode-plus package 1.19.0

Stack Trace

Uncaught TypeError: this.historyProvider.getChangesSinceCheckpoint is not a function

At /Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:1022

TypeError: this.historyProvider.getChangesSinceCheckpoint is not a function
    at TextBuffer.module.exports.TextBuffer.getChangesSinceCheckpoint (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:1022:48)
    at ActivateInsertMode.getChangeSinceCheckpoint (/packages/vim-mode-plus/lib/operator-insert.js:25:31)
    at /packages/vim-mode-plus/lib/operator-insert.js:100:31
    at Function.module.exports.Emitter.simpleDispatch (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at VimState.activate (/packages/vim-mode-plus/lib/vim-state.js:491:20)
    at /packages/vim-mode-plus/lib/main.js:152:39)
    at HTMLElement.didDispatch (/packages/vim-mode-plus/lib/main.js:201:30)
    at CommandRegistry.handleCommandEvent (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/src/command-registry.js:381:36)
    at KeymapManager.module.exports.KeymapManager.dispatchCommandEvent (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:621:22)
    at KeymapManager.module.exports.KeymapManager.handleKeyboardEvent (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:412:28)
    at WindowEventHandler.module.exports.WindowEventHandler.handleDocumentKeyEvent (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/src/window-event-handler.js:100:42)
    at HTMLDocument.<anonymous> (/Users/dgoldberg/Downloads/Atom 5.app/Contents/Resources/app/src/window-event-handler.js:3:65)

Commands

     -0:54 vim-mode-plus:reset-normal-mode (input.hidden-input)
     -0:40.8.0 vim-mode-plus:activate-normal-mode (input.hidden-input)
     -0:40.7.0 vim-mode-plus:reset-normal-mode (input.hidden-input)
 20x -0:40.3.0 vim-mode-plus:move-left (input.hidden-input)
     -0:39 vim-mode-plus:move-down (input.hidden-input)
     -0:38.1.0 vim-mode-plus:move-up (input.hidden-input)
  3x -0:37.7.0 vim-mode-plus:move-down (input.hidden-input)
  2x -0:36.9.0 vim-mode-plus:move-up (input.hidden-input)
 15x -0:32.8.0 vim-mode-plus:move-down (input.hidden-input)
 34x -0:32 vim-mode-plus:move-up (input.hidden-input)
 20x -0:30.2.0 vim-mode-plus:move-down (input.hidden-input)
  2x -0:28.9.0 vim-mode-plus:move-up (input.hidden-input)
     -0:27.4.0 vim-mode-plus:insert-after-end-of-line (input.hidden-input)
  2x -0:18.5.0 vim-mode-plus:activate-normal-mode (input.hidden-input)
     -0:04.1.0 vim-mode-plus:activate-insert-mode (input.hidden-input)
     -0:03.8.0 vim-mode-plus:activate-normal-mode (input.hidden-input)

Non-Core Packages

activate-power-mode 2.6.0 
an-old-hope-syntax 1.0.4 
angularjs 0.4.0 
ask-stack 2.2.0 
atom-beautify 0.30.6 
atom-ide-ui 0.5.4 
atom-material-syntax 1.0.7 
atom-material-syntax-dark 1.0.0 
atom-material-syntax-light 0.4.6 
atom-material-ui 2.0.6 
atom-mermaid 3.2.1 
atom-typescript 11.0.10 
bookmarklet 0.7.1 
bottom-dock 0.4.4 
bug-report 0.7.1 
build 0.69.0 
build-npm-apm 0.12.0 
busy 0.7.0 
busy-signal 1.4.3 
chameleon-dark-syntax 0.0.5 
change-case 0.6.5 
coffee-navigator 0.0.18 
coffee-refactor 0.7.0 
color-picker 2.2.5 
command-logger 0.23.0 
copy-filename 1.1.0 
cursor-history 0.12.0 
dash 1.7.1 
dracula-syntax 2.0.5 
editor-stats 0.17.0 
elm-format 3.0.0 
elm-navigator 2.0.0 
elm-snippets 0.1.0 
elmjutsu 7.1.5 
emmet 2.4.3 
ex-mode 0.18.0 
file-icons 2.1.13 
firewatch-syntax 1.1.1 
fizzy 0.21.0 
gist-it 0.9.2 
git-blame 1.3.1 
git-history 3.3.0 
git-log 0.4.1 
git-plus 7.10.0 
git-tab-status 1.9.2 
git-time-machine 1.5.9 
highlight-selected 0.13.1 
html-to-elm 0.2.0 
Hydrogen 2.0.1 
hyperclick 0.0.0 
ide-typescript 0.7.0 
idledark 0.3.1 
indent-guide-improved 1.4.13 
indentation-indicator 1.1.0 
indico-syntax 0.4.0 
indico-ui 0.3.0 
intentions 1.1.5 
js-hyperclick 1.12.2 
js-refactor 0.7.5 
juicebox-syntax 1.0.6 
jumpy 4.1.1 
key-peek 0.2.12 
keybinding-cheatsheet 0.1.1 
knightrider-syntax 1.0.2 
lambda-syntax 0.5.2 
language-aspx 0.5.0 
language-bro 1.3.0 
language-cjsx 0.3.0 
language-docker 1.1.8 
language-docker-erb 0.1.0 
language-elm 1.5.0 
language-generic-config 1.4.0 
language-gitignore 0.3.0 
language-javascript-jsx 0.3.7 
language-kdb-q 0.3.1 
language-pgsql 0.2.3 
language-splunk 0.1.1 
last-tab 0.1.6 
line-count 0.5.0 
linter 2.2.0 
linter-alex 4.0.0 
linter-coffee-variables 0.8.2 
linter-coffeelint 1.3.1 
linter-csslint 2.0.0 
linter-docker 0.2.1 
linter-elm-make 0.27.2 
linter-eslint 8.4.0 
linter-flake8 2.2.1 
linter-gcc 0.7.1 
linter-javac 1.9.4 
linter-jsonlint 1.3.0 
linter-just-say-no 0.7.3 
linter-less 2.6.0 
linter-lua 1.0.4 
linter-manager 0.2.12 
linter-markdown 5.2.0 
linter-perl 0.8.1 
linter-pylint 2.1.0 
linter-rubocop 2.2.0 
linter-ruby 1.2.6 
linter-shellcheck 1.4.6 
linter-tidy 2.3.1 
linter-ui-default 1.6.10 
linter-write-good 0.9.0 
live-archive 0.1.15 
lychee-syntax 2.4.2 
mandarin-syntax 1.0.0 
material 2.2.0 
merge-conflicts 1.4.5 
minimap 4.29.7 
minimap-find-and-replace 4.5.2 
minimap-git-diff 4.3.1 
minimap-highlight-selected 4.6.1 
minimap-linter 2.1.3 
minimap-pigments 0.2.2 
monokai 0.24.0 
my-test-with-js-package 0.0.0 
neon-cursor 1.6.0 
neon-selection 0.3.2 
nucleus-dark-ui 0.12.3 
open-recent 5.0.0 
pain-split 1.4.0 
pigments 0.40.2 
pretty-json 1.6.4 
proton-bat 2.0.0 
qolor 0.4.2 
quick-highlight 0.11.1 
react 0.17.0 
refactor 0.11.5 
regex-railroad-diagram 0.19.4 
remote-sync 4.1.8 
rest-client 1.3.1 
rspec 0.4.0 
script 3.17.3 
show-in-system 0.4.0 
soft-wrap-indicator 1.1.0 
stacktrace 0.0.2 
tabs-to-spaces 1.0.3 
teletype 0.1.1 
theme-roulette 1.1.0 
todo-show 2.1.0 
toggle-quotes 1.0.1 
toggler 0.3.0 
trailing-spaces 0.4.0 
tron-theme 0.3.3 
turbo-javascript 1.4.0 
vim-mode-plus 1.19.0 
wakatime 7.0.4 
white-cursor 0.7.0 
Zen 0.18.0 
t9md commented 6 years ago

Not sure how to fix it, can't I expect text buffer provides getChangesSinceCheckpoint? I've not tried it yet.

DavidLGoldberg commented 6 years ago

Haven't done any investigation..(work day) I'll try to remember to investigate tonight ... apparently vs code just released their version too ! I wonder how that one behaves with their vim

...luckily this should be fixable because like I said ...if it wasn't for that red pop up it seems more or less fine ...(wouldnt be the first time I've seen that pattern)

But the way only edits are sent I guess..or maybe cursor positions on move (forgot) ...but my friend didn't have vim mode on and it mostly worked. I'll try to play more later ...@ me tonight if you need a hand should be around

On Wed, Nov 15, 2017, 12:14 PM t9md notifications@github.com wrote:

Not sure how to fix it, can't I expect text buffer provides getChangesSinceCheckpoint? I've not tried it yet.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/t9md/atom-vim-mode-plus/issues/968#issuecomment-344662566, or mute the thread https://github.com/notifications/unsubscribe-auth/AAjTr9VG-B3sgnw2hVKoMbSa9kGB0Nf6ks5s2xwKgaJpZM4QfQdn .

t9md commented 6 years ago

I believe OK to close this issue, since this is duplicate of #969. Which is closed after adding some fixes at teletype side.