Closed byteofsoren closed 1 year ago
We will need to narrow down what is conflicting.
The typical approach is to "bisect" your vimrc, i.e. comment out the top "half" and see if it goes away, then try the bottom "half" etc.
However, I can provide a hint based on the above. First - it's not YCM that's causing the E881 error, even though it looks like it is. Second, from the error I can see that it's a call to loadview
that is causing the error:
Vim(loadview)
YCM does not use :loadview
anywhere.
Therefore I suspect what's happening, given the location of :help E881
, something has an autocommand that is calling loadview
(heinously!) in FileChanged
or FileChangedRO
autocommand (or something like that). I suggest scanning your plugins for calls to loadview
.
Closing as most likely not a YCM bug.
FWIW this issue seems kind of similar to something I saw reported against vimspector. IIRC it was some plugin that "maximised" windows or something that was recommended by some YouTuber or other for unknowable reasons. Just a hint, I really don't know and without being able to repro, there's little I can do.
I suggest scanning your plugins for calls to loadview.
Found it in my vimrc. I think this code was generated by an old vimrc online generator.
augroup remember_folds
autocmd!
autocmd BufWinLeave ?* mkview | filetype detect
autocmd BufWinEnter ?* silent loadview | filetype detect
augroup END
Thank you @puremourning!
Found a new problem to solve.
2023-05-10 00:50:14,754 - INFO - Adding buffer identifiers for file: /home/soren/tmp/udmy/esp32_udemy/main/main.c 13 Traceback (most recent call last): 14 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/third_party/bottle/bottle.py", line 876, in _handle 15 return route.call(**args) 16 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/third_party/bottle/bottle.py", line 1756, in wrapper 17 rv = callback(*a, **ka) 18 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/watchdog_plugin.py", line 97, in wrapper 19 return callback( *args, **kwargs ) 20 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/hmac_plugin.py", line 62, in wrapper
21 body = callback( *args, **kwargs ) 22 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/handlers.py", line 65, in EventNotification 23 response_data = getattr( _server_state.GetFiletypeCompleter( filetypes ), 24 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/completers/language_server/language_server_completer.py", lin e 1884, in OnFileReadyToParse 25 self._StartAndInitializeServer( request_data ) 26 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/completers/language_server/language_server_completer.py", lin e 1870, in _StartAndInitializeServer 27 self._extra_conf_dir = self._GetSettingsFromExtraConf( request_data ) 28 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/completers/language_server/language_server_completer.py", lin e 1838, in _GetSettingsFromExtraConf
29 module = extra_conf_store.ModuleForSourceFile( request_data[ 'filepath' ] )
30 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/extra_conf_store.py", line 55, in ModuleForSourceFile
31 return Load( ModuleFileForSourceFile( filename ) )
32 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/extra_conf_store.py", line 66, in ModuleFileForSourceFile
33 if Load( module_file ):
34 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/extra_conf_store.py", line 151, in Load
35 if not force and not _ShouldLoad( module_file, is_global ):
36 File "/home/soren/.vim/plugged/YouCompleteMe/third_party/ycmd/ycmd/extra_conf_store.py", line 134, in _ShouldLoad
37 raise UnknownExtraConf( module_file )
38 ycmd.responses.UnknownExtraConf: Found /home/soren/tmp/udmy/esp32_udemy/.ycm_extra_conf.py. Load?
This is perhaps a problem with my .ycm_extra_conf.py
file?
Will investigate that to morrow.
The above is perfectly normal.
Issue Prelude
Please complete these steps and check these boxes (by putting an
x
inside the brackets) before filing your issue:vim --version
.:YcmDebugInfo
.:YcmToggleLogs
command.vim -Nu /path/to/YCM/vimrc_ycm_minimal
, including what I expected to happen and what actually happened.install.py
(orcmake
/make
/ninja
) including its invocationThank you for adhering to this process! It ensures your issue is resolved quickly and that neither your nor our time is needlessly wasted.
Disclaimer
First if mods decides that this should not belong here they are free to close, remove or nuke it to orbit, its okay for me.
Second my vimrc contains an error or it is an incompatibility with a other plugin. With this issue I hope to let the core developers know if/when I find my problem what the problem was and let the developers know that this could be an issue with that particular error and perhaps finds a way to do some thing with that in the code. Third, my vimrc is complex and perhaps bloated but I need quite few of those mods for my job, sorry for the mess.
You can find it here Vimrc
Issue Details
After installation of YcM I created a main.c and started typing code. Then I executed the :YcmDiags command and got the following error message:
If I use the ycm_vimrc_minimal then YcmDiags works. So Its my vimrc that causes the problem, but why? I tested to disable each plugin I have in the vimrc but the problem remains.
Diagnostic data
Output of
vim --version
Output of
YcmDebugInfo
Output of
YcmDiags
Already done.Output of
git rev-parse HEAD
in YouCompleteMe installation directoryContents of YCM, ycmd and completion engine logfiles
OS version, distribution, etc.
Linux
Output of build/install commands