OmniSharp / omnisharp-atom

Omnisharp support for the atom editor
https://atom.io/packages/omnisharp-atom
MIT License
318 stars 61 forks source link

Uncaught TypeError: Cannot read property 'error' of undefined #253

Closed luboid closed 9 years ago

luboid commented 9 years ago

[Enter steps to reproduce below:]

  1. Atom is installed as Portable
  2. install omnisharp
  3. restart atom
  4. create file - test.cs
  5. Menu -> Omnisharp -> Toggole

Atom Version: 0.198.0 System: Microsoft Windows 8.1 Thrown From: omnisharp-atom package, v0.4.24

Stack Trace

Uncaught TypeError: Cannot read property 'error' of undefined

At C:\Tools\atom\packages\omnisharp-atom\node_modules\omnisharp-node-client\lib\drivers\stdio.js:76

TypeError: Cannot read property 'error' of undefined
  at Socket.<anonymous> (C:\Tools\atom\packages\omnisharp-atom\node_modules\omnisharp-node-client\lib\drivers\stdio.js:76:70)
  at emitOne (events.js:82:20)
  at Socket.emit (events.js:166:7)
  at readableAddChunk (_stream_readable.js:146:16)
  at Socket.Readable.push (_stream_readable.js:109:10)
  at Pipe.onread (net.js:517:20)

Commands

  2x -0:36.9.0 omnisharp-atom:toggle (atom-text-editor.editor.is-focused)

Config

{
  "core": {}
}

Installed Packages

# User
.bin, vundefined
atom-typescript, v4.2.4
atom-yeoman, v0.2.0
autocomplete-plus, v2.14.1
autocomplete-plus-async, v0.22.0
language-asp, v1.0.0
language-aspx, v0.4.0
linter, v0.12.2
omnisharp-atom, v0.4.24

# Dev
No dev packages
GeordieP commented 9 years ago

Getting the same issue on a non-portable install of Atom (Windows), when using File > Add Project Folder, then opening an existing .cs file. Error is produced again when toggling omnisharp off.

nosami commented 9 years ago

Thanks for the report. I'll have a look into this.

btw. you should uninstall autocomplete-plus-async

jchannon commented 9 years ago

getting same error after latest install

douglasstarnes commented 9 years ago

I'm getting a similar error on OS X (Yosemite) and Ubuntu 14.04. This is possibly related to the issue I posted earlier (#276). The error I receive is:

Uncaught TypeError: Cannot read property 'stdin' of null

And the stack trace on OS X:

TypeError: Cannot read property 'stdin' of null
  at StdioDriver.request (/Users/userfolder/.atom/packages/omnisharp-atom/node_modules/omnisharp-client/lib/drivers/stdio.js:130:22)
  at Client.OmnisharpClient.request (/Users/userfolder/.atom/packages/omnisharp-atom/node_modules/omnisharp-client/lib/omnisharp-client.js:108:35)
  at Client.OmnisharpClient.codecheck (/Users/userfolder/.atom/packages/omnisharp-atom/node_modules/omnisharp-client/lib/omnisharp-client.js:217:21)
  at Client.OmnisharpClient.codecheckPromise (/Users/userfolder/.atom/packages/omnisharp-atom/node_modules/omnisharp-client/lib/omnisharp-client.js:220:21)
  at LinterCSharp.lintFile (/Users/userfolder/.atom/packages/omnisharp-atom/lib/omnisharp-atom/linter.ts:41:21)
  at /Users/userfolder/.atom/packages/linter/lib/linter-view.coffee:163:18
  at Array.forEach (native)
  at /Users/userfolder/.atom/packages/linter/lib/linter-view.coffee:162:18
  at FSReqWrap.oncomplete (fs.js:77:15)

Using version 0.199.0 of Atom and 0.4.29 of omnisharp-atom (just updated this morning)

david-driscoll commented 9 years ago

I think​ I know what is going on with this problem now, and have a replication, so I'm working on it.

david-driscoll commented 9 years ago

Try 0.4.33 and let us know if it's still an issue!

douglasstarnes commented 9 years ago

This appears to be fixed but see #301.