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: Cannot read property 'some' of undefined #17055

Closed
bratliff opened this Issue Mar 30, 2018 · 12 comments

Comments

Projects
None yet
10 participants
@bratliff

bratliff commented Mar 30, 2018

Edit by @rsese to add repro steps

Repro-ed with 1.26.0-beta1 on macOS 10.12.6 with @Ben3eeE's repro steps /cc #17055 (comment).

  1. atom-beta --safe
  2. Open some GIt repo-back project (e.g. atom/atom)
  3. GitHub: Toggle Git Tab
  4. Click into the commit message text box
  5. Type legal and then tab

@Ben3eeE's GIF:

commit editor issue thing 2


[Enter steps to reproduce:]

  1. ...
  2. ...

Atom: 1.25.0 x64
Electron: 1.7.11
OS: Mac OS X 10.13.3
Thrown From: Atom Core

Stack Trace

Uncaught TypeError: Cannot read property 'some' of undefined

At /Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81

TypeError: Cannot read property 'some' of undefined
    at SnippetExpansion.module.exports.SnippetExpansion.cursorMoved (/Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81:56)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:56:38
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Selection.markerDidChange (/Applications/Atom.app/Contents/Resources/app/src/selection.js:932:33)
    at Selection.marker.onDidChange.e (/Applications/Atom.app/Contents/Resources/app/src/selection.js:21:45)
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at DisplayMarker.module.exports.DisplayMarker.notifyObservers (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:248:33)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:53:32
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Marker.module.exports.Marker.emitChangeEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:441:26)
    at Marker.module.exports.Marker.update (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:374:18)
    at Marker.module.exports.Marker.setHeadPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:149:25)
    at DisplayMarker.module.exports.DisplayMarker.setHeadBufferPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:146:38)
    at DisplayMarker.module.exports.DisplayMarker.setHeadScreenPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:154:25)
    at changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:68:25)
    at Cursor.changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:713:11)
    at Cursor.setScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:67:16)
    at modifySelection (/Applications/Atom.app/Contents/Resources/app/src/selection.js:222:27)
    at Selection.modifySelection (/Applications/Atom.app/Contents/Resources/app/src/selection.js:984:11)
    at Selection.selectToScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/selection.js:214:16)
    at TextEditor.selectToScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:2911:25)
    at didDrag (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:1819:21)
    at get_window.requestAnimationFrame (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:1895:17)

Commands

     -7:12.9.0 core:save (input.hidden-input)
     -0:40.9.0 core:copy (input.hidden-input)
     -0:39.3.0 emmet:insert-formatted-line-break-only (input.hidden-input)
     -0:39.3.0 editor:newline (input.hidden-input)
     -0:39.1.0 core:paste (input.hidden-input)
  2x -0:34.5.0 core:backspace (input.hidden-input)
     -0:19.6.0 emmet:expand-abbreviation-with-tab (input.hidden-input)

Non-Core Packages

atom-beautify 0.32.2 
atom-terminal 0.8.0 
atom-terminal-panel 4.4.4 
emmet 2.4.3 
react 0.16.2 
sort-lines 0.15.0 
@MagicMarvMan

This comment has been minimized.

MagicMarvMan commented Mar 30, 2018

@MagicMarvMan

This comment has been minimized.

MagicMarvMan commented Mar 30, 2018

Could you please provide more information, e.g. the steps to reproduce? Thanks.

@Arcanemagus

This comment has been minimized.

Contributor

Arcanemagus commented Mar 30, 2018

Thanks for contributing!

All new issues require steps to reproduce (also called "repro steps") the problem or the behavior you wish to see in Atom. We do this so we can be certain that we are understanding what it is you're describing and don't prematurely close the issue or implement the wrong feature. If you need help writing detailed repro steps, please see the How Can I Contribute? section of the Atom CONTRTIBUTING guide.

@nivsalamon

This comment has been minimized.

nivsalamon commented Apr 10, 2018

[Enter steps to reproduce:]

  1. ...
  2. ...

Atom: 1.25.1 x64
Electron: 1.7.11
OS: Mac OS X 10.11.6
Thrown From: Atom Core

Stack Trace

Uncaught TypeError: Cannot read property 'some' of undefined

At /Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:959

TypeError: Cannot read property 'some' of undefined
    at SnippetExpansion.module.exports.SnippetExpansion.cursorMoved (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81:56)
    at /Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:56:38
    at Function.module.exports.Emitter.simpleDispatch (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Selection.markerDidChange (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/selection.js:932:33)
    at Selection.marker.onDidChange.e (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/selection.js:21:45)
    at Function.module.exports.Emitter.simpleDispatch (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at DisplayMarker.module.exports.DisplayMarker.notifyObservers (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:248:33)
    at /Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:53:32
    at Function.module.exports.Emitter.simpleDispatch (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Marker.module.exports.Marker.emitChangeEvent (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:441:26)
    at Marker.module.exports.Marker.update (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:374:18)
    at Marker.module.exports.Marker.setHeadPosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:149:25)
    at DisplayMarker.module.exports.DisplayMarker.setHeadBufferPosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:146:38)
    at DisplayMarker.module.exports.DisplayMarker.setHeadScreenPosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:154:25)
    at changePosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/cursor.js:68:25)
    at Cursor.changePosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/cursor.js:713:11)
    at Cursor.setScreenPosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/cursor.js:67:16)
    at moveCursors.cursor (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor.js:2519:52)
    at Array.forEach (native)
    at transact (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor.js:2709:31)
    at TextBuffer.module.exports.TextBuffer.transact (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:952:24)
    at TextEditor.transact (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor.js:1839:30)
    at TextEditor.moveCursors (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor.js:2708:23)
    at TextEditor.setCursorScreenPosition (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor.js:2519:23)
    at TextEditorComponent.didMouseDownOnContent (/Users/nivsalamon/Downloads/Atom.app/Contents/Resources/app/src/text-editor-component.js:1801:25)

Commands

  2x -7:25.5.0 core:backspace (input.hidden-input)
     -7:24.2.0 core:save (input.hidden-input)
     -6:27.3.0 core:move-up (input.hidden-input)
     -6:27 core:move-left (input.hidden-input)
  2x -6:26.2.0 core:save (input.hidden-input)
     -5:18.2.0 core:move-up (input.hidden-input)
     -5:17.9.0 core:move-right (input.hidden-input)
  3x -5:16 core:backspace (input.hidden-input)
     -5:10.5.0 core:move-right (input.hidden-input)
  2x -5:09.5.0 core:save (input.hidden-input)
     -1:50.2.0 editor:newline (input.hidden-input)
     -1:32.5.0 core:move-right (input.hidden-input)
     -1:32 editor:newline (input.hidden-input)
     -1:25 autocomplete-plus:confirm (input.hidden-input)
     -1:25 snippets:expand (atom-text-editor.editor.is-focused.autocomplete-active)
     -1:24.4.0 editor:newline (input.hidden-input)

Non-Core Packages

atom-angularjs-snippets 1.1.0 
autoclose-html 0.23.0 
react 0.17.0 
@rcrooks

This comment has been minimized.

rcrooks commented Apr 10, 2018

This is happening to me when I try to type a commit message for a GitHub commit

[Enter steps to reproduce:]

  1. Save file
  2. Stage it
  3. Try to type commit message

Atom: 1.26.0-beta1 x64
Electron: 1.7.11
OS: Mac OS X 10.13.4
Thrown From: Atom Core

Stack Trace

Uncaught TypeError: Cannot read property 'some' of undefined

At /private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:959

TypeError: Cannot read property 'some' of undefined
    at SnippetExpansion.module.exports.SnippetExpansion.cursorMoved (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81:56)
    at /private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:56:38
    at Function.module.exports.Emitter.simpleDispatch (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Selection.markerDidChange (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/selection.js:932:33)
    at Selection.marker.onDidChange.e (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/selection.js:21:45)
    at Function.module.exports.Emitter.simpleDispatch (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at DisplayMarker.module.exports.DisplayMarker.notifyObservers (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:248:33)
    at /private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:53:32
    at Function.module.exports.Emitter.simpleDispatch (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Marker.module.exports.Marker.emitChangeEvent (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:441:26)
    at Marker.module.exports.Marker.update (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:374:18)
    at Marker.module.exports.Marker.setHeadPosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:149:25)
    at DisplayMarker.module.exports.DisplayMarker.setHeadBufferPosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:146:38)
    at DisplayMarker.module.exports.DisplayMarker.setHeadScreenPosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:154:25)
    at changePosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/cursor.js:68:25)
    at Cursor.changePosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/cursor.js:713:11)
    at Cursor.setScreenPosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/cursor.js:67:16)
    at moveCursors.cursor (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor.js:2519:52)
    at Array.forEach (native)
    at transact (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor.js:2709:31)
    at TextBuffer.module.exports.TextBuffer.transact (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:952:24)
    at TextEditor.transact (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor.js:1839:30)
    at TextEditor.moveCursors (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor.js:2708:23)
    at TextEditor.setCursorScreenPosition (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor.js:2519:23)
    at TextEditorComponent.didMouseDownOnContent (/private/var/folders/4f/7s1xcy6d4t7fjnpxy_dkxmnrjrz47n/T/AppTranslocation/6D658BD0-4B32-4C83-B2CC-32784D2F4533/d/Atom Beta.app/Contents/Resources/app/src/text-editor-component.js:1808:25)

Commands

     -1:24.7.0 find-and-replace:show (input.hidden-input)
  4x -1:13.9.0 core:copy (input.hidden-input)
     -0:42.4.0 smart-save:smart-save (input.hidden-input)
  3x -0:37.9.0 core:backspace (input.hidden-input)
     -0:30.1.0 core:copy (input.hidden-input)
     -0:27 core:cut (input.hidden-input)

Non-Core Packages

aligner 1.2.4 
aligner-css 1.2.1 
aligner-javascript 1.3.0 
aligner-php 1.2.0 
api-workbench 0.8.48 
atom-beautify 0.32.2 
atom-ide-ui 0.9.4 
atom-json 0.6.0 
atom-json-color 0.6.0 
atom-json-editor 0.4.1 
atom-minify 0.8.0 
atom-ternjs 0.18.3 
autoclose-html 0.23.0 
autocomplete-json 5.5.2 
autoupdate-packages 1.3.1 
ayu-mirage-atom-syntax 1.0.0 
birds-syntax 0.2.1 
block-select 1.0.0 
busy-signal 1.4.3 
city-lights-syntax 1.1.8 
city-lights-ui 1.3.3 
colorful-json 1.1.0 
creative-af-syntax 0.1.0 
Delete-Whitelines 0.6.3 
directory-color 0.3.0 
docblockr 0.13.7 
double-tag 1.1.0 
emmet 2.4.3 
emmet-snippets-compatibility 1.0.6 
fancy-bracket-matcher 2.1.0 
file-icons 2.1.18 
gaia-dark-syntax 2.1.0 
highlight-line 0.12.0 
highlight-selected 0.13.1 
html-wrapper 0.2.0 
iceberg-syntax 0.2.3 
ide-bash 1.0.10 
ide-html 0.4.2 
ide-json 0.2.1 
ide-php 0.7.14 
ide-yaml 0.4.2 
indent-guide-improved 1.4.13 
intentions 1.1.5 
language-vtt 0.0.2 
line-number-color 0.2.0 
linter 2.2.0 
linter-jshint 3.1.6 
linter-raml 1.0.1 
linter-ui-default 1.7.1 
minima-syntax 0.0.2 
minima-ui 0.0.4 
multi-cursor 2.1.5 
NatureBoi 2.0.0 
night-owl-syntax 1.0.1 
night-owl-ui 1.0.0 
noir-dark-syntax 0.1.0 
nord-atom-syntax 0.9.1 
nord-atom-ui 0.11.0 
one-liner 0.1.3 
pear-dark-syntax 1.0.6 
pigments 0.40.2 
platformio-ide-terminal 2.8.1 
playa-dark-syntax 2.1.0 
predawn-syntax 1.0.4 
pristine-ui 1.1.11 
quilt-syntax 0.4.0 
raml 0.2.0 
raml-snippets 0.1.0 
red-wavy-underline 0.3.3 
select-text-between-tags 0.1.0 
seti-ui 1.10.0 
simple-drag-drop-text 0.4.0 
smart-save 0.6.1 
splash-ui 0.4.0 
tag 0.5.0 
talamasca 1.3.0 
teletype 0.12.0 
todo-show 2.3.0 
tree-view-git-branch 0.1.2 
tree-view-git-status 1.4.0 
tuesday-syntax 0.1.2 
w3c-validation 0.4.0 
white-cursor 0.7.0 
yaml-path 0.1.1 
@rsese

This comment has been minimized.

Member

rsese commented Apr 10, 2018

Thanks @rcrooks:

Save file
Stage it
Try to type commit message

I'm unable to reproduce with these steps on macOS 10.12.6 with 1.26.0-beta1 - can you reproduce in safe mode?

@bravenewamber

This comment has been minimized.

bravenewamber commented Apr 11, 2018

I am also having this issue, but I took slightly different steps.

[Enter steps to reproduce:]

  1. Save file
  2. Use platformio-ide-terminal to stage and commit using CLI
  3. Open Git panel & click "Amend" checkbox
  4. Began typing new commit message
  • The error did not start presenting originally until I typed in all caps
  • After posting this, I unchecked the "Amend" checkbox, re-checked it, and then it started happening every time I clicked on the textarea.

Atom: 1.25.1 x64
Electron: 1.7.11
OS: Mac OS X 10.12.6
Thrown From: Atom Core

Stack Trace

Uncaught TypeError: Cannot read property 'some' of undefined

At /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:959

TypeError: Cannot read property 'some' of undefined
    at SnippetExpansion.module.exports.SnippetExpansion.cursorMoved (/Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81:56)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:56:38
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Selection.markerDidChange (/Applications/Atom.app/Contents/Resources/app/src/selection.js:932:33)
    at Selection.marker.onDidChange.e (/Applications/Atom.app/Contents/Resources/app/src/selection.js:21:45)
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at DisplayMarker.module.exports.DisplayMarker.notifyObservers (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:248:33)
    at /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:53:32
    at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20)
    at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34)
    at Marker.module.exports.Marker.emitChangeEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:441:26)
    at Marker.module.exports.Marker.update (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:374:18)
    at Marker.module.exports.Marker.setHeadPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:149:25)
    at DisplayMarker.module.exports.DisplayMarker.setHeadBufferPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:146:38)
    at DisplayMarker.module.exports.DisplayMarker.setHeadScreenPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:154:25)
    at changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:68:25)
    at Cursor.changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:713:11)
    at Cursor.setScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:67:16)
    at moveCursors.cursor (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:2519:52)
    at Array.forEach (native)
    at transact (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:2709:31)
    at TextBuffer.module.exports.TextBuffer.transact (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:952:24)
    at TextEditor.transact (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:1839:30)
    at TextEditor.moveCursors (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:2708:23)
    at TextEditor.setCursorScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:2519:23)
    at TextEditorComponent.didMouseDownOnContent (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:1801:25)

Commands

     -7:22.8.0 editor:newline (input.hidden-input)
     -0:50.7.0 emmet:expand-abbreviation (input.hidden-input)
     -0:38.2.0 core:backspace (input.hidden-input)

Non-Core Packages

ask-stack 2.2.0 
atom-material-syntax-dark 1.0.0 
atom-material-ui 2.1.3 
atom-minify 0.8.0 
atom-wordpress 0.3.0 
atom-wrap-in-tag 0.6.0 
city-lights-icons 1.1.1 
clipboard-plus 0.5.1 
color-indent 0.5.3 
css-snippets 1.1.0 
double-tag 1.1.0 
emmet 2.4.3 
emmet-snippets-compatibility 1.0.6 
expose 0.15.0 
file-icons 2.1.18 
gruvbox-plus-syntax 1.3.1 
jQuery 1.2.6 
open-recent 5.0.0 
pigments 0.40.2 
platformio-ide-terminal 2.8.1 
predawn-syntax 1.0.4 
project-manager 3.3.5 
reindent 1.4.0 
scroll-through-time 0.3.0 
seti-icons 1.5.4 
tone-syntax 0.2.1 
@rcrooks

This comment has been minimized.

rcrooks commented Apr 11, 2018

Interesting....I think I've also been seeing the error in the Git pane after using platformio-ide-terminal (for something else)

@Ben3eeE

This comment has been minimized.

Member

Ben3eeE commented Apr 12, 2018

@rsese I see this when trying to expand a snippet in the github commit editor. Also see #16997

commit editor issue thing 2

@iarobinson

This comment has been minimized.

iarobinson commented Apr 12, 2018

Atom links me to here as it's predicting that I'm having the same issue.

It appears that I am. I'll describe my process for getting here:

  • Started a new index.html document using the terminal
  • Wrote basic HTML5 creation code
  • When I wrote the JS for the window.onload, the error arrived
  • The error is triggered when I click the 'delete' key on my macbook's keyboard

- When I click outside the error message, a new error message appears

- The error message appears with each of the following events 1. I click delete key on keyboard 2. I mouse click anywhere in the error-prone atom file 3. I use arrow keys to move cursor 4. I click the tab key. At this point, I can add to the text document with other keys, but I cannot delete or navigate the cursor. - When I create a new text file, the program performs without error. This suggests to me that the error is specific to the code I have written in index.html | Here is that code:
<script> function init() { var loadButton = window.getElementById()''===]asdfasdf123 } window.onload = init; </script>

Click Here to Load Title
  • When I save the document (cmd + a), close the window and reopen the same file, the error message stops appearing

About my system:

  • I'm on macOS Sierra version 10.12.6
  • Atom version 1.25.1 x64

TypeError: Cannot read property 'some' of undefined at SnippetExpansion.module.exports.SnippetExpansion.cursorMoved (/Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:81:56) at /Applications/Atom.app/Contents/Resources/app/node_modules/snippets/lib/snippet-expansion.js:56:38 at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20) at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34) at Selection.markerDidChange (/Applications/Atom.app/Contents/Resources/app/src/selection.js:932:33) at Selection.marker.onDidChange.e (/Applications/Atom.app/Contents/Resources/app/src/selection.js:21:45) at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20) at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34) at DisplayMarker.module.exports.DisplayMarker.notifyObservers (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:248:33) at /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:53:32 at Function.module.exports.Emitter.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:25:20) at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:141:34) at Marker.module.exports.Marker.emitChangeEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:441:26) at Marker.module.exports.Marker.update (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:374:18) at Marker.module.exports.Marker.setHeadPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/marker.js:149:25) at DisplayMarker.module.exports.DisplayMarker.setHeadBufferPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:146:38) at DisplayMarker.module.exports.DisplayMarker.setHeadScreenPosition (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/display-marker.js:154:25) at changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:68:25) at Cursor.changePosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:713:11) at Cursor.setScreenPosition (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:67:16) at Cursor.moveLeft (/Applications/Atom.app/Contents/Resources/app/src/cursor.js:288:18) at modifySelection (/Applications/Atom.app/Contents/Resources/app/src/selection.js:252:50) at Selection.modifySelection (/Applications/Atom.app/Contents/Resources/app/src/selection.js:984:11) at Selection.selectLeft (/Applications/Atom.app/Contents/Resources/app/src/selection.js:252:16) at Selection.backspace (/Applications/Atom.app/Contents/Resources/app/src/selection.js:496:36) at mutateSelectedText.selection (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:1373:65) at getSelectionsOrderedByBufferPosition.map (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:1387:92) at Array.map (native) at transact (/Applications/Atom.app/Contents/Resources/app/src/text-editor.js:1387:66) at TextBuffer.module.exports.TextBuffer.transact (/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:952:24) This is likely a bug in Atom.

Just put this out there to support.

@rsese

This comment has been minimized.

Member

rsese commented Apr 12, 2018

@rsese I see this when trying to expand a snippet in the github commit editor. Also see #16997

Thanks @Ben3eeE 🙇 I'll add your steps to the issue body.

And thanks everyone else for sharing your repro steps - it seems like in some of these other cases it's not reproducible in safe mode so is likely related to one of your community packages (e.g. maybe emmet or platformio-ide-terminal. Luckily @Ben3eeE's repro steps work in safe mode though.

@lock

This comment has been minimized.

lock bot commented Oct 22, 2018

This issue has been automatically locked since there has not been any recent activity after it was closed. If you can still reproduce this issue in Safe Mode then please open a new issue and fill out the entire issue template to ensure that we have enough information to address your issue. Thanks!

@lock lock bot locked as resolved and limited conversation to collaborators Oct 22, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.