OCaml Weekly News

Previous Week Up Next Week

Hello

Here is the latest OCaml Weekly News, for the week of October 27 to November 03, 2026.

Table of Contents

k7 0.9.0: record and replay CLI outputs

Thomas Gazagnaire announced

I'm happy to announce the release of k7 0.9.0 a small tool to record and replay CLI animations.

It's available on MacOS and Linux with brew:

brew install samoht/tap/k7

or in opam:

opam install k7

The main feature vs. other similar tools is that it can use cram tests as input or output, so you can 1/ convert any cram test into an svg file; and 2/ ensure the svg that you use in your README files stays up-to-date with your code.

Apart from this it's in pure OCaml with no browser or ffmpeg involved; it plays .cast and .tape files (from asciinema and vhs) and write .cast files, but probably has fewer options than those tools, so feel free to open an issue if you find anything missing or not working.

See more details in my post: https://gazagnaire.org/blog/2026-10-26-k7.html

dune tracing

Raphaël Proust announced

Over the summer, @NatKarmios worked on dune for his internship at [Ahrefs](ahrefs.com). He got a couple of PRs merged into dune. Then he wrote a new backend for traces and a matching perfetto extension.

All of the details in his blog post: Tracing Dune, with a side of graphs

TL;DR: you get a graph view of the build, some SQL querying capabilities, it scales to handle Ahrefs' monorepo

We're using the new tracing capability internally. And we're planning on upstreaming it too.

console: making OCaml CLI tools look good!

Thomas Gazagnaire announced

I'm happy to announce the release of console 0.9.0, a set of widgets for building nice-looking command-line tools. The main design constraint I tried to follow is that the output should look good both for a human at an interactive terminal and for scripts run in CI or other non-interactive loops (like LLM agents). Live rows are redrawn in place and everything useful the program printed is still there when it ends; piped output tries to be relatively clean.

21b202a69ab6ff219fa5fee2416d438bbae78d14.gif

You can use it with:

opam install console console-eio

The widgets in console are pure; console-eio is the driver that runs animations. There are a few limitation (including limited Windows support) but you can already use it to encode quite complex UX. For instance, here a few imitations of package manager frontends using console (recorded using k7):

b18c267eea031cfb770f92fab15f9355882c96d4.gif

ed712dd72eba5421dc825b884e0dbb739b2befdc.gif

d7a8c56d42c8430f282e7afa9426bb315b52965f.gif

7ecc3d918f9968f61a15ef66e563487cd70335ee.gif

You can read more (including how it compares with notty, progress and printbox, here): https://gazagnaire.org/blog/2026-11-02-console.html.

Feedback is very welcome before 1.0, on the issue tracker or here.

imguiml 1.93.0

Frédéric Bour announced

I'm happy to announce a new release of imguiml, the OCaml bindings to Dear ImGui.

I am taking over maintenance of the project from its original author, Emilien Lemaire.

What's new:

  • Updated to Dear ImGui 1.93.0, with docking support.
  • The bindings now work on arm64 (and probably s390).
  • Fonts are now rendered with the system FreeType instead of stb_truetype, providing higher-quality rendering and better compatibility with modern font formats.
  • ImGui is now built with support for 32-bit characters, so Emojis are supported.

Disclaimer: "Claude" was used in this port, notably to rebase onto the latest version of ImGui and to fix the build on arm64.

Introcaml 5.5.2

Frédéric Bour announced

We're happy to announce a new alpha release of Introcaml, an extension of OCaml that brings polymorphic printing. It allows printing and inspecting values of any type, without writing printer functions. See the first announcement for an introduction.

Introcaml is developed at Shogan.ai.

This release ports Introcaml to OCaml 5.5.2. To try it:

opam switch create 5.5.2+introcaml

What's new

  • JSON printer

    A generic JSON printer is available in Introspect.Json.*, intended for debugging (and piping through jq :sweat_smile:):

    # Introspect.Json.to_channel stdout [
        `Point {x = 5; y = 0};
        `String "foo";
        `List [Result.Ok true; Result.Error false]
      ];;
    [{"Point":{"x":5,"y":0}},{"String":"foo"},{"List":[{"Ok":true},{"Error":false}]}]
    - : unit = ()
    # 
    
  • Debugging flags
    • -dblock-desc shows descriptors in -dlambda and similar output.
    • -verbose reports descriptor collisions at link time.

Compatibility

Object files and executables (exec, cmo, cma, cmx, cmxa, cmxs) now use Introcaml-specific magic numbers (Caml1999?901). cmi, cmt and ast files keep the upstream format.

  • js_of_ocaml support

    Although this was done in the js_of_ocaml repository, I think it is relevant to point the work we did @hhugo to bring full compatibility with Introcaml. js_of_ocaml can now be installed in Introcaml switches and javascript builds can now be instrumented. This brings polymorphic printing to OCaml programs compiled with js_of_ocaml, at no observable runtime cost (in our experiments).

    There is also opt-in integration with the browser's JavaScript console (console.log) and debugger, though this appears to be Chrome-only as far as I can tell. See how to enable it.

Bug fixes

  • Descriptor collisions: descriptors are hashed better, reducing collisions. When they still collide, values are printed raw instead of with the wrong names.
  • Descriptor representation: the representation is simpler and more portable.
  • Missing descriptors: I fixed a few cases where descriptors were omitted or lost during compilation (large native allocations, #load in the toplevel).
  • Float arrays and records: this fixes bugs reported by @vouillon (#5, #6, #7), paving the way toward compatibility with wasm_of_ocaml.
  • Printing: ~steps now bounds long lists and arrays, and printing is domain-safe.

Introcaml also received the "Claude treatment" to catch bugs I missed :clown_face:.

ocaml-ssl 0.8.1

Romain Beauxis announced

Hi all!

ocaml-ssl version 0.8.1 was just released and added to the opam registry.

Version 0.8.0 was released a few weeks back with a bunch of bugfixes and cleanups and 0.8.1 now also adds support for SSL v4.

All projects using ocaml-ssl should now consider updating to this latest version.

As usual, feel free to suggest patches and etc. Also, the package could definitely use more workforce is you're interested in stepping in.

Thanks,

­- Romain

Old CWN

If you happen to miss a CWN, you can send me a message and I'll mail it to you, or go take a look at the archive or the RSS feed of the archives.

If you also wish to receive it every week by mail, you may subscribe to the caml-list.