Ycmd server crashes when opening a file in a folder containing a file named commands.py

Bug #1678469 reported by Raziman T V on 2017-04-01
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
vim-youcompleteme (Ubuntu)
Undecided
Unassigned

Bug Description

On Ubuntu 17.04 (development branch), vim-youcompleteme version 0+20161219+git194ff33-1

Youcompleteme works perfectly well in most situations. Except when vim is launched in a folder containing a file named 'commands.py' (irrespective of the contents of the file, even if it is empty) - in that case, the Ycmd server crashes. All the log files are empty, but this is what I see in vim:

"test.cpp" [New File]
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
Traceback (most recent call last):
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
  File "<string>", line 1, in <module>
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
  File "/usr/share/vim-youcompleteme/python/ycm/youcompleteme.py", line 351, in OnFileReadyToParse
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
    self._NotifyUserIfServerCrashed()
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
  File "/usr/share/vim-youcompleteme/python/ycm/youcompleteme.py", line 239, in _NotifyUserIfServerCrashed
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
    server_stderr = '\n'.join(self._server_popen.stderr.read().splitlines() )
Press ENTER or type command to continue
Error detected while processing function youcompleteme#Enable[62]..<SNR>54_OnBufferRead[20]..<SNR>54_OnFileReadyToParse:
line 13:
TypeError: sequence item 0: expected str instance, bytes found

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers