Skip to content

[new release] fsevents (2 packages) (0.4.0) - #30479

Open
dinosaure wants to merge 1 commit into
ocaml:masterfrom
dinosaure:release-fsevents-0.4.0
Open

[new release] fsevents (2 packages) (0.4.0)#30479
dinosaure wants to merge 1 commit into
ocaml:masterfrom
dinosaure:release-fsevents-0.4.0

Conversation

@dinosaure

Copy link
Copy Markdown
Contributor

OCaml bindings to macOS FSEvents

CHANGES:

CHANGES:

- Remove `base-bytes` dependency (@Leonidas-from-XIV, mirage/ocaml-fsevents#1)
- Update GitHUb actions scripts (@samoht, mirage/ocaml-fsevents#4)
- Update to `cmdliner.1.1.0` (@samoht, mirage/ocaml-fsevents#5)
- Apply `ocamlformat.0.27.0` (@MisterDA, @samoht, mirage/ocaml-fsevents#3)
@dinosaure

Copy link
Copy Markdown
Contributor Author

A side note to @panglesd if we look about errors:

# --- a/_build/default/test/compiler/dimension.t/run.t
# +++ b/_build/default/test/compiler/dimension.t/run.t.corrected
# @@ -5,20 +5,17 @@ Let's start with an empty file
#  We can provide the dimension with --dimension
#  
#    $ slipshow compile --dimension qfdesfesf file.md
# +  Usage: slipshow compile [--help] [OPTION]… [FILE.md]
#    slipshow: option '--dimension': Expected "4:3", "16:9", or two integers
#              separated by a 'x'
# -  Usage: slipshow compile [OPTION]… [FILE.md]
# -  Try 'slipshow compile --help' or 'slipshow --help' for more information.
#    [124]
#    $ slipshow compile --dimension wrongxefzefezf file.md
# +  Usage: slipshow compile [--help] [OPTION]… [FILE.md]
#    slipshow: option '--dimension': invalid value 'wrong', expected an integer
# -  Usage: slipshow compile [OPTION]… [FILE.md]
# -  Try 'slipshow compile --help' or 'slipshow --help' for more information.
#    [124]
#    $ slipshow compile --dimension 1920xwrong file.md
# +  Usage: slipshow compile [--help] [OPTION]… [FILE.md]
#    slipshow: option '--dimension': invalid value 'wrong', expected an integer
# -  Usage: slipshow compile [OPTION]… [FILE.md]
# -  Try 'slipshow compile --help' or 'slipshow --help' for more information.
#    [124]
#    $ slipshow compile --dimension 16:9 file.md
#    $ slipshow compile --dimension 4:3 file.md

You should note run tests when cmdliner's outputs are involved according to this comment.

@panglesd

Copy link
Copy Markdown
Contributor

Thanks for the release, and for the pointer! I'll do something about those tests before my next release.

@panglesd

panglesd commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Oh no I forgot to do it before #30652 ... 😞

Is it the reason you added the do not merge tag? I can push a 0.13.1 if it's the case.

@dinosaure

Copy link
Copy Markdown
Contributor Author

Is it the reason you added the do not merge tag? I can push a 0.13.1 if it's the case.

Actually, I think I need some helps. I currently don't have an access to a MacOS and it seems that the package does not compile anymore on such platform. If you are the time to fix and propose a PR, I can take the relay and release it 👍. Otherwise, I will try to figure out how to fix the compilation.

@mseri

mseri commented Sep 7, 2026

Copy link
Copy Markdown
Member

I tried it out on my mac. Tests are failing because the first event is ItemType(Dir) ItemCreated ItemXattrMod.

If I add

let drop_xattr_mod stream =
    Lwt_stream.filter_map
      (fun event ->
        let flags = { event.flags with item_xattr_mod = false } in
        if flags = zero then None else Some { event with flags })
      stream

and replace

- let stream = Fsevents_lwt.stream watcher in
+ let stream = drop_xattr_mod (Fsevents_lwt.stream watcher) in

in lib_test/test.ml, then tests are passing. I hope it helps

@mseri

mseri commented Sep 7, 2026

Copy link
Copy Markdown
Member

I don't see

# File "examples/dune", line 5, characters 19-31:
# 5 |  (libraries cf-lwt fsevents-lwt))
#                        ^^^^^^^^^^^^
# Error: Library "fsevents-lwt" not found.

locally, which seems to be the main failure in the CI.

@panglesd

panglesd commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

My investigation would be that the test in example/ is not associated with a package, and thus runs when the CI runs dune build @runtest -p fsevents. However, at this stage fsevents-lwt is not available (why is it available in your case? I don't know, maybe it's because of the -p fsevents, or maybe the CI is doing something special).

I think a fix would be to associate the test with the fsevents-lwt package:

; example/dune

(executable
 (name print_events)
 (enabled_if
  (= %{system} macosx))
 (libraries cf-lwt fsevents-lwt))

(alias
 (name runtest)
 (enabled_if
  (= %{system} macosx))
+ (package fsevents-lwt)
 (deps print_events.exe))

Anyway, @mseri issue should probably be fixed too. I don't have a Mac either, I use github's CI which is a very bad UX but better (maybe?) than buying a mac just for that, and unlimited for OSS.

@MisterDA

MisterDA commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

See also mirage/ocaml-fsevents#11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants