ycm-core/YouCompleteMe

OpenBSD 7.4 Python module fails to load

Closed this issue · 2 comments

Issue Prelude

Please complete these steps and check these boxes (by putting an x inside
the brackets) before filing your issue:

  • [ X ] I have read and understood YCM's CONTRIBUTING document.
  • [ X ] I have read and understood YCM's CODE_OF_CONDUCT document.
  • [ X ] I have read and understood YCM's README, especially the
    Frequently Asked Questions section.
  • [ X ] I have searched YCM's issue tracker to find issues similar to the one I'm
    about to report and couldn't find an answer to my problem. (Example Google
    search.
    )
  • [ X ] If filing a bug report, I have included the output of vim --version.
  • [ X ] If filing a bug report, I have included the output of :YcmDebugInfo.
  • [ X ] If filing a bug report, I have attached the contents of the logfiles using
    the :YcmToggleLogs command.
  • [ X ] If filing a bug report, I have included which OS (including specific OS
    version) I am using.
  • [ X ] If filing a bug report, I have included a minimal test case that reproduces
    my issue, using vim -Nu /path/to/YCM/vimrc_ycm_minimal, including what I
    expected to happen and what actually happened.
  • [ X ] If filing a installation failure report, I have included the entire output
    of install.py (or cmake/make/ninja) including its invocation
  • [ X ] I understand this is an open-source project staffed by volunteers and
    that any help I receive is a selfless, heartfelt gift of their free time. I
    know I am not entitled to anything and will be polite and courteous.
  • [ X ] I understand my issue may be closed if it becomes obvious I didn't
    actually perform all of these steps.

Thank you for adhering to this process! It ensures your issue is resolved
quickly and that neither your nor our time is needlessly wasted.

Issue Details

The module fails to load on OpenBSD. It tries to load the .so file, but fails and says "Cannot load specified object".

I have tried the "Run YCM Manually" step per https://github.com/ycm-core/YouCompleteMe/wiki/Troubleshooting-steps-for-ycmd-server-SHUT-DOWN and got the same issue as is noted in the ycmd stderr log in the gist below.

I then tried running it with the flag LD_DEBUG=1 as follows env LD_DEBUG=1 python3.10 ycmd --options_file=default_settings.json and got the output in this gist: https://gist.github.com/Jaywalker/e353ea8ab31b209ce59e5c5ad142b663

Most notable line to me is line 602: dlopen: /home/jaywalker/.config/nvim/plugged/YouCompleteMe/third_party/ycmd/ycm_core.cpython-310.so: done (failed).

  • What did you do?
  1. Open vim
  2. See the report that the YCM server has failed
  • What did you expect to happen?

YCM to run.

  • What actually happened?

It says the YCM server is shutdown.

Diagnostic data

Output of vim --version

NVIM v0.9.1
Build type: Release
LuaJIT 2.1.0-beta3

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/usr/local/share/nvim"

Run :checkhealth for more info

Output of YcmDebugInfo

Printing YouCompleteMe debug information...
-- Resolve completions: Up front
-- Client logfile: /tmp/ycm_5yba4vp4.log
-- Server errored, no debug info from server
-- Server running at: http://127.0.0.1:31439
-- Server process ID: 11829
-- Server logfiles:
--   /tmp/ycmd_31439_stdout_kob6taco.log
--   /tmp/ycmd_31439_stderr_banvy3ej.log
-- Semantic highlighting supported: False
-- Virtual text supported: False
-- Popup windows supported: False

Output of YcmDiags

Native filetype completion not supported for current file, cannot force recompilation.

Output of git rev-parse HEAD in YouCompleteMe installation directory

79c850b4a674a4f461a670f4515ab953bb89d632

Contents of YCM, ycmd and completion engine logfiles

https://gist.github.com/Jaywalker/bf28d07a66eeb1ea050793075a5e861e
https://gist.github.com/Jaywalker/66ef3959dfc459b2171f0a659055b463

OS version, distribution, etc.

OpenBSD 7.4

Output of build/install commands

https://gist.github.com/Jaywalker/8ec1b4a7a5bf404ce20d4d5cb8e6edfa

I see you are using the legacy --clang-completer. I would advise you to skip that flag and instead set g:ycm_clangd_binary_path.

Aha! I didn't realize that was deprecated. Completion is working as expected with that fix in place. Thanks!