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

After getting around some installation issues on macOS, no response to global hotkeys. #19

Open
slackwing opened this issue Dec 22, 2019 · 4 comments

Comments

@slackwing
Copy link

I'm on macOS High Sierra 10.13.6 and encountered the same issues as @slashinfty in #15, but got past them. However, the application does not respond to any of the global hotkeys.


First though, it should be mentioned that at first I skipped opam switch 4.07.0 because it asked if I meant opam switch create 4.07.0 instead. I figured I'd take my chances with the newer version I had installed (4.09.x) than do something that seemed semantically different. Later in a second attempt I came back to try opam switch create 4.07.0.

Either way, on dune build I got the message about uuseg, lwt_ppx, and uutf being missing. (And one of the hints has a typo, saying to install uuset instead of uuseg.) After installing these, in my first attempt with 4.09.x I got the same as @slashinfty, about pp_set_formatter_tag_functions being deprecated. But on my second attempt with 4.07.0, I had less errors, only this:

$ dune build
File "_none_", line 1:
Warning 58: no cmx file was found in path for module Toploop, and its interface was not compiled with -opaque
File "vendor/notty/lwt/notty_lwt.ml", line 68, characters 25-64:
Error: This expression has type (unit -> unit) Lwt.t
       but an expression was expected of type unit Lwt.t
       Hint: Did you forget to provide `()' as argument?

Opening up vendor/notty/lwt/notty_lwt.ml and changing

Lwt.async (fun () -> Lwt_stream.closed stream >|= fun _ -> f);

to

Lwt.async (fun () -> Lwt_stream.closed stream >|= fun _ -> f ());

fixed this for me, despite warnings. I was then able to dune install and run flitter examples/my-splits.scm:

image

Unfortunately, none of the global hotkeys do anything, whether or not the terminal is focused.

If the author would like to pair on solving this issue for macOS, happy to offer my time in exchange for guidance. @alexozer

@slackwing
Copy link
Author

Additionally I seem unable to ^z or ^c out of the application. Not sure if that's normal or not.

Anyway, let's see if fixing some of the warnings solves the issue:

11:22 $ dune build
File "_none_", line 1:
Warning 58: no cmx file was found in path for module Toploop, and its interface was not compiled with -opaque
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 6-24:
Warning 3: deprecated: module Lwt_sequence
 Use package lwt-dllist. See
   https://github.com/mirage/lwt-dllist
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 47-66:
Warning 3: deprecated: Lwt_main.exit_hooks
 Use module Lwt_main.Exit_hooks.
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 6-24:
Warning 3: deprecated: module Lwt_sequence
 Use package lwt-dllist. See
   https://github.com/mirage/lwt-dllist
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 47-66:
Warning 3: deprecated: Lwt_main.exit_hooks
 Use module Lwt_main.Exit_hooks.

Changing Lwt_main.exit_hooks to Lwt_main.Exit_hooks results in

11:25 $ dune build
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 6-24:
Warning 3: deprecated: module Lwt_sequence
 Use package lwt-dllist. See
   https://github.com/mirage/lwt-dllist
File "vendor/notty/lwt/notty_lwt.ml", line 131, characters 47-66:
Error: Unbound constructor Lwt_main.Exit_hooks

and I'm not sure what to do about that. It seems the version of lwt is quite old though, so maybe I will try using a more recent version.

@slackwing
Copy link
Author

slackwing commented Dec 22, 2019

Saw @OlivierBlanvillain's PR #17 and decided to give it a shot.

  1. Updated url in .gitmodules as directed in Update to notty v0.2.2 upsteam #17.
  2. Undid my changes in vendor/notty by going to vendor/notty and doing git reset --hard.
  3. Went back to flitter dir and updated submodules with git submodule update --init --recursive --remote.
  4. dune build

Now seeing

11:43 $ dune build
File "_none_", line 1:
Warning 58: no cmx file was found in path for module Toploop, and its interface was not compiled with -opaque
File "src/big.ml", line 49, characters 49-64:
Error: This expression has type image but an expression was expected of type
         Uchar.t array -> 'a
File "src/display.ml", line 28, characters 34-45:
Error: The function applied to this argument has type ?attr:attr -> image
This argument cannot be applied without label

I suspect now I'm too far ahead in versions with Notty.

@alexozer
Copy link
Owner

Try building again with 666c548.

@l0go
Copy link

l0go commented Nov 18, 2020

Hi, I am able to build, but I also have no response to global hotkeys.

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

3 participants