Skip to content
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

OSX app always crash on first launch #86

Closed
metalelf0 opened this issue Oct 28, 2019 · 7 comments
Closed

OSX app always crash on first launch #86

metalelf0 opened this issue Oct 28, 2019 · 7 comments

Comments

@metalelf0
Copy link

Hi,

just downloaded the latest release and I cannot start fvim from osx.

Here's the window I get with the error message:

Schermata 2019-10-28 alle 09 29 17

Currently installed neovim version is NVIM v0.5.0-53b0258. OS is macOS Catalina 10.15 (19A602). Let me know if I can provide any further info.

Thanks!

@yatli
Copy link
Owner

yatli commented Oct 28, 2019

Hi @metalelf0 !

Thanks for reporting.
Can you start nvim in a terminal?

@metalelf0
Copy link
Author

Yes, I use it regularly. Strange thing is, I just tried opening fvim again, and it started normally (just a couple warnings about ginit.vim, but nothing critical). The message I posted above has been shown only on first start.

@yatli
Copy link
Owner

yatli commented Oct 28, 2019

Other users also report this symptom. Weird indeed.

I've edited the title a bit. Let's keep this issue open so we can track and fix this.

@yatli yatli changed the title Can't start latest OSx release OSX app always crash on first launch Oct 28, 2019
@bitmappergit
Copy link

I've got this issue too.

@khalidchawtany
Copy link

khalidchawtany commented May 15, 2020

In my case most of the times it crashes. I am very lucky to get it working. I get a blank (black) screen.

$ ./FVim --trace-to-stdout
log: fvim started. time = 5/15/2020 6:06:04 PM
model: starting neovim instance...
model: opts = { intent = Start
  logToStdout = true
  logToFile = false
  logPatterns = None
  args = ["--embed"]
  program = "nvim"
  stderrenc = System.Text.UTF8Encoding+UTF8EncodingSealed
  serveropts = StartNew }
neovim.process: Starting process. Program: nvim; Arguments: --embed
neovim.process: begin read loop
model: commencing early initialization...
neovim.process: call: 0 -> [0,0,"nvim_get_api_info",[]]
model: available ui options: set
  ["ext_cmdline"; "ext_hlstate"; "ext_linegrid"; "ext_messages"; "ext_multigrid";
   "ext_popupmenu"; "ext_tabline"; "ext_termcolors"; "ext_wildmenu"; ...]
neovim.process: call: 1 -> [0,1,"nvim_set_var",["fvim_loaded",1]]
neovim.process: call: 2 -> [0,2,"nvim_set_client_info",["FVim",{"major":"0","minor":"2","prerelease":"dev"},"ui",{},{"InstanceId":"0f85ec94-29af-40b0-8d4f-acc3ada870bc"}]]
neovim.process: call: 3 -> [0,3,"nvim_list_chans",[]]
model: FVim connected clients: [("0f85ec94-29af-40b0-8d4f-acc3ada870bc", 1)]
model: FVim client channel is: 1
neovim.process: call: 4 -> [0,4,"nvim_command",["let g:clipboard = {  'name': 'FVimClipboard',  'copy': {     '+': {lines, regtype -> rpcrequest(1, 'set-clipboard', lines, regtype)},     '*': {lines, regtype -> rpcrequest(1, 'set-clipboard', lines, regtype)},   },  'paste': {     '+': {-> rpcrequest(1, 'get-clipboard')},     '*': {-> rpcrequest(1, 'get-clipboard')},  },}"]]
neovim.process: call: 5 -> [0,5,"nvim_set_var",["fvim_channel",1]]
neovim.process: call: 6 -> [0,6,"nvim_command",["command! -nargs=0 FVimDetach call rpcnotify(1, 'remote.detach')"]]
neovim.process: call: 7 -> [0,7,"nvim_command",["command! -nargs=0 FVimToggleFullScreen call rpcnotify(1, 'ToggleFullScreen', 1)"]]
neovim.process: call: 8 -> [0,8,"nvim_command",["command! -nargs=1 -complete=expression FVimCursorSmoothMove call rpcnotify(1, 'cursor.smoothmove', <args>)"]]
neovim.process: call: 9 -> [0,9,"nvim_command",["command! -nargs=1 -complete=expression FVimCursorSmoothBlink call rpcnotify(1, 'cursor.smoothblink', <args>)"]]
neovim.process: call: 10 -> [0,10,"nvim_command",["command! -nargs=1 -complete=expression FVimFontLineHeight call rpcnotify(1, 'font.lineheight', <args>)"]]
neovim.process: call: 11 -> [0,11,"nvim_command",["command! -nargs=1 -complete=expression FVimFontAutoSnap call rpcnotify(1, 'font.autosnap', <args>)"]]
neovim.process: call: 12 -> [0,12,"nvim_command",["command! -nargs=1 -complete=expression FVimFontAntialias call rpcnotify(1, 'font.antialias', <args>)"]]
neovim.process: call: 13 -> [0,13,"nvim_command",["command! -nargs=1 -complete=expression FVimFontDrawBounds call rpcnotify(1, 'font.drawBounds', <args>)"]]
neovim.process: call: 14 -> [0,14,"nvim_command",["command! -nargs=1 -complete=expression FVimFontAutohint call rpcnotify(1, 'font.autohint', <args>)"]]
neovim.process: call: 15 -> [0,15,"nvim_command",["command! -nargs=1 -complete=expression FVimFontSubpixel call rpcnotify(1, 'font.subpixel', <args>)"]]
neovim.process: call: 16 -> [0,16,"nvim_command",["command! -nargs=1 -complete=expression FVimFontLcdRender call rpcnotify(1, 'font.lcdrender', <args>)"]]
neovim.process: call: 17 -> [0,17,"nvim_command",["command! -nargs=1 -complete=expression FVimFontHintLevel call rpcnotify(1, 'font.hindLevel', <args>)"]]
neovim.process: call: 18 -> [0,18,"nvim_command",["command! -nargs=1 -complete=expression FVimFontNormalWeight call rpcnotify(1, 'font.weight.normal', <args>)"]]
neovim.process: call: 19 -> [0,19,"nvim_command",["command! -nargs=1 -complete=expression FVimFontBoldWeight call rpcnotify(1, 'font.weight.bold', <args>)"]]
neovim.process: call: 20 -> [0,20,"nvim_command",["command! -nargs=1 -complete=expression FVimKeyDisableShiftSpace call rpcnotify(1, 'key.disableShiftSpace', <args>)"]]
neovim.process: call: 21 -> [0,21,"nvim_command",["command! -nargs=1 -complete=expression FVimUIMultiGrid call rpcnotify(1, 'ui.multigrid', <args>)"]]
neovim.process: call: 22 -> [0,22,"nvim_command",["command! -nargs=1 -complete=expression FVimUIPopupMenu call rpcnotify(1, 'ui.popupmenu', <args>)"]]
neovim.process: call: 23 -> [0,23,"nvim_command",["command! -nargs=1 -complete=expression FVimUITabLine call rpcnotify(1, 'ui.tabline', <args>)"]]
neovim.process: call: 24 -> [0,24,"nvim_command",["command! -nargs=1 -complete=expression FVimUICmdLine call rpcnotify(1, 'ui.cmdline', <args>)"]]
neovim.process: call: 25 -> [0,25,"nvim_command",["command! -nargs=1 -complete=expression FVimUIWildMenu call rpcnotify(1, 'ui.wildmenu', <args>)"]]
neovim.process: call: 26 -> [0,26,"nvim_command",["command! -nargs=1 -complete=expression FVimUIMessages call rpcnotify(1, 'ui.messages', <args>)"]]
neovim.process: call: 27 -> [0,27,"nvim_command",["command! -nargs=1 -complete=expression FVimUITermColors call rpcnotify(1, 'ui.termcolors', <args>)"]]
neovim.process: call: 28 -> [0,28,"nvim_command",["command! -nargs=1 -complete=expression FVimUIHlState call rpcnotify(1, 'ui.hlstate', <args>)"]]
neovim.process: call: 29 -> [0,29,"nvim_command",["command! -nargs=1 -complete=expression FVimDrawFPS call rpcnotify(1, 'DrawFPS', <args>)"]]
neovim.process: call: 30 -> [0,30,"nvim_command",["command! -nargs=1 -complete=expression FVimCustomTitleBar call rpcnotify(1, 'CustomTitleBar', <args>)"]]
neovim.process: call: 31 -> [0,31,"nvim_command",["command! -nargs=1 -complete=expression FVimBackgroundOpacity call rpcnotify(1, 'background.opacity', <args>)"]]
neovim.process: call: 32 -> [0,32,"nvim_command",["command! -nargs=1 -complete=expression FVimBackgroundComposition call rpcnotify(1, 'background.composition', <args>)"]]
neovim.process: call: 33 -> [0,33,"nvim_command",["command! -nargs=1 -complete=expression FVimBackgroundAltOpacity call rpcnotify(1, 'background.altopacity', <args>)"]]
neovim.process: call: 34 -> [0,34,"nvim_command",["autocmd VimEnter * runtime! ginit.vim"]]
ui: GetTypeface: allocating new typeface Menlo:false:false
editorvm #1: fontConfig: glyphsize=9.933837890625, 19, measured font size=16.5
mainwindow: configBackground: SolidBackground #00000000
cursor: render tick 0
cursor: setCursorAnimation: blink=false, move=false
mainwindow: set position: 608, 266
editor #1: viewmodel connected
cursor: render tick 1
editor #1: MeasureOverride: 1260, 735
editorvm #1: set measured size: 1260, 735
model: attaching to nvim on first grid ready signal. size = 126 0
neovim.process: call: 35 -> [0,35,"nvim_ui_attach",[126,0,{"rgb":true,"ext_linegrid":true,"ext_popupmenu":true,"ext_multigrid":false,"ext_tabline":false,"ext_cmdline":false,"ext_wildmenu":false,"ext_messages":false,"ext_hlstate":false,"ext_termcolors":false}]]
neovim.process: call 35: error response [|1uy; "Expected width > 0 and height > 0"|]
editor #1: MeasureOverride: 666, 600
editorvm #1: set measured size: 666, 600
model: Grid #1 resized to 67 31
neovim.process: call: 36 -> [0,36,"nvim_ui_try_resize",[67,31]]
neovim.process: call 36: error response [|0uy; "UI not attached to channel: 1"|]
model: Grid #1 resized to 67 31
neovim.process: call: 37 -> [0,37,"nvim_ui_try_resize",[67,31]]
neovim.process: call 37: error response [|0uy; "UI not attached to channel: 1"|]
ui: GetTypeface: allocating new typeface :false:false
cursor: setCursorAnimation: blink=false, move=false
cursor: setCursorAnimation: blink=false, move=false
cursor: setCursorAnimation: blink=false, move=false
model: window is closing
neovim.process: call: 38 -> [0,38,"nvim_command",["confirm quitall"]]
error: model: neovim:
neovim.process: exception: System.InvalidOperationException: Invalid MessagePack code was detected, code:-1
   at MessagePack.MessagePackBinary.ReadMessageBlockFromStreamCore(Stream stream, Byte[]& bytes, Int32 offset, Boolean readOnlySingleMessage)
   at MessagePack.MessagePackBinary.ReadMessageBlockFromStreamUnsafe(Stream stream, Boolean readOnlySingleMessage, Int32& readSize)
   at MessagePack.MessagePackSerializer.Deserialize[T](Stream stream, IFormatterResolver resolver, Boolean readStrict)
   at FVim.neovim.read@112-1.Invoke()
neovim.process: end read loop: process exited, code = 0
model: window is closing
neovim.process: call: 39 -> [0,39,"nvim_command",["confirm quitall"]]

It stops at this line
neovim.process: call 37: error response [|0uy; "UI not attached to channel: 1"|]

@khalidchawtany
Copy link

I don't get crashed anymore :)

@yatli
Copy link
Owner

yatli commented Nov 1, 2020

Some findings here. The crash usually doesn't reveal the "real exception" but if you go into the app package folder and invoke fvim-osx-launcher, the exception will be printed to the terminal.

I've got a null value exception caused by $HOME not set in the launcher environment.
Working on a new launcher script that will solve #86, #145, #128

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants