<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.10.0">Jekyll</generator><link href="https://metaredux.com/feed.xml" rel="self" type="application/atom+xml" /><link href="https://metaredux.com/" rel="alternate" type="text/html" /><updated>2026-11-28T18:48:03+00:00</updated><id>https://metaredux.com/feed.xml</id><title type="html">Meta Redux</title><subtitle>Writings on programming and open-source by Bozhidar Batsov, creator of RuboCop, CIDER, and Prelude.</subtitle><author><name>Bozhidar Batsov</name></author><entry><title type="html">neorepl 0.6: Errors Made Easy (to Fix)</title><link href="https://metaredux.com/posts/2026/11/28/neorepl-0-6.html" rel="alternate" type="text/html" title="neorepl 0.6: Errors Made Easy (to Fix)" /><published>2026-11-28T16:21:00+00:00</published><updated>2026-11-28T16:21:00+00:00</updated><id>https://metaredux.com/posts/2026/11/28/neorepl-0-6</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/28/neorepl-0-6.html"><![CDATA[<p><a href="https://github.com/nrepl/neorepl/releases/tag/v0.6.0">neorepl 0.6</a> is out!
In the <a href="/posts/2026/11/05/neorepl-0-5.html">0.5 post</a> I wrote that 0.6
would be about getting neorepl to more people, with Clojars, Homebrew,
Windows and a documentation site. Then I started looking at what the REPL
does when your code blows up, and, well, you can guess how that went. The
site happened, and neorepl installs as a Clojure CLI tool now, but most of
this release is about errors: what they mean, how to fix them, and a
debugger for the ones that don’t give up easily. Hence the tagline, “Errors
made easy (to fix)”.</p>

<!--more-->

<h2 id="from-error-to-fix">From error to fix</h2>

<p><img src="/assets/images/neorepl-hints.gif" alt="Fixing errors in neorepl" /></p>

<p>Every Clojure programmer has stared at “Unable to resolve symbol” more
times than they’d care to admit, and nine times out of ten the fix is a
missing require or a typo. The REPL knows that much, so now it tells you.
When code names something that isn’t there, neorepl marks the name in what
you typed and lists what could fix it, numbered for <code class="language-plaintext highlighter-rouge">,fix</code>:</p>

<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>user=&gt; (join ", " ["a" "b"])
Syntax error compiling at (REPL:1:1).
Unable to resolve symbol: join in this context
  (join ", " ["a" "b"])
   ^^^^
  ,fix 1  (require '[clojure.set :refer [join]])
  ,fix 2  (require '[clojure.string :refer [join]])
user=&gt; ,fix 2
nil
"a, b"
</code></pre></div></div>

<p>The requires and imports come from cider-nrepl’s <code class="language-plaintext highlighter-rouge">resolve-missing</code> (or
babashka 1.13.230’s), and the fixes for typos come from completion. A fix
only ever runs when you ask for it. I stole the idea from Smalltalk’s
debugger, which offers to create the method you just called, and from
Factor and MIT Scheme, which number their restarts, but I drew the line at
fixing things behind your back.</p>

<p>The rest of the errors got some love too:</p>

<ul>
  <li>An <code class="language-plaintext highlighter-rouge">ex-info</code>’s data shows up as fields under its message, rather than as
one long map you have to squint at.</li>
  <li>A function called with the wrong number of arguments gets its arglists.</li>
  <li>The commonest errors get a line on what they tend to mean. A
<code class="language-plaintext highlighter-rouge">NullPointerException</code> from <code class="language-plaintext highlighter-rouge">clojure.lang.Numbers</code> is arithmetic getting
<code class="language-plaintext highlighter-rouge">nil</code>, for instance.</li>
  <li>You get the line of your own code the error came from, rather than the
first of fifty frames of <code class="language-plaintext highlighter-rouge">clojure.lang</code>.</li>
  <li>The first few errors point out <code class="language-plaintext highlighter-rouge">,pst</code> and <code class="language-plaintext highlighter-rouge">,stacktrace</code>, and the <code class="language-plaintext highlighter-rouge">hints</code>
setting turns all of this off, if you’d rather figure things out the hard
way.</li>
</ul>

<p>Coding agents make even more typos than I do, so <code class="language-plaintext highlighter-rouge">neorepl eval</code> and the MCP
<code class="language-plaintext highlighter-rouge">eval</code> tool follow such an error with the same fixes. With <code class="language-plaintext highlighter-rouge">--format edn</code> or
<code class="language-plaintext highlighter-rouge">json</code> (and in the tool’s structured content) they come as <code class="language-plaintext highlighter-rouge">suggestions</code>,
each with the code to evaluate for it.</p>

<h2 id="a-debugger-at-last">A debugger, at last</h2>

<p><img src="/assets/images/neorepl-debugger.gif" alt="Stepping through a function in neorepl" /></p>

<p>CIDER’s debugger has been one of my favourite CIDER features ever since
Artur Malabarba wrote it, back in 2015, and it’s the first thing I missed
in neorepl. Not anymore! <code class="language-plaintext highlighter-rouge">,break</code> instruments a function with cider-nrepl’s
debugger, so it stops at each step, and at each breakpoint you get CIDER’s keys:
<code class="language-plaintext highlighter-rouge">n</code> for the next step, <code class="language-plaintext highlighter-rouge">i</code> and <code class="language-plaintext highlighter-rouge">o</code> to step in and out, <code class="language-plaintext highlighter-rouge">c</code> to go on, <code class="language-plaintext highlighter-rouge">l</code>
for the locals, <code class="language-plaintext highlighter-rouge">e</code> to evaluate something with them, <code class="language-plaintext highlighter-rouge">j</code> to return a value
of your choosing, <code class="language-plaintext highlighter-rouge">p</code> to inspect, <code class="language-plaintext highlighter-rouge">q</code> to quit and <code class="language-plaintext highlighter-rouge">?</code> for everything else.</p>

<p>A few more ways in:</p>

<ul>
  <li><code class="language-plaintext highlighter-rouge">,break-at FILE LINE</code> stops at a line of a file, which also works for a
method, a function inside a <code class="language-plaintext highlighter-rouge">def</code> or a line in the middle of a long
function. <code class="language-plaintext highlighter-rouge">,breaks</code> lists what stops, and <code class="language-plaintext highlighter-rouge">,unbreak</code> and <code class="language-plaintext highlighter-rouge">,unbreak-at</code>
take it out.</li>
  <li><code class="language-plaintext highlighter-rouge">#dbg</code> and <code class="language-plaintext highlighter-rouge">#break</code> typed in front of a form work as they do in CIDER.</li>
  <li>After an error, <code class="language-plaintext highlighter-rouge">,debug</code> runs the input that failed again and stops right
where it throws, with the locals, so you can poke around or <code class="language-plaintext highlighter-rouge">j</code> your way
past it.</li>
  <li>A breakpoint on a thread of its own, like an HTTP handler’s, waits with a
note above the prompt until you get to it with <code class="language-plaintext highlighter-rouge">,stop</code>.</li>
  <li>When the REPL exits, everything it instrumented runs as normal again, so
you don’t leave breakpoints behind that no one will ever answer.</li>
</ul>

<p>All of this works with babashka 1.13.230 as well.</p>

<h2 id="bring-your-own-editor">Bring your own editor</h2>

<p>I doubt many of you write non-trivial amounts of code straight into a REPL,
so here’s what all of this looks like next to an editor:</p>

<p><img src="/assets/images/neorepl-editor.gif" alt="Neovim and neorepl, side by side" /></p>

<p>That’s Neovim, with neorepl in a <code class="language-plaintext highlighter-rouge">:terminal</code> split under the code, and the
setup from <a href="https://github.com/nrepl/neorepl/blob/main/doc/editors.md">doc/editors.md</a>,
which is a few dozen lines of Lua and no plugin. The editor and the REPL
share a server, so whatever one of them evaluates, the other sees. The
receipt in the REPL looks suspiciously round, so <code class="language-plaintext highlighter-rouge">,break format-cents</code> and
a few steps show <code class="language-plaintext highlighter-rouge">(rem cents 10)</code> coming back with 0. The fix in the buffer
is one character, <code class="language-plaintext highlighter-rouge">,ee</code> evaluates the function at the cursor (without even
saving the file), and back in the REPL the receipt finally adds up.</p>

<p>The way I’d split the work between them:</p>

<ul>
  <li>The editor evaluates things and loads files, the REPL runs them, and when
something’s off, the REPL is where you poke at it, with the inspector,
the tests, the stack traces and now the debugger.</li>
  <li><code class="language-plaintext highlighter-rouge">,break-at FILE LINE</code> is handy here, as you can put the line your cursor’s
on in the editor straight into it.</li>
  <li>Going the other way, <code class="language-plaintext highlighter-rouge">,edit NAME</code> in the REPL opens a definition in your
<code class="language-plaintext highlighter-rouge">$EDITOR</code>.</li>
</ul>

<p>The doc has this split too, and the same setup for Emacs, where C-M-x and
C-c C-r evaluate the form at point and the region from clojure-mode, no
CIDER required, and for Helix. Any terminal next to the editor will do for
the REPL, if you’d rather keep it out of the editor.</p>

<h2 id="so-does-it-feel-like-cider-yet">So, does it feel like CIDER yet?</h2>

<p>When I <a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">announced neorepl</a>,
a lot of people didn’t understand why we needed one more terminal REPL for
nREPL. Back then I said my vision was an alternative to REPLy with a
CIDER-like experience in your terminal (and a good CLI for agents to lean
on, if you’re into AI engineering these days). The first version of neorepl
didn’t feel much like CIDER, but I hope you’ll agree that things are looking
way better in this regard now. Here’s where neorepl stands on CIDER’s major
features, and what each of them needs on the server:</p>

<table>
  <thead>
    <tr>
      <th> </th>
      <th>With cider-nrepl</th>
      <th>nREPL alone</th>
      <th>In ClojureScript</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Completion, arglists as you type</td>
      <td>yes</td>
      <td>yes, with nREPL 0.8 or later</td>
      <td>yes</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,doc</code>, <code class="language-plaintext highlighter-rouge">,source</code>, <code class="language-plaintext highlighter-rouge">,where</code></td>
      <td>yes</td>
      <td>yes</td>
      <td>yes</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,apropos</code></td>
      <td>yes</td>
      <td>yes</td>
      <td>Clojure’s vars only</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,macroexpand</code></td>
      <td>yes</td>
      <td>yes</td>
      <td>yes</td>
    </tr>
    <tr>
      <td>Errors, <code class="language-plaintext highlighter-rouge">,pst</code>, <code class="language-plaintext highlighter-rouge">,stacktrace</code></td>
      <td>yes</td>
      <td>yes</td>
      <td>the message, without JavaScript frames</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,fix</code> and what an error says past its message</td>
      <td>yes, requires and imports with 0.64 or later</td>
      <td>typos only</td>
      <td>no, ClojureScript only warns</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,inspect</code></td>
      <td>yes</td>
      <td>no</td>
      <td>the value, read back as data</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,test</code></td>
      <td>yes</td>
      <td>the namespaces you name</td>
      <td>yes</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,retest</code></td>
      <td>yes</td>
      <td>no</td>
      <td>yes</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,reload</code></td>
      <td>yes, and what changed</td>
      <td>the namespaces you name</td>
      <td>Clojure’s only</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,autoreload</code></td>
      <td>yes</td>
      <td>no</td>
      <td>no</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,break</code>, <code class="language-plaintext highlighter-rouge">,break-at</code>, <code class="language-plaintext highlighter-rouge">,debug</code></td>
      <td>yes</td>
      <td>no</td>
      <td>no</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,trace</code>, <code class="language-plaintext highlighter-rouge">,profile</code></td>
      <td>yes</td>
      <td>no</td>
      <td>no</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,refs</code>, <code class="language-plaintext highlighter-rouge">,deps</code></td>
      <td>yes</td>
      <td>no</td>
      <td>no</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,ns</code> and its browser</td>
      <td>yes</td>
      <td>yes</td>
      <td>yes</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,spec</code></td>
      <td>yes</td>
      <td>yes</td>
      <td>Clojure’s specs only</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">,tap</code></td>
      <td>yes, 0.64 or later</td>
      <td>no</td>
      <td>no</td>
    </tr>
  </tbody>
</table>

<p>Like CIDER, neorepl gets the most out of cider-nrepl, which jack-in adds for
you, and the ClojureScript column assumes it’s there, through piggieback or
shadow-cljs. babashka’s server, 1.13.230 or later, does everything in the
first column but <code class="language-plaintext highlighter-rouge">,refs</code>, <code class="language-plaintext highlighter-rouge">,deps</code>, reloading what changed and <code class="language-plaintext highlighter-rouge">,tap</code>. The
<a href="https://github.com/nrepl/neorepl#what-works-where">README</a> has the same
table.</p>

<h2 id="making-the-neighbours-better-round-four">Making the neighbours better, round four</h2>

<ul>
  <li>babashka’s CIDER ops now come from cider-nrepl’s own middleware, which
gave bb 1.13.230 the debugger, <code class="language-plaintext highlighter-rouge">resolve-missing</code>, <code class="language-plaintext highlighter-rouge">apropos</code>,
<code class="language-plaintext highlighter-rouge">macroexpand</code>, the profiler and quite a bit more. I did that one myself,
so it’s my fault if something’s off there.</li>
  <li>neorepl’s jack-in brings cider-nrepl 0.64.1, which fixed a couple of
problems with reloading that neorepl used to work around.</li>
  <li>I filed a couple of cider-nrepl issues the debugger and the tests turned
up: a breakpoint <a href="https://github.com/clojure-emacs/cider-nrepl/issues/1085">waits forever</a>
once the client that started the debugger is gone, and tests compiled
before the first test op <a href="https://github.com/clojure-emacs/cider-nrepl/issues/1079">report forms instead of values</a>.</li>
  <li>The nREPL fixes are still waiting for the next nREPL release, and the
piggieback changes are still in review.</li>
</ul>

<h2 id="smaller-things">Smaller things</h2>

<ul>
  <li>neorepl installs as a Clojure CLI tool, straight from git, with
<code class="language-plaintext highlighter-rouge">clojure -Ttools install-latest :lib io.github.nrepl/neorepl :as neorepl</code>,
and every command is a function of the tool, as in <code class="language-plaintext highlighter-rouge">clojure -Tneorepl repl</code>.</li>
  <li><code class="language-plaintext highlighter-rouge">,apropos</code>, <code class="language-plaintext highlighter-rouge">neorepl apropos</code> and the namespace browser leave out the
namespaces of nREPL, cider-nrepl and its libraries, which were mostly
noise. <code class="language-plaintext highlighter-rouge">--tooling</code> and the <code class="language-plaintext highlighter-rouge">tooling</code> setting bring them back.</li>
  <li><code class="language-plaintext highlighter-rouge">,apropos</code> fits what it lists to your terminal, and so does the profile
summary.</li>
  <li>Locations in <code class="language-plaintext highlighter-rouge">where</code>, <code class="language-plaintext highlighter-rouge">refs</code>, <code class="language-plaintext highlighter-rouge">deps</code> and <code class="language-plaintext highlighter-rouge">check</code> are relative to the
directory you’re in, when they’re in it.</li>
  <li>Ctrl-C stops code that refuses to stop on JDK 20 and later, in the
servers <code class="language-plaintext highlighter-rouge">neorepl server</code> starts.</li>
  <li>Each form you paste or evaluate with <code class="language-plaintext highlighter-rouge">eval -f</code> gets its own line and
column, so errors in the second form no longer point somewhere above it.</li>
</ul>

<p>neorepl also has <a href="https://nrepl.github.io/neorepl/">a site</a> now, where you
can see all of the above in action, if you’d rather not take my word for it.</p>

<h2 id="whats-next">What’s next</h2>

<p>Clojars, an uberjar and Homebrew are still at the top of my list, along
with proper Windows support and the frames of ClojureScript errors (which
have been “next” since 0.2, I know). After that comes 1.0, where the CLI’s
exit codes, its edn and JSON output and the MCP tools become a contract I
promise to keep.</p>

<h2 id="try-it">Try it</h2>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>bbin <span class="nb">install </span>io.github.nrepl/neorepl
<span class="nv">$ </span><span class="nb">cd </span>my-project
<span class="nv">$ </span>neorepl
</code></pre></div></div>

<p>The <a href="https://github.com/nrepl/neorepl/blob/main/CHANGELOG.md">CHANGELOG</a> has
everything I skipped here, and the <a href="https://github.com/nrepl/neorepl">README</a>
has the details. Please keep the issues and ideas coming!</p>

<p>That’s all I have for you today. With 0.6 out, I feel we’re pretty close to
a “feature-complete” 1.0, and I hope we’ll get there in the months to come.
Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="neorepl" /><summary type="html"><![CDATA[neorepl 0.6 is out! In the 0.5 post I wrote that 0.6 would be about getting neorepl to more people, with Clojars, Homebrew, Windows and a documentation site. Then I started looking at what the REPL does when your code blows up, and, well, you can guess how that went. The site happened, and neorepl installs as a Clojure CLI tool now, but most of this release is about errors: what they mean, how to fix them, and a debugger for the ones that don’t give up easily. Hence the tagline, “Errors made easy (to fix)”.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">The Ruby and Clojure Style Guides Get a Facelift</title><link href="https://metaredux.com/posts/2026/11/28/the-ruby-and-clojure-style-guides-get-a-facelift.html" rel="alternate" type="text/html" title="The Ruby and Clojure Style Guides Get a Facelift" /><published>2026-11-28T12:50:00+00:00</published><updated>2026-11-28T12:50:00+00:00</updated><id>https://metaredux.com/posts/2026/11/28/the-ruby-and-clojure-style-guides-get-a-facelift</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/28/the-ruby-and-clojure-style-guides-get-a-facelift.html"><![CDATA[<p>The community style guides for <a href="https://rubystyle.guide">Ruby</a> and
<a href="https://guide.clojure.style">Clojure</a> (and their siblings for
<a href="https://rails.rubystyle.guide">Rails</a>, <a href="https://rspec.rubystyle.guide">RSpec</a> and
<a href="https://minitest.rubystyle.guide">Minitest</a>) got a brand new look this week.
That was long overdue and, as it turned out, way easier to do than I had
expected.</p>

<!--more-->

<h2 id="a-bit-of-history">A Bit of History</h2>

<p>Back in 2019 I spent a lot of time <a href="/posts/2019/07/07/meta-reduce-2019-3-style-guide-docs-updates.html">converting the guides from Markdown to AsciiDoc</a>
and publishing them as websites for the first time. It’s no secret that I’m a big fan
of AsciiDoc and I think it’s the best format for writing technical documentation.
I’ve written about it <a href="/posts/2023/03/12/adoc-mode-reborn.html">here</a>,
<a href="https://batsov.com/articles/2024/02/22/asciidoc-language-specification/">there</a> and
<a href="https://batsov.com/articles/2026/06/11/emacs-loves-asciidoc/">everywhere</a>, and
the documentation of most of my bigger OSS projects is written in AsciiDoc.</p>

<p>Admittedly, I didn’t think much about the websites back then. Each guide is just a single
<code class="language-plaintext highlighter-rouge">README.adoc</code>, so I went with the simplest approach I could find:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code>asciidoctor <span class="nt">-a</span> <span class="nv">toc</span><span class="o">=</span><span class="s2">"left"</span> <span class="nt">-a</span> <span class="nv">toclevels</span><span class="o">=</span>2 README.adoc <span class="nt">-o</span> _build/html/index.html
</code></pre></div></div>

<p>Yeah, that’s the entire “site generator”. A CI job would run this command on
every push and publish the resulting <code class="language-plaintext highlighter-rouge">index.html</code> to GitHub Pages. At the time
I wrote that <a href="/posts/2019/04/26/rspec-style-guide-reloaded.html">it’s much better to have great content than beautiful visuals</a>
(although having them both would be ideal for sure) and I was certain that I’d
replace this setup with something fancier down the road. Fast-forward 7 years
and it was still there.<sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup> Time sure flies fast!</p>

<h2 id="the-problem">The Problem</h2>

<p>Here’s what the guides looked like until a few days ago:</p>

<p><img src="/assets/images/style-guides-before.png" alt="The Clojure Style Guide with Asciidoctor's default stylesheet" /></p>

<p>That’s Asciidoctor’s default stylesheet. It was fine in 2019, but it hasn’t aged
that well, and over the years I’ve heard a few complaints about it:</p>

<ul>
  <li>On a phone the entire table of contents is displayed at the top of the page.
The Ruby guide has over 300 entries there, so you had to scroll for quite a
while before you’d get to the actual content.</li>
  <li>There’s no dark mode.</li>
  <li>The tables <a href="https://github.com/bbatsov/clojure-style-guide/issues/277">look like something from mid-1990s web pages</a>.
That’s a pretty accurate description, if you ask me.</li>
  <li>The fonts are fetched from Google Fonts, which is a bit weird for a page
that’s otherwise a single self-contained HTML file.</li>
</ul>

<p>Thanks to <a href="https://github.com/kwj">Jun Kawai</a> for bringing up the tables
recently! That was the nudge I needed to finally do something about the looks
of the guides.</p>

<p>From time to time I’ve considered moving the guides to
<a href="https://antora.org">Antora</a> (which I’m using for the documentation of CIDER,
nREPL and RuboCop) or some other static site generator, but that always seemed
like an overkill to me. After all, each guide is a single document, right?</p>

<h2 id="the-fix">The Fix</h2>

<p>In the end I didn’t need a different tool at all - I only needed a different
stylesheet. Asciidoctor allows you to replace its default stylesheet with your
own and to inject some HTML of yours into the page (that’s what the <code class="language-plaintext highlighter-rouge">docinfo</code>
attributes are for). Basically, the command above became:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code>asciidoctor <span class="nt">-a</span> <span class="nv">toc</span><span class="o">=</span>left <span class="nt">-a</span> <span class="nv">toclevels</span><span class="o">=</span>2 <span class="se">\</span>
  <span class="nt">-a</span> <span class="nv">stylesdir</span><span class="o">=</span>theme <span class="nt">-a</span> <span class="nv">stylesheet</span><span class="o">=</span>guide.css <span class="se">\</span>
  <span class="nt">-a</span> <span class="nv">docinfo</span><span class="o">=</span>shared <span class="nt">-a</span> <span class="nv">docinfodir</span><span class="o">=</span>theme <span class="se">\</span>
  <span class="nt">-a</span> guide-accent<span class="o">=</span><span class="s1">'#cc342d'</span> <span class="se">\</span>
  README.adoc <span class="nt">-o</span> _build/html/index.html
</code></pre></div></div>

<p>The output is still a single self-contained HTML file and I didn’t have to
touch the AsciiDoc source of the guides at all. I was pretty glad that getting
where I wanted to go was just a matter of using a different stylesheet. Here’s
how the guides look today:</p>

<p><img src="/assets/images/style-guides-clojure.png" alt="The Clojure Style Guide today" /></p>

<p><img src="/assets/images/style-guides-ruby.png" alt="The Ruby Style Guide today" /></p>

<p>There’s a dark mode that follows your system settings (you can also switch
between the modes manually):</p>

<p><img src="/assets/images/style-guides-clojure-dark.png" alt="The Clojure Style Guide in dark mode" /></p>

<p>And on small screens the table of contents is no longer in your way:</p>

<p><img src="/assets/images/style-guides-mobile.png" alt="The Clojure Style Guide on a phone" /></p>

<p>The sidebar also highlights the section that you’re currently reading, which is
pretty handy for documents that long.</p>

<h2 id="the-look">The Look</h2>

<p>I’m no designer (as you can probably tell), so I didn’t try to come up with
something original. I assume that most people reading the guides spend a lot of
time on GitHub, so I aimed for something aligned with GitHub’s UI - the greys,
the borders, the admonitions and the syntax highlighting are all pretty close
to what you’d see there in light and dark mode. The theme relies on your system
fonts, so nothing gets downloaded anymore.</p>

<p>The only difference between the guides is the accent colour. Each
guide specifies a single colour (Clojure’s blue and Ruby’s red) and everything
else is derived from it in CSS:</p>

<div class="language-css highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">--accent</span><span class="o">:</span> <span class="nt">light-dark</span><span class="o">(</span><span class="nt">var</span><span class="o">(</span><span class="nt">--brand</span><span class="o">),</span> <span class="nt">color-mix</span><span class="o">(</span><span class="nt">in</span> <span class="nt">oklch</span><span class="o">,</span> <span class="nt">var</span><span class="o">(</span><span class="nt">--brand</span><span class="o">),</span> <span class="nt">white</span> <span class="err">30</span><span class="o">%));</span>
<span class="nt">--link</span><span class="o">:</span> <span class="nt">light-dark</span><span class="o">(</span><span class="nt">color-mix</span><span class="o">(</span><span class="nt">in</span> <span class="nt">oklch</span><span class="o">,</span> <span class="nt">var</span><span class="o">(</span><span class="nt">--brand</span><span class="o">),</span> <span class="nt">black</span> <span class="err">25</span><span class="o">%),</span>
                   <span class="nt">color-mix</span><span class="o">(</span><span class="nt">in</span> <span class="nt">oklch</span><span class="o">,</span> <span class="nt">var</span><span class="o">(</span><span class="nt">--brand</span><span class="o">),</span> <span class="nt">white</span> <span class="err">50</span><span class="o">%));</span>
</code></pre></div></div>

<p>In other words - the links are a darker shade of the accent on a light
background and a lighter shade of it on a dark background, so they are easy to
read in both modes. Modern CSS is pretty awesome! Not so long ago you’d need a
preprocessor for something like this.<sup id="fnref:2" role="doc-noteref"><a href="#fn:2" class="footnote" rel="footnote">2</a></sup></p>

<h2 id="one-theme-to-rule-them-all">One Theme to Rule Them All</h2>

<p>All the guides share the same theme, which lives in a <a href="https://github.com/bbatsov/style-guide-theme">separate
repository</a>. It’s just a
stylesheet, a little bit of JavaScript (for the theme switcher and the mobile
menu) and a GitHub Action that wraps the command you saw earlier. Here’s all
that it takes to build a guide now:</p>

<div class="language-yaml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="pi">-</span> <span class="na">uses</span><span class="pi">:</span> <span class="s">actions/checkout@v7</span>
<span class="pi">-</span> <span class="na">uses</span><span class="pi">:</span> <span class="s">bbatsov/style-guide-theme@v1</span>
  <span class="na">with</span><span class="pi">:</span>
    <span class="na">accent</span><span class="pi">:</span> <span class="s1">'</span><span class="s">#5881d8'</span>
</code></pre></div></div>

<p>While I was at it I also moved the Ruby guides from CircleCI to GitHub Actions,
so now all the guides are built and deployed in exactly the same way. There’s
nothing specific to style guides in the theme, so feel free to use it for your
own AsciiDoc documents if you like it.</p>

<h2 id="epilogue">Epilogue</h2>

<p>I’m sure that the new look has some rough edges. I haven’t tested it on that
many browsers and devices, and I guess that not everyone will like my choice of
colours. If you notice any problems - please, let me know! Issues and pull
requests are always welcome!</p>

<p>Looking back, I’m glad I went with something that simple in 2019. I never
expected it’d stay in place for so many years, but simple solutions are also
the easiest to improve when the time for this finally comes. Once again I was
reminded that “less is more”.</p>

<p>That’s all I have for you today. Keep hacking!</p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>There’s nothing more permanent than a temporary solution. <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:2" role="doc-endnote">
      <p>The downside is that the theme requires a browser released in 2024 or later. <a href="#fnref:2" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Ruby" /><category term="Clojure" /><category term="Style Guide" /><category term="AsciiDoc" /><summary type="html"><![CDATA[The community style guides for Ruby and Clojure (and their siblings for Rails, RSpec and Minitest) got a brand new look this week. That was long overdue and, as it turned out, way easier to do than I had expected.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">RuboCop 1.93: Prism, Without the Middleman</title><link href="https://metaredux.com/posts/2026/11/25/rubocop-1-93.html" rel="alternate" type="text/html" title="RuboCop 1.93: Prism, Without the Middleman" /><published>2026-11-25T16:00:00+00:00</published><updated>2026-11-25T16:00:00+00:00</updated><id>https://metaredux.com/posts/2026/11/25/rubocop-1-93</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/25/rubocop-1-93.html"><![CDATA[<p><a href="https://github.com/rubocop/rubocop/releases/tag/v1.93.0">RuboCop 1.93</a> is out! Almost three years ago I wrote about <a href="/posts/2024/02/19/need-for-speed-using-rubocop-with-prism.html">using RuboCop
with Prism</a> for the
first time, and I was VERY excited about it. Since then Prism quietly became the
default parser for modern Ruby code, but it always reached RuboCop through a
translation layer that made it look like the good old <code class="language-plaintext highlighter-rouge">parser</code> gem. With this
release (and RuboCop AST 1.54) the middleman is gone - RuboCop can now build its AST
straight from Prism.</p>

<p>That sounds like the kind of change that should come with fireworks and a 10x
speedup. It doesn’t, and I think the reasons why are more interesting than the change
itself.</p>

<!--more-->

<h2 id="why-not-just-drop-parser">Why not just drop Parser?</h2>

<p>That’s the first question everyone asks, usually followed by “and why don’t the cops
work on Prism’s own nodes?”. I wish it were that simple. Here’s what stands in
the way:</p>

<ul>
  <li>Prism can only parse Ruby 3.3 and newer. RuboCop can analyze code that targets
anything back to Ruby 2.0, and it doesn’t care much which Ruby it runs on. Plenty of
popular gems still support Rubies that were released long before Prism existed, and
they lint their code as that oldest version. When RuboCop can’t figure out your
target version it assumes 2.7. All of those need <code class="language-plaintext highlighter-rouge">parser</code>.</li>
  <li>Every cop is written against the AST of <code class="language-plaintext highlighter-rouge">parser</code> - the node types, their children,
their source maps. That’s about 600 cops in RuboCop itself, hundreds more in the
extensions, and who knows how many custom cops living in private codebases.
Prism’s own tree has a different shape, so moving the cops to it would break every
single one of them. I did that kind of migration once, from <code class="language-plaintext highlighter-rouge">ripper</code> to <code class="language-plaintext highlighter-rouge">parser</code>,
when RuboCop was tiny. Never again.</li>
  <li>Autocorrection doesn’t live in the parser at all. It lives in the source layer of
<code class="language-plaintext highlighter-rouge">parser</code> - ranges, buffers, comments and the tree rewriter that merges the edits of
different cops. Prism <a href="https://github.com/ruby/prism/issues/3466">won’t ship a rewriter</a>, so that code has to
live somewhere.</li>
  <li>The new engine needs Prism 2, and some very popular gems (Ruby LSP being the one
you most likely have in your bundle) still require Prism 1. Until they catch up,
Bundler will happily keep you on the old path.</li>
</ul>

<p>So Parser isn’t going anywhere just yet. But we don’t have to keep routing every
single parse through it either.</p>

<h2 id="what-we-did-instead">What we did instead</h2>

<p>RuboCop AST now has its own compiler that walks the Prism tree and creates the very
same nodes RuboCop has always worked with - same types, same node classes, same
source maps. It also converts Prism’s tokens, comments and diagnostics by itself. From
the point of view of a cop nothing has changed, and that’s the whole point.</p>

<p>If that sounds a lot like what the translation layer (<code class="language-plaintext highlighter-rouge">Prism::Translation::Parser</code>,
the artist formerly known as <code class="language-plaintext highlighter-rouge">parser-prism</code>) has been doing for years - it is. Both
walk the Prism tree and produce a <code class="language-plaintext highlighter-rouge">parser</code>-shaped AST, and we went out of our way to
produce exactly the same one. The difference is in what happens along the way, and in
who owns it:</p>

<ul>
  <li>The translation layer is a <code class="language-plaintext highlighter-rouge">Parser::Base</code> subclass that drives the builder of the
<code class="language-plaintext highlighter-rouge">parser</code> gem - the very same builder the old Racc grammar talks to. For every node it
repackages Prism’s locations as <code class="language-plaintext highlighter-rouge">parser</code>-style tokens, hands them to the builder and
lets it work out the node and its source map. It’s a brilliant way to make Prism a
drop-in replacement, but it means every parse still goes through <code class="language-plaintext highlighter-rouge">parser</code>’s
machinery, and you can only build what that builder knows how to build.</li>
  <li>Our compiler creates RuboCop’s nodes and their source maps directly from Prism’s
nodes and locations. No builder, no fake tokens, no <code class="language-plaintext highlighter-rouge">Parser::Base</code>. The only thing
left from <code class="language-plaintext highlighter-rouge">parser</code> is the handful of classes that describe source code (ranges,
buffers, source maps), and those we can carry ourselves.</li>
  <li>The translation layer has to serve everyone who ever used <code class="language-plaintext highlighter-rouge">parser</code>, bug for bug.
Ours only has to serve RuboCop, and it lives in a gem we control. When Ruby grows
new syntax we can add a node for it the same day, and we no longer have to poke at
the internals of someone else’s library to get things like lazily built tokens.</li>
</ul>

<p>So think of it less as a new idea and more as taking a great idea in-house, minus a
layer.</p>

<p>We also ship a copy of the source layer of <code class="language-plaintext highlighter-rouge">parser</code> (about 2,800 lines) that’s loaded
only when the <code class="language-plaintext highlighter-rouge">parser</code> gem isn’t installed. With it, linting Ruby 3.3+ code needs
nothing from <code class="language-plaintext highlighter-rouge">parser</code> at all.<sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup></p>

<p>The new engine is called <code class="language-plaintext highlighter-rouge">prism</code>, and it’s what <code class="language-plaintext highlighter-rouge">ParserEngine: default</code> picks when
your target Ruby is 3.3 or newer and Prism 2 is in your bundle. With an older Prism
you stay on <code class="language-plaintext highlighter-rouge">parser_prism</code> (the translation layer), and for older target Rubies on
<code class="language-plaintext highlighter-rouge">parser_whitequark</code>, exactly as before. <code class="language-plaintext highlighter-rouge">rubocop -V</code> tells you which one you got.</p>

<p>“The same nodes” is easy to say, so we checked it. The new engine and the translation
layer produce identical trees, tokens, comments and diagnostics on every Ruby file of
every gem I have installed - 17,580 files, 12.4 million nodes and 24.7 million tokens.
And RuboCop reports exactly the same offenses on its own codebase with <code class="language-plaintext highlighter-rouge">parser</code> made
impossible to load.</p>

<p>What do we get out of it?</p>

<ul>
  <li>New Ruby syntax no longer has to wait for someone to invent a <code class="language-plaintext highlighter-rouge">parser</code>-shaped node
for it upstream. That’s the part I care about most.</li>
  <li>One less layer of other people’s private API between us and the parser.</li>
  <li>A path to a RuboCop that doesn’t depend on <code class="language-plaintext highlighter-rouge">parser</code> for modern code.</li>
  <li>And yes, a bit of speed. About that…</li>
</ul>

<h2 id="parsing-was-never-the-bottleneck">Parsing was never the bottleneck</h2>

<p>Here’s what parsing RuboCop’s own source code (about 1,800 files) costs on my
machine:</p>

<table>
  <thead>
    <tr>
      <th> </th>
      <th style="text-align: right">Time</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Prism alone (<code class="language-plaintext highlighter-rouge">Prism.parse_lex</code>)</td>
      <td style="text-align: right">1.0s</td>
    </tr>
    <tr>
      <td>The new <code class="language-plaintext highlighter-rouge">prism</code> engine</td>
      <td style="text-align: right">4.5s</td>
    </tr>
    <tr>
      <td><code class="language-plaintext highlighter-rouge">parser_prism</code> (translation layer)</td>
      <td style="text-align: right">5.0s</td>
    </tr>
    <tr>
      <td>The <code class="language-plaintext highlighter-rouge">parser</code> gem</td>
      <td style="text-align: right">roughly 4.5x the Prism engines</td>
    </tr>
  </tbody>
</table>

<p>So the new engine is about 10% faster than the translation layer, and allocates 9%
fewer objects. Nice, but look at the first two rows - Prism needs one second, and we
spend three and a half more turning its tree into ours. Most of what’s left of the
parsing cost is our own node and source map building, not parsing.</p>

<p>And then look at the big picture. A full single-process run over those same files
with the default configuration takes about 38 seconds, and the profiler puts
everything parser-related (Prism, building our nodes, the tokens) at roughly a tenth
of that. The other 90% is cops doing their job, and no parser in the world will make
them faster.</p>

<p>Startup tells the same story. Running RuboCop on a single small file takes about half
a second here. Close to half of that is Bundler, the rest is loading and configuring a
few hundred cops, and the parser shows up for a couple of milliseconds.
That’s the problem <a href="/posts/2022/07/26/rubocop-serves-much-faster.html">server mode</a>
solves, by the way.</p>

<p>These days there are projects like <a href="https://github.com/costajohnt/rbcop">rbcop</a>, which is RuboCop rewritten in Rust and
claims to be 20 times faster, so it might seem we’re doing embarrassingly little to
speed RuboCop up. Guilty as charged. In our defense - we’re trying to stay true to
the spirit of Ruby. By running on Ruby. :D<sup id="fnref:2" role="doc-noteref"><a href="#fn:2" class="footnote" rel="footnote">2</a></sup></p>

<h2 id="known-limitations">Known limitations</h2>

<ul>
  <li>You need Prism 2 to get the new engine. If something in your bundle holds Prism
back, nothing breaks - you just stay where you were.</li>
  <li>Target Ruby versions below 3.3 still need the <code class="language-plaintext highlighter-rouge">parser</code> gem, and so does asking for
<code class="language-plaintext highlighter-rouge">parser_whitequark</code> or <code class="language-plaintext highlighter-rouge">parser_prism</code> explicitly.</li>
  <li><code class="language-plaintext highlighter-rouge">parser</code> is still a dependency of both RuboCop and RuboCop AST. Dropping it would
break everyone who lints old Ruby code, so that’s a conversation for RuboCop 2.0.</li>
  <li>If you somehow end up with a parser engine that can’t handle your target Ruby
version, RuboCop now tells you so in plain words instead of greeting you with a
backtrace.</li>
</ul>

<h2 id="what-might-come-next">What might come next</h2>

<p>No promises here, just the things on my mind:</p>

<ul>
  <li>Building source maps lazily. That’s where most of those three and a half seconds
go, and many nodes never have their location looked at.</li>
  <li>Linting files with syntax errors. Prism recovers from errors and still gives you a
tree, which <code class="language-plaintext highlighter-rouge">parser</code> never could. Your editor would love that, since code is broken
most of the time while you’re typing it.</li>
  <li>Our own node types for new syntax, instead of waiting for upstream.</li>
  <li>Giving the source layer a proper home under <code class="language-plaintext highlighter-rouge">RuboCop::AST</code> (with the old names kept
as aliases, of course).</li>
  <li>Dropping the <code class="language-plaintext highlighter-rouge">parser</code> dependency in RuboCop 2.0, and retiring the translation
layer once Prism 2 is everywhere.</li>
</ul>

<h2 id="the-rest-of-the-release">The rest of the release</h2>

<p>The other big theme is a familiar one - autocorrection you can trust. There are 66
bug fixes in this release, and most of them are about corrections that ate a heredoc
body, dropped a comment or quietly changed what the code does. <a href="https://github.com/Starlexxx">Starlexxx</a> found
(with a fuzzer!) and fixed a big chunk of them, and Koichi took care of plenty more.</p>

<p>A couple of smaller things:</p>

<ul>
  <li>A config file passed with <code class="language-plaintext highlighter-rouge">--config</code> now has its <code class="language-plaintext highlighter-rouge">TargetRubyVersion</code> validated,
like any other config file.</li>
  <li><code class="language-plaintext highlighter-rouge">Lint/DuplicateMethods</code> no longer complains about a method that’s redefined after
<code class="language-plaintext highlighter-rouge">undef</code>, <code class="language-plaintext highlighter-rouge">undef_method</code> or <code class="language-plaintext highlighter-rouge">remove_method</code>. Thanks, <a href="https://github.com/APX403">APX403</a>!</li>
</ul>

<p>The <a href="https://github.com/rubocop/rubocop/releases/tag/v1.93.0">release notes</a> have the full list.</p>

<h2 id="epilogue">Epilogue</h2>

<p>This is one of those releases where the most important change is one you’re not
supposed to notice. If you do notice something - an offense that appears or
disappears when you switch between <code class="language-plaintext highlighter-rouge">ParserEngine: prism</code> and <code class="language-plaintext highlighter-rouge">parser_prism</code> - that’s
a bug, and I’d love to <a href="https://github.com/rubocop/rubocop/issues">hear about it</a>.</p>

<p>Big thanks to Kevin Newton and everyone working on Prism, to Koichi for keeping
RuboCop in sync with it all these years, to Marc-André for reviewing the RuboCop AST
side of this, and to everyone who contributed to the release!</p>

<p>That’s all I have for you today. Keep hacking!</p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>Not that you can uninstall it just yet - see the limitations below. <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:2" role="doc-endnote">
      <p>I was curious how much of that gap is just startup time, so I measured. On
  RuboCop’s own code rbcop needs about 14 times less CPU time per file, startup
  not included. Impressive stuff! <a href="#fnref:2" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Ruby" /><category term="RuboCop" /><category term="Prism" /><summary type="html"><![CDATA[RuboCop 1.93 is out! Almost three years ago I wrote about using RuboCop with Prism for the first time, and I was VERY excited about it. Since then Prism quietly became the default parser for modern Ruby code, but it always reached RuboCop through a translation layer that made it look like the good old parser gem. With this release (and RuboCop AST 1.54) the middleman is gone - RuboCop can now build its AST straight from Prism. That sounds like the kind of change that should come with fireworks and a 10x speedup. It doesn’t, and I think the reasons why are more interesting than the change itself.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">Clojurists Together Update: September and October 2026</title><link href="https://metaredux.com/posts/2026/11/06/clojurists-together-update-september-october-2026.html" rel="alternate" type="text/html" title="Clojurists Together Update: September and October 2026" /><published>2026-11-06T09:00:00+00:00</published><updated>2026-11-06T09:00:00+00:00</updated><id>https://metaredux.com/posts/2026/11/06/clojurists-together-update-september-october-2026</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/06/clojurists-together-update-september-october-2026.html"><![CDATA[<p>Time for another bi-monthly update on the work that <a href="https://www.clojuriststogether.org/">Clojurists Together</a> are funding this year - my
maintenance of <a href="https://nrepl.org">nREPL</a>, <a href="https://cider.mx">CIDER</a> and friends. You can find the <a href="/posts/2026/09/10/clojurists-together-update-july-august-2026.html">previous one</a> here.</p>

<p>For a change, most of my focus in September and October was on nREPL itself, not on CIDER.
The big themes were the nREPL protocol spec and how well the servers and clients out there actually stick to it.
For years building an nREPL server or client that plays well with the rest of the ecosystem came down to trial and error,
and this time I finally did something about it. It paid off much sooner than I expected.</p>

<!--more-->

<p>The big highlights from my perspective:</p>

<ul>
  <li><a href="https://github.com/nrepl/proof">proof</a>, a compatibility suite for nREPL servers and clients, is out, and it’s already found (and helped fix) problems in nREPL itself, Babashka, CIDER, Calva, Conjure and many other servers and clients</li>
  <li><a href="https://github.com/nrepl/neorepl">neorepl</a>, a brand new terminal REPL meant to be something like “CIDER in a terminal” and “CIDER for agents”, went from 0.1 to 0.4 in two weeks</li>
  <li>nREPL 1.8 is out, and master already has fixes for some of the bugs proof found in it</li>
  <li><a href="https://github.com/nrepl/piggieback">Piggieback</a> 0.7.1 and 0.8.0 fixed a few long-standing problems with ClojureScript REPLs</li>
  <li>nrepl.org became a proper landing page (with an nREPL server running right in your browser), the manual moved to docs.nrepl.org, and CIDER got a landing page of its own at <a href="https://cider.mx">cider.mx</a></li>
  <li>CIDER’s master gained streaming test results and commands for editing the <code class="language-plaintext highlighter-rouge">ns</code> form, backed by new cider-nrepl and Orchard releases</li>
</ul>

<p>Below you’ll find the details, project by project.</p>

<h2 id="proof-and-the-nrepl-spec">proof and the nREPL spec</h2>

<p><a href="https://github.com/nrepl/proof">proof</a> is the big new project this time around, and the one I’m most excited about.
I’ve been talking about some automated way to check nREPL compatibility for ages (it made my list of <a href="/posts/2023/03/26/bad-nrepl.html">things people hate about nREPL</a> back in 2023),
so it feels really great to finally see it become a reality. Good things take a while to happen, they said…
Does your server work with CIDER? Until now the only way to find out was to implement the protocol, connect CIDER (or Calva, or whatever your users run)
and see what breaks. Now you can point proof at your server and it’ll tell you. It’s a single binary that runs about 80 checks against a server.
A check fails only when a real client would break (with a link to the client code that depends on the behavior), and everything else is just a warning.
proof also comes with client profiles that send exactly what CIDER, Calva, Conjure, vim-fireplace, REPLy and neorepl send,
profiles for the servers I know of, and a GitHub Action for running it in a server’s CI.</p>

<p>Once the server side was in place, I started on the clients as well. <code class="language-plaintext highlighter-rouge">proof proxy</code> sits between a client and a server and checks what the client sends,
and <code class="language-plaintext highlighter-rouge">proof serve</code> is a small server for the test suites of clients, which can mimic the quirks of nREPL, Babashka, jank and others (<code class="language-plaintext highlighter-rouge">proof serve -like jank</code>).
I wrote about proof in a lot more detail in <a href="/posts/2026/11/05/proof-how-strong-is-your-nrepl.html">proof: How Strong Is Your nREPL?</a>.</p>

<ul>
  <li><a href="https://github.com/nrepl/proof/releases/tag/v0.1.0">proof 0.1.0</a> came out on October 26.</li>
  <li><a href="https://github.com/nrepl/proof/releases/tag/v0.2.0">proof 0.2.0</a> followed a week later, along with a <a href="https://nrepl.github.io/proof/">compatibility matrix</a> that runs proof against every server it knows about daily.</li>
</ul>

<p>proof goes hand in hand with the <a href="https://spec.nrepl.org">nREPL spec</a>, the draft Phil Hagelberg wrote earlier this year.
When the spec and the existing clients disagree, proof goes with the clients (a spec that breaks CIDER isn’t much use to anyone),
and every such conflict, along with the gaps proof ran into, ends up on a <a href="https://github.com/nrepl/proof/blob/main/doc/spec-changes.md">list of spec changes</a>.
The first few of them are already PRs against the spec: how replies relate to their requests, the status values, how interrupts are answered
and the fields of lookup replies.</p>

<p>What I like the most about proof is how quickly it started paying off:</p>

<ul>
  <li>nREPL itself sent the <code class="language-plaintext highlighter-rouge">done</code> of an eval interrupted from another connection to the wrong connection (fixed on master), drops the evals waiting behind an interrupted one (<a href="https://github.com/nrepl/nrepl/issues/503">#503</a>) and can’t interrupt an eval that hasn’t started yet (<a href="https://github.com/nrepl/nrepl/issues/504">#504</a>). Not great!</li>
  <li>Between proof and neorepl, Babashka got a couple of dozen issue reports from me in October, from test ops that never answered to a session that stopped answering after its client went away in the middle of an eval. Michiel Borkent fixed nearly all of them the same day or the next. You rock, Michiel!</li>
  <li>CIDER didn’t finish setting up connections to servers without cider-nrepl (fixed), Calva and Conjure didn’t sort the keys of the dictionaries they sent (both fixed within days), vim-fireplace and REPLy never close their sessions, and REPLy’s and Conjure’s interrupts don’t say which eval to stop.</li>
  <li>Basilisp and jank got a few reports as well (lookup replies, and a request that throws taking its whole connection down).</li>
  <li>My own toy implementations (nrepl-beam, mezcaml and neat) were the first projects I ran proof against (more on them below).</li>
</ul>

<p>I was also super happy to see other people using proof already. Tom Waddington has been running it against his nREPL implementations
for <a href="https://github.com/waddie/nrepl-janet">Janet</a> and <a href="https://github.com/waddie/nrepl-steel">Steel Scheme</a> since early October (nrepl-janet even tests its client with <code class="language-plaintext highlighter-rouge">proof serve</code>),
Jeaye Wilkerson <a href="https://github.com/jank-lang/jank/issues/1104">suggested</a> using it for jank’s nREPL server, and Kyle Cesare is already <a href="https://github.com/jank-lang/jank/pull/1175">fixing</a> what it found there.
That’s exactly what I was hoping for!</p>

<h2 id="neorepl">neorepl</h2>

<p><a href="https://github.com/nrepl/neorepl">neorepl</a> is the other brand new project, and it grew up together with proof.
It’s a <a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">terminal REPL for Clojure (and anything else that runs an nREPL server)</a>,
and the best way I can describe it is “CIDER in a terminal”: it uses cider-nrepl when it’s around, the same way CIDER does,
and falls back to nREPL’s built-in ops when it isn’t. Every lookup the REPL can do is also a command with structured output,
and there’s an MCP server and a skill for coding agents, so it’s “CIDER for agents” as well. Five releases in three weeks:</p>

<ul>
  <li><a href="https://github.com/nrepl/neorepl/releases/tag/v0.1.0">neorepl 0.1.0</a> had the REPL with a proper line editor (highlighting, completion, arglists as you type, history per project, a Ctrl-C that actually interrupts), CIDER-style REPL commands, jack-in for Leiningen, the Clojure CLI, Babashka and shadow-cljs, and commands for evaluating code and looking things up that keep their session between calls. It runs on the JVM and on Babashka.</li>
  <li><a href="https://github.com/nrepl/neorepl/releases/tag/v0.2.0">neorepl 0.2.0</a> added a test runner (Clojure and ClojureScript), a full-screen inspector and a stacktrace browser.</li>
  <li><a href="https://github.com/nrepl/neorepl/releases/tag/v0.3.0">neorepl 0.3.0</a> was all about coding agents: <code class="language-plaintext highlighter-rouge">neorepl mcp</code>, a skill that teaches agents to check, load, test and debug Clojure code with the CLI, and <code class="language-plaintext highlighter-rouge">neorepl check --fix</code>, which fixes mismatched delimiters the way parinfer does.</li>
  <li><a href="https://github.com/nrepl/neorepl/releases/tag/v0.4.0">neorepl 0.4.0</a> brought tracing, switching the REPL into another named session (e.g. to take a look at what your coding agent is doing), and a huge list of fixes. I wrote about it (and the two releases before it) in <a href="/posts/2026/10/30/neorepl-0-4.html">neorepl 0.4: Tests, Inspector, Tracing and Agents</a>.</li>
  <li><a href="https://github.com/nrepl/neorepl/releases/tag/v0.4.1">neorepl 0.4.1</a> caught up with cider-nrepl 0.64.</li>
</ul>

<p>proof checks every server with the exact requests neorepl sends, and neorepl went through <code class="language-plaintext highlighter-rouge">proof proxy</code> and every scenario of <code class="language-plaintext highlighter-rouge">proof serve</code> before 0.1 was out.
Its commands are separate processes sharing a session, so neorepl hits nREPL’s interrupt bugs harder than most clients,
and making it work as well on Babashka’s server as with cider-nrepl is where most of the Babashka reports came from.
Even JLine got a few bug reports along the way.</p>

<p>By the time I got around to writing this update, <a href="https://github.com/nrepl/neorepl/releases/tag/v0.5.0">neorepl 0.5</a> was out as well,
with a much smarter line editor, a namespace browser, automatic reloading and a CLI that editors can use without a plugin.
I wrote about it in <a href="/posts/2026/11/05/neorepl-0-5.html">neorepl 0.5: CIDER in a Terminal</a>.</p>

<h2 id="nrepl">nREPL</h2>

<p><a href="https://github.com/nrepl/nrepl/releases/tag/v1.8.0">nREPL 1.8.0</a> came out on October 2 with the URL-based connections and the TLS improvements I mentioned last time,
plus a few session fixes. Sessions survive evaluated code closing <code class="language-plaintext highlighter-rouge">*in*</code> or <code class="language-plaintext highlighter-rouge">*out*</code>, a race that could split responses between concurrent reads in <code class="language-plaintext highlighter-rouge">nrepl.core/client</code> is gone,
and Sashko made persistent sessions re-create their thread when a faulty exec thunk kills it. He also moved the Unix sockets to the <code class="language-plaintext highlighter-rouge">SocketChannel</code> API.</p>

<p>Master moved on quickly after the release, much of it because of proof and neorepl:</p>

<ul>
  <li>the <code class="language-plaintext highlighter-rouge">done</code> of an eval interrupted from another connection goes to the eval’s own connection, where the client that sent the eval never got it</li>
  <li>the server sets <code class="language-plaintext highlighter-rouge">TCP_NODELAY</code> on accepted connections, so on Linux an eval’s <code class="language-plaintext highlighter-rouge">done</code> no longer waits up to 40ms behind its value</li>
  <li>Sashko replaced <code class="language-plaintext highlighter-rouge">:out-limit</code> with separate <code class="language-plaintext highlighter-rouge">:out-quota</code> and <code class="language-plaintext highlighter-rouge">:err-quota</code> limits, made the bencode transport turn empty lists into <code class="language-plaintext highlighter-rouge">nil</code> for <code class="language-plaintext highlighter-rouge">?</code>-ending keys and made building the middleware stack faster</li>
</ul>

<p>The interrupt bugs that are still open are next on my list.</p>

<h2 id="piggieback">Piggieback</h2>

<ul>
  <li><a href="https://github.com/nrepl/piggieback/releases/tag/0.7.1">Piggieback 0.7.1</a> fixed <code class="language-plaintext highlighter-rouge">load-file</code> failing with “No such namespace” when the file requires a foreign lib (e.g. a cljsjs package).</li>
  <li><a href="https://github.com/nrepl/piggieback/releases/tag/0.8.0">Piggieback 0.8.0</a> fixed <code class="language-plaintext highlighter-rouge">:cljs/quit</code> on nREPL 1.3+, where the session stayed in ClojureScript mode, and made evaluation use the same dynamic bindings as <code class="language-plaintext highlighter-rouge">cljs.repl</code>. That means the <code class="language-plaintext highlighter-rouge">cljs-repl</code> options (e.g. <code class="language-plaintext highlighter-rouge">:warnings</code>) and the bindings tools like figwheel-main set up around it finally take effect, which closes an issue from 2018. It also picked up <code class="language-plaintext highlighter-rouge">:as-alias</code> keywords and the <code class="language-plaintext highlighter-rouge">:cljs</code> branch of <code class="language-plaintext highlighter-rouge">data_readers.cljc</code>.</li>
</ul>

<h2 id="nreplorg-and-cidermx">nrepl.org and cider.mx</h2>

<p>nrepl.org got a facelift at the end of October. The manual moved to <a href="https://docs.nrepl.org">docs.nrepl.org</a>,
and <a href="https://nrepl.org">nrepl.org</a> itself is now a landing page that explains what nREPL is and how its protocol works,
with real exchanges between a client and a server next to every feature. It even has a <a href="https://nrepl.org/#try">“Try it”</a> section with an nREPL server
running right in your browser, which turned out to be <a href="/posts/2026/11/01/nrepl-right-in-your-browser.html">a story of its own</a>.
That playground is how <a href="https://github.com/nrepl/nrepl-sci">nrepl-sci</a>, a small nREPL server for SCI that runs entirely in a web page, came to be,
and it even led me to take a closer look at <a href="https://github.com/nextjournal/clojure-mode">clojure-mode</a> for CodeMirror, which powers the playground’s editor.</p>

<p>CIDER got a landing page of its own at <a href="https://cider.mx">cider.mx</a>, made to look like an Emacs frame (mode line, <code class="language-plaintext highlighter-rouge">M-x</code> and all), with mini screencasts of CIDER in action.
I had a lot of fun working on both sites!</p>

<h2 id="neat-mezcaml-and-nrepl-on-the-beam">neat, mezcaml and nREPL on the BEAM</h2>

<p>My toy nREPL implementations were the first things I ran proof against, and all of them got a round of fixes in early October:</p>

<ul>
  <li>dialtone and repartee, the Erlang and Elixir servers in <a href="https://github.com/nrepl/nrepl-beam">nrepl-beam</a>, now answer <code class="language-plaintext highlighter-rouge">close</code> with <code class="language-plaintext highlighter-rouge">session-closed</code>, echo the op in <code class="language-plaintext highlighter-rouge">unknown-op</code> replies and return a value for every Erlang form in an eval</li>
  <li><a href="https://github.com/nrepl/mezcaml">mezcaml</a> no longer lets late output from one eval end the next one early, interrupts on Ctrl-C, answers stdin requests, closes its session on exit and completes on jank and Basilisp</li>
  <li><a href="https://github.com/nrepl/neat">neat</a> shows late and id-less output, reports error statuses that come without <code class="language-plaintext highlighter-rouge">err</code>, handles unknown sessions and stdin EOF, and checks <code class="language-plaintext highlighter-rouge">describe</code> before using completions, lookup and interrupt</li>
</ul>

<p>neat’s own integration suite now tests just the client and leaves the servers to proof. None of the three has had a release yet, though.</p>

<h2 id="cider">CIDER</h2>

<p>No CIDER release this time (2.1 is still brewing), but master kept moving:</p>

<ul>
  <li>Test results now stream in while the tests run (<code class="language-plaintext highlighter-rouge">cider-test-stream-results</code>, on by default): the echo area keeps a running count, and failing tests land in the report as soon as they finish. This closes an issue from 2014! <code class="language-plaintext highlighter-rouge">cider-test-fail-fast</code> is now off by default to go with it.</li>
  <li>A family of commands for editing the <code class="language-plaintext highlighter-rouge">ns</code> form: <code class="language-plaintext highlighter-rouge">cider-ns-add-require</code>, <code class="language-plaintext highlighter-rouge">cider-ns-add-import</code>, <code class="language-plaintext highlighter-rouge">cider-ns-add-missing</code> (adds what the symbol at point needs), magic requires (typing <code class="language-plaintext highlighter-rouge">alias/</code> adds the require the alias needs) and <code class="language-plaintext highlighter-rouge">cider-ns-clean</code>. These are some of clj-refactor’s most popular features, and they’re backed by new cider-nrepl ops that read your code instead of loading it.</li>
  <li>Connecting to a server without cider-nrepl (e.g. plain nREPL or Babashka) finishes setting up the connection again, where <code class="language-plaintext highlighter-rouge">cider-connected-hook</code> and friends never ran. proof found this one.</li>
  <li>Keys with a <code class="language-plaintext highlighter-rouge">nil</code> value are left out of nREPL requests instead of being sent as empty lists, which closes an issue from 2020.</li>
  <li>Natively compiled builds no longer have broken menu options, Emacs 31 is on CI, and the manual got per-build-tool setup tabs, the refcard and CI checks for its cross references.</li>
</ul>

<h2 id="cider-nrepl-and-orchard">cider-nrepl and Orchard</h2>

<p><a href="https://github.com/clojure-emacs/cider-nrepl">cider-nrepl</a> releases:</p>

<ul>
  <li><a href="https://github.com/clojure-emacs/cider-nrepl/releases/tag/v0.63.0">cider-nrepl 0.63.0</a> runs tests with <code class="language-plaintext highlighter-rouge">orchard.test</code> and streams their progress to the client, which is what CIDER’s test streaming builds on.</li>
  <li><a href="https://github.com/clojure-emacs/cider-nrepl/releases/tag/v0.63.1">cider-nrepl 0.63.1</a> was Sashko’s quick bump to compliment 0.8.2.</li>
  <li><a href="https://github.com/clojure-emacs/cider-nrepl/releases/tag/v0.64.0">cider-nrepl 0.64.0</a> added the <code class="language-plaintext highlighter-rouge">cider/resolve-missing</code>, <code class="language-plaintext highlighter-rouge">cider/resolve-alias</code> and <code class="language-plaintext highlighter-rouge">cider/clean-ns</code> ops behind CIDER’s <code class="language-plaintext highlighter-rouge">ns</code> commands (after three alphas), made the test ops always answer and send what tests print with their own responses on nREPL 1.3+, and fixed the inspector and ClojureScript tests on shadow-cljs.</li>
</ul>

<p><a href="https://github.com/clojure-emacs/orchard">Orchard</a> releases:</p>

<ul>
  <li><a href="https://github.com/clojure-emacs/orchard/releases/tag/v0.45.0">Orchard 0.45.0</a> added <code class="language-plaintext highlighter-rouge">orchard.test</code>, the <code class="language-plaintext highlighter-rouge">clojure.test</code> runner that used to live in cider-nrepl and can now report progress as it goes, plus Sashko’s string analytics in the inspector and his fix for the stack overflows when printing recursive collections.</li>
  <li><a href="https://github.com/clojure-emacs/orchard/releases/tag/v0.46.0">Orchard 0.46.0</a> and <a href="https://github.com/clojure-emacs/orchard/releases/tag/v0.47.0">Orchard 0.47.0</a> added <code class="language-plaintext highlighter-rouge">orchard.ns-form</code>, which takes apart an <code class="language-plaintext highlighter-rouge">ns</code> form and tells what it requires, refers and imports that the code doesn’t use, all without loading anything, and fixed some Java doc rendering problems.</li>
  <li><a href="https://github.com/clojure-emacs/orchard/releases/tag/v0.48.0">Orchard 0.48.0</a> made tracing show calls that throw and stopped tracing a function tracing itself uses (say, <code class="language-plaintext highlighter-rouge">str</code>) from overflowing the stack.</li>
</ul>

<p>Sashko also added JDK 27 to the CI of nREPL, cider-nrepl and Orchard. Thanks, Sashko!</p>

<h2 id="refactor-nrepl-and-clj-refactor">refactor-nrepl and clj-refactor</h2>

<p><a href="https://github.com/clojure-emacs/refactor-nrepl/releases/tag/v3.15.0">refactor-nrepl 3.15.0</a> documented the limitations of its AST-based analysis
and deprecated the ops cider-nrepl has taken over. Back in the spring I said I’d like to move the most useful refactor-nrepl features
to CIDER and cider-nrepl eventually, and the <code class="language-plaintext highlighter-rouge">ns</code> editing commands above are the first step in that direction.</p>

<h2 id="clojure-ts-mode">clojure-ts-mode</h2>

<p>No release, but quite a few fixes on main. I fixed clojure-ts-mode on Emacs 31 (e.g. the ClojureScript mode asking for the jsdoc grammar, <code class="language-plaintext highlighter-rouge">M-q</code> indenting only the innermost form)
and a pile of refactoring commands that went wrong around metadata, <code class="language-plaintext highlighter-rouge">#_</code> forms and reader conditionals.
Jason Jackson sent a round of indentation and alignment fixes (threading macros, reader prefixes, metadata and comments before arguments),
and Kyle Cesare kept up with jank’s syntax. Thanks, Jason and Kyle!</p>

<h2 id="mranderson-and-smaller-things">MrAnderson and smaller things</h2>

<p><a href="https://github.com/benedekfazekas/mranderson/releases/tag/v0.7.2">MrAnderson 0.7.2</a> stopped bundling pomegranate’s Maven classes in its jar,
where they clashed with any other resolver on the classpath and broke cider-nrepl’s build once tools.build pulled in a newer tools.deps. The artifact went from 8 MB to about 200 KB in the process.</p>

<p>There was also a lot of release and CI maintenance across nREPL, cider-nrepl, Orchard, Piggieback and friends
(e.g. release notes taken from the changelogs, the docs of a release published by its release workflow), and I revived the CI of parseclj and parseedn.</p>

<h2 id="blog-posts">Blog posts</h2>

<ul>
  <li><a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">neorepl: A Terminal REPL for Clojure (and Friends)</a></li>
  <li><a href="/posts/2026/10/30/neorepl-0-4.html">neorepl 0.4: Tests, Inspector, Tracing and Agents</a></li>
  <li><a href="/posts/2026/11/01/nrepl-right-in-your-browser.html">nREPL, Right in Your Browser</a></li>
  <li><a href="/posts/2026/11/05/neorepl-0-5.html">neorepl 0.5: CIDER in a Terminal</a></li>
  <li><a href="/posts/2026/11/05/proof-how-strong-is-your-nrepl.html">proof: How Strong Is Your nREPL?</a></li>
</ul>

<h2 id="epilogue">Epilogue</h2>

<p>Big thanks to Clojurists Together, Nubank and the other organizations and people supporting my Clojure OSS work! None of this would have happened without you. You rock!</p>

<p>As for what’s next - last time I said CIDER 2.1 was the obvious next milestone. It still is, but it got delayed, as most of my time went into nREPL instead.
I told you I’m bad at predictions! nREPL 1.8 shipped as planned, and mezcaml and the BEAM servers got a lot more reliable thanks to proof, even if neither got a release.
While we’ve made solid progress on CIDER and friends as well, my main focus until the end of the year will likely be the broader nREPL ecosystem:
fixing the interrupt bugs proof found in nREPL, turning the list of spec changes into PRs against the spec, and getting more servers and clients to run proof.</p>

<p>Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="CIDER" /><category term="OSS" /><summary type="html"><![CDATA[Time for another bi-monthly update on the work that Clojurists Together are funding this year - my maintenance of nREPL, CIDER and friends. You can find the previous one here. For a change, most of my focus in September and October was on nREPL itself, not on CIDER. The big themes were the nREPL protocol spec and how well the servers and clients out there actually stick to it. For years building an nREPL server or client that plays well with the rest of the ecosystem came down to trial and error, and this time I finally did something about it. It paid off much sooner than I expected.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">proof: How Strong Is Your nREPL?</title><link href="https://metaredux.com/posts/2026/11/05/proof-how-strong-is-your-nrepl.html" rel="alternate" type="text/html" title="proof: How Strong Is Your nREPL?" /><published>2026-11-05T21:00:00+00:00</published><updated>2026-11-05T21:00:00+00:00</updated><id>https://metaredux.com/posts/2026/11/05/proof-how-strong-is-your-nrepl</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/05/proof-how-strong-is-your-nrepl.html"><![CDATA[<p>For as long as I’ve been involved with nREPL, the question I’ve heard most
often from people building servers and clients has been some variation of
“Will this work with CIDER?”. And for just as long the honest answer was “Try
it and see”. Today I have a better answer for you -
<a href="https://github.com/nrepl/proof">proof</a>, a compatibility suite for nREPL
servers (and clients). I’ve been working on it since the end of September and
<a href="https://github.com/nrepl/proof/releases/tag/v0.2.0">proof 0.2</a> came out a couple of days ago, so I guess it’s high time
I told you a bit about it.</p>

<!--more-->

<h2 id="try-it-and-see">Try It and See</h2>

<p>The nREPL protocol is tiny. A handful of ops, requests and responses that are
simple maps, bencode on the wire. You can write a basic nREPL server in a
couple of hours, and lots of people have done exactly that. Making it play nice with
CIDER, Calva, Conjure and the rest of the clients out there is a very
different matter, though. What clients actually expect from a server is
spread across the reference implementation, a draft spec, many years of
client code and lots of GitHub issues. Which status values mean what? Is
<code class="language-plaintext highlighter-rouge">ops</code> in <code class="language-plaintext highlighter-rouge">describe</code> a map or a list? Where does the end of an interrupted
evaluation go? What happens to a session when its client goes away in the
middle of an eval? Server authors usually find out one bug report at a time.</p>

<p>Client authors don’t have it any easier, as every server has its own quirks,
and for many years the only way to find them was to try your client with every
server you could get your hands on. I’ve been on both sides of this
conversation for well over a decade (CIDER is a client, nREPL is a server), so
believe me - I know the pain.</p>

<h2 id="bigger-than-clojure">Bigger Than Clojure</h2>

<p>Why bother? Because I’ve always seen nREPL as something bigger than Clojure.
Back in 2019 I wrote that nREPL is <a href="/posts/2019/01/12/nrepl-beyond-clojure.html">similar in nature to
LSP</a>, only much simpler, and I
still believe that. For any language that can evaluate code at runtime, nREPL
is a much simpler alternative to LSP. Implement <code class="language-plaintext highlighter-rouge">eval</code>, <code class="language-plaintext highlighter-rouge">interrupt</code> and
<code class="language-plaintext highlighter-rouge">load-file</code>, throw in completions and lookups if you feel like it, and every
nREPL client out there becomes an editor integration for your language.</p>

<p>That’s not just a dream anymore. These days there are nREPL servers for
Clojure dialects running on Python (Basilisp), C++ (jank), .NET (ClojureCLR),
Go (let-go) and Node.js (nbb), for Janet and Steel Scheme, and even for
Erlang and Elixir (more on those later). Still, “language-agnostic” doesn’t
mean much if everyone who builds a server has to check it against CIDER by
hand.</p>

<h2 id="better-late-than-never">Better Late Than Never</h2>

<p>The idea of a compatibility suite is not new. When nREPL 1.0 came out in 2022
I wrote that <a href="https://github.com/nrepl/nrepl/discussions/273">improving the protocol spec and the ability to test against
it</a> was where our focus
should go next, and a year later the lack of a compatibility test suite made
my list of <a href="/posts/2023/03/26/bad-nrepl.html">things people hate about
nREPL</a>. I even asked if one of you was
looking for a fun small OSS project. Nobody volunteered, and the idea spent
a few more years on the backburner. This year, thanks to the support of
<a href="https://www.clojuriststogether.org/">Clojurists Together</a>, I finally made a
very focused push on it.</p>

<p>It started with the spec. Late last year Phil Hagelberg wrote a draft of <a href="https://spec.nrepl.org">the
nREPL protocol spec</a>, which landed in May. A spec is
great, but you can’t run a spec against your server, so I started proof. The
two feed each other - every time proof finds a place where the spec and the
clients disagree, or something the spec doesn’t cover at all, it ends up in
<a href="https://github.com/nrepl/proof/blob/main/doc/spec-changes.md">a running list</a>, and from there in the spec itself. (A few of
those are already pull requests against it.)</p>

<p>When the spec and the clients disagree, proof sides with the clients. For
instance, the spec recommends returning the ops in <code class="language-plaintext highlighter-rouge">describe</code> as a list, but
CIDER and Calva both expect a map. A server that follows the spec to the
letter, but that CIDER can’t connect to, is not much use to anyone. That’s
also why proof is a <em>compatibility</em> suite and not a <em>conformance</em> suite. You
can only conform to an official spec, and nREPL doesn’t have one yet.</p>

<h2 id="checking-servers">Checking Servers</h2>

<p>Checking servers is proof’s main job. It’s a single binary<sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup> that talks to
your server over a socket, the same way any client would. It knows nothing
about the server’s internals and it doesn’t care what language the server is
written in. What it does need is a profile - a small TOML file that tells
proof how to start your server and gives it a few snippets of code in the
server’s language (an idea I borrowed from
<a href="https://github.com/jupyter/jupyter_kernel_test">jupyter_kernel_test</a>):</p>

<div class="language-toml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="py">name</span> <span class="p">=</span> <span class="s">"My server"</span>

<span class="nn">[launch]</span>
<span class="py">command</span> <span class="p">=</span> <span class="p">[</span><span class="s">"my-server"</span><span class="p">,</span> <span class="s">"--port"</span><span class="p">,</span> <span class="s">"0"</span><span class="p">]</span>
<span class="py">port-pattern</span> <span class="p">=</span> <span class="s">'nREPL server started on port (\d+)'</span>

<span class="nn">[snippets.value]</span>
<span class="py">code</span> <span class="p">=</span> <span class="s">"(+ 1 2)"</span>
<span class="py">value</span> <span class="p">=</span> <span class="s">"3"</span>
</code></pre></div></div>

<p>Then you install proof and run it:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>go <span class="nb">install </span>github.com/nrepl/proof/cmd/proof@latest
<span class="nv">$ </span>proof run my-server.toml
</code></pre></div></div>

<p>proof starts your server, runs about 80 checks against it and shuts it down
afterwards. (You can also grab a binary from the
<a href="https://github.com/nrepl/proof/releases">releases</a>, if you don’t have Go
around.) Profiles for nREPL, Babashka, nbb, Basilisp, ClojureCLR, jank,
let-go, dialtone and repartee come with proof, so <code class="language-plaintext highlighter-rouge">proof run babashka</code> just
works if you have Babashka installed.</p>

<p>The most important decision in proof’s design is how it grades the checks. A
check fails only when some client won’t work properly with your server (or
when users will lose data), and the report tells you which client it is and
links to the client code in question, pinned to a specific commit. If your
server simply does something differently from the reference implementation,
you get a warning instead. Here’s a failure from a run against Babashka
1.13.226:</p>

<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>FAIL   interrupt.other-connection   An interrupted eval ends on its own connection
       the interrupted eval's done went to the connection the interrupt came from
       why: neorepl interrupt stops an eval that another neorepl process
       started, and that process waits for the eval's done on its own
       connection forever if it goes anywhere else.
       see: neorepl interrupt stops an eval from another process
       https://github.com/nrepl/neorepl/blob/462a182c.../src/neorepl/main.clj#L374-L385
       see: nrepl/nrepl#498 https://github.com/nrepl/nrepl/issues/498
</code></pre></div></div>

<p>The idea is that a failure should always be worth fixing and never be a
matter of taste. If you think some failure isn’t justified, the links show you
exactly what you need to argue with.</p>

<p>Some checks go a step further and send exactly what a particular client
sends, the way it sends it. <code class="language-plaintext highlighter-rouge">cider.connect</code> sends the requests CIDER sends
while connecting, <code class="language-plaintext highlighter-rouge">calva.eval</code> evaluates code the way Calva does, and so on
for Conjure, vim-fireplace, REPLy, neorepl, clojure-cli.repl and
<code class="language-plaintext highlighter-rouge">bb repl --connect</code>. That way the report tells you directly whether those clients will
work with your server.</p>

<p>Once your server passes everything it can pass, you can list the failures you
can’t fix yet as expected failures in its profile and run proof in your CI
with its <a href="https://github.com/nrepl/proof/blob/main/doc/usage.md#running-proof-in-ci">GitHub Action</a>. When an expected failure starts passing,
proof fails the build and asks you to remove it from the list, so the list
can’t go stale.</p>

<p>Last, but not least, the bundled profiles run every day and their reports end
up in a <a href="https://nrepl.github.io/proof/">compatibility matrix</a>, which shows
where the different servers agree, where they don’t and where the spec needs
some work.</p>

<h2 id="checking-clients">Checking Clients</h2>

<p>Servers were always proof’s primary focus, but once the foundation was in
place people started asking me how they could check their clients with it.
That made a lot of sense to me - after all, the same knowledge cuts both ways.
proof has two tools for client authors.</p>

<p><code class="language-plaintext highlighter-rouge">proof proxy</code> sits between a client and a server, passes everything along as
is and records it on the way. You use your client for a while (or run its
test suite through the proxy), press Ctrl-C and proof grades every request
the client sent. Here’s a quick <code class="language-plaintext highlighter-rouge">neorepl eval</code> going through it:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>proof proxy <span class="nt">-listen</span> 127.0.0.1:7888 babashka
<span class="nv">$ </span>neorepl <span class="nb">eval</span> <span class="nt">--port</span> 7888 <span class="s1">'(println "hi") (+ 1 2)'</span>
</code></pre></div></div>

<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>client
  PASS   client.bencode               Every frame is valid bencode
  PASS   client.dict                  Every request is a dict
  PASS   client.canonical             Frames use canonical bencode
  PASS   client.id                    Every request has an id
  PASS   client.active-id             An id isn't reused while its request is active
  PASS   client.field-types           Request fields have the right types
  PASS   client.required-fields       Requests carry the fields their op needs
  PASS   client.need-input            need-input is answered with stdin in the same session
  WARN   client.close                 Sessions are closed before disconnecting
  PASS   client.unknown-op            Requests use ops the server supports

9 passed, 0 failed, 1 warnings, 0 skipped
</code></pre></div></div>

<p>The grading rule is the same, just turned around. A client check fails only
when some server breaks, and it links to the server code in question. (That
warning is fine, by the way. neorepl keeps its session around on purpose, so
the next <code class="language-plaintext highlighter-rouge">neorepl eval</code> can use it.)</p>

<p>A proxy sees only what goes over the wire, though, so it can’t tell you how
your client copes with the replies of different servers. That’s what
<code class="language-plaintext highlighter-rouge">proof serve</code> is for. It’s a small nREPL server for client test suites, which
behaves like nREPL unless you ask it to behave like some other server in some
particular way - send only the value of the last form (like Basilisp, jank and
dialtone), drop what the code prints to stderr, have no <code class="language-plaintext highlighter-rouge">interrupt</code> op,
deliver its replies a byte at a time, and so on. None of those scenarios are
made up. Every one of them is something a real server does (or something TCP
can do to any server’s replies). <code class="language-plaintext highlighter-rouge">-like</code> turns on all the quirks of a server
at once, so you can run your client’s tests against “jank” without installing
jank:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>proof serve <span class="nt">-listen</span> 127.0.0.1:7888 <span class="nt">-like</span> jank
</code></pre></div></div>

<h2 id="proof-in-practice">proof in Practice</h2>

<p>So far, so good. But does it actually find anything? You bet! Here are some
of the things proof turned up in the past couple of months:</p>

<ul>
  <li>nREPL itself sent the end of an interrupted eval to the connection the
interrupt came from (fixed on master), drops the evals waiting behind an
interrupted one (<a href="https://github.com/nrepl/nrepl/issues/503">#503</a>) and
can leave a session that stops sending <code class="language-plaintext highlighter-rouge">done</code> after its client goes away in
the middle of an eval (<a href="https://github.com/nrepl/nrepl/issues/509">#509</a>).
Oops!</li>
  <li>Babashka, nbb, Basilisp, jank and ClojureCLR all had their share of rough
edges, e.g. errors without an <code class="language-plaintext highlighter-rouge">eval-error</code> status, sessions sharing <code class="language-plaintext highlighter-rouge">*1</code> and
the current namespace, and a request that throws taking its whole connection
down.</li>
  <li>CIDER skipped part of its setup when connecting to a server without
cider-nrepl, Calva and Conjure didn’t sort the keys of the dicts they sent, vim-fireplace
and REPLy never close their sessions, and Conjure’s interrupts don’t say
which eval to stop.</li>
</ul>

<p>Michiel Borkent fixed the Babashka and nbb issues the same day I reported
them (or the next one), Conjure fixed its encoder the next day and Calva
within a week. That’s the Clojure community for you!</p>

<p>I was also super happy to see other people picking up proof before I even got
around to announcing it. Tom Waddington has been running it against his nREPL
implementations for <a href="https://github.com/waddie/nrepl-janet">Janet</a> and
<a href="https://github.com/waddie/nrepl-steel">Steel Scheme</a> since early October
(nrepl-janet even tests its client with <code class="language-plaintext highlighter-rouge">proof serve</code>), Jeaye Wilkerson
<a href="https://github.com/jank-lang/jank/issues/1104">suggested</a> using it for
jank’s nREPL server, and Kyle Cesare is already
<a href="https://github.com/jank-lang/jank/pull/1175">fixing</a> what it found there.
That’s exactly what I was hoping for!</p>

<p>The projects that benefited from proof the most were my own, though. This
year I built a few toy nREPL implementations, mostly for fun and to see how
well the protocol holds up outside of Clojure:</p>

<ul>
  <li><a href="https://github.com/nrepl/nrepl-beam">nrepl-beam</a> has nREPL servers for
Erlang (dialtone) and Elixir (repartee). proof found that they didn’t answer
<code class="language-plaintext highlighter-rouge">close</code> with <code class="language-plaintext highlighter-rouge">session-closed</code>, didn’t echo unknown ops and returned only the
last value of several forms, and fixing those uncovered a race after <code class="language-plaintext highlighter-rouge">close</code>
and temporary sessions that never stopped.</li>
  <li><a href="https://github.com/nrepl/mezcaml">mezcaml</a>, my little OCaml client, read
replies as if only one request was ever in flight, so late output from one
eval could end the next one early.</li>
  <li><a href="https://github.com/nrepl/neat">neat</a>, my language-agnostic client for
Emacs, got late output, errors without <code class="language-plaintext highlighter-rouge">err</code> and unknown sessions wrong.</li>
  <li><a href="https://github.com/nrepl/nrepl-sci">nrepl-sci</a>, the nREPL server behind
the “Try it” section of nrepl.org, was the first server I wrote with proof
around from day one, and <a href="/posts/2026/11/01/nrepl-right-in-your-browser.html">working on
it</a> mostly came down
to running proof after every change.</li>
</ul>

<p>And then there’s
<a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">neorepl</a>,
the CIDER-inspired terminal REPL I’ve been working on lately, which is just as
happy to be used by coding agents as by humans. neorepl and proof pretty much
grew up together. I ran neorepl through <code class="language-plaintext highlighter-rouge">proof proxy</code> and every scenario of
<code class="language-plaintext highlighter-rouge">proof serve</code>, which caught a few bugs before neorepl 0.1 was out, and proof
checks every server with the exact requests neorepl sends. It’s also how I
found the interrupt bugs in nREPL above, which hit neorepl harder than most
clients. Its commands are separate processes sharing a session, so
<code class="language-plaintext highlighter-rouge">neorepl interrupt</code> stops an eval that some <code class="language-plaintext highlighter-rouge">neorepl eval</code> started, and that
<code class="language-plaintext highlighter-rouge">neorepl eval</code> used to wait for its <code class="language-plaintext highlighter-rouge">done</code> forever.</p>

<h2 id="a-tool-for-tool-authors">A Tool for Tool Authors</h2>

<p>I guess I should spell out who proof is for. If you’re using nREPL through CIDER
or Calva you’ll probably never run proof yourself (although hopefully you’ll
feel its effects). proof is a tool for tool authors - people writing nREPL
servers, clients and middleware.</p>

<p>I really hope that it will make it a lot easier to grow the nREPL ecosystem.
These days anyone can put together an nREPL server or client in no time with
the help of tools like Claude. Writing the code is no longer the hard part -
knowing whether the result actually works with CIDER, Calva and friends is.
proof gives you (and your coding agent) a fast feedback loop and failures that
explain themselves: what went wrong, why it matters and which client code
depends on it. That’s usually all an agent needs to fix the problem.</p>

<h2 id="why-proof">Why “proof”?</h2>

<p>Naming is hard! Luckily, the nREPL world has a tradition that makes it a bit
easier, as many nREPL clients are named after drinks (CIDER, neat, mezcaml,
chaser and so on). proof is not a client, so it bends the rule a bit, but it still
belongs at the bar. The proof of a spirit is a measure of its strength, which
is more or less what this tool measures for nREPL servers. And running it
gives you proof that your server works with the existing clients (or a list of
the reasons why it doesn’t). Two meanings for the price of one!<sup id="fnref:2" role="doc-noteref"><a href="#fn:2" class="footnote" rel="footnote">2</a></sup></p>

<h2 id="epilogue">Epilogue</h2>

<p>proof is still in its early days, but it already covers the core of the
protocol, the exact requests of the most popular clients and the server quirks
clients have to deal with. Now it needs more users.</p>

<p>So, if you’re working on an nREPL server or client, please take proof out for
a spin and let me know how it went! I’d love to see your server in the
compatibility matrix, and if you think some failure isn’t fair, open an issue
and let’s argue about it. And if you’re a casual Clojure hacker who’d just like
a nice REPL in the terminal, give neorepl a try:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>bbin <span class="nb">install </span>io.github.nrepl/neorepl
</code></pre></div></div>

<p>Big thanks to Clojurists Together for supporting my work on nREPL, to Phil
Hagelberg for getting the spec going, and to the maintainers of all the
servers and clients who were so quick to fix the problems proof found. You
rock! In the (n)REPL we trust!</p>

<p>That’s all I have for you today. Keep hacking!</p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>Written in Go, of all things. A Clojure tool would have been the obvious choice, but proof shouldn’t favour any of the languages it checks, and a single binary without a runtime is easy to drop into any CI. <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:2" role="doc-endnote">
      <p>“hangover” would have been a good name for what you get when a server forgets to send <code class="language-plaintext highlighter-rouge">done</code>, but it’s a hard sell for a project. <a href="#fnref:2" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="proof" /><summary type="html"><![CDATA[For as long as I’ve been involved with nREPL, the question I’ve heard most often from people building servers and clients has been some variation of “Will this work with CIDER?”. And for just as long the honest answer was “Try it and see”. Today I have a better answer for you - proof, a compatibility suite for nREPL servers (and clients). I’ve been working on it since the end of September and proof 0.2 came out a couple of days ago, so I guess it’s high time I told you a bit about it.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">neorepl 0.5: CIDER in a Terminal</title><link href="https://metaredux.com/posts/2026/11/05/neorepl-0-5.html" rel="alternate" type="text/html" title="neorepl 0.5: CIDER in a Terminal" /><published>2026-11-05T15:34:00+00:00</published><updated>2026-11-05T15:34:00+00:00</updated><id>https://metaredux.com/posts/2026/11/05/neorepl-0-5</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/05/neorepl-0-5.html"><![CDATA[<p><a href="https://github.com/nrepl/neorepl/releases/tag/v0.5.0">neorepl 0.5</a> is out!
When I <a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">announced neorepl</a>
last month, I wrote that I’d always wanted a terminal REPL that felt like
CIDER, without the Emacs part. A few releases later I think neorepl is mostly
there, so this one went out with “CIDER in a terminal” for a tagline. It also
has everything from the “What’s next” list in the <a href="/posts/2026/10/30/neorepl-0-4.html">0.4 post</a>,
which almost never happens with my plans.</p>

<!--more-->

<h2 id="a-line-editor-that-knows-clojure">A line editor that knows Clojure</h2>

<p><img src="/assets/images/neorepl-editing.gif" alt="Editing in neorepl" /></p>

<p>That’s where you spend most of your time in a REPL, so that’s where most of
the work went:</p>

<ul>
  <li>The arglists of the function you’re calling show up under the input, the
way eldoc shows them in CIDER, with the parameter the argument at the
cursor goes into in bold, and the arities that can’t take that many
arguments faint. Macros get matched by their shape, so the docstring of a
<code class="language-plaintext highlighter-rouge">defn</code> lines up with <code class="language-plaintext highlighter-rouge">doc-string?</code>. The lookups happen in the background
now, so typing never waits on the server.</li>
  <li>Enter in an unfinished form starts a line indented the way cljfmt would
indent it.</li>
  <li>The delimiter that pairs with the one at the cursor gets highlighted, and
a closer that pairs with nothing, or with the wrong kind, shows up in red.
JLine’s own idea of paren matching was to move the cursor to the opener for
half a second, which always made me think I’d pressed the wrong key.</li>
  <li>C-x Enter evaluates only the form at the cursor and gives you your input
back, which is great for checking a piece of a bigger expression without
retyping it. And after an evaluation the prompt shows at its right whether
it worked, and how long it took. I borrowed both ideas from
<a href="https://github.com/clojure/clojure-cli.repl">clojure-cli.repl</a>, and I’m
not sorry at all.</li>
  <li>C-x C-e opens what you’ve typed in your <code class="language-plaintext highlighter-rouge">$EDITOR</code>, as it does in bash, for
when a form outgrows the line editor.</li>
  <li><code class="language-plaintext highlighter-rouge">set editing-mode vi</code> in <code class="language-plaintext highlighter-rouge">~/.inputrc</code> gets you vi’s keys. neorepl takes
the readline settings JLine knows from there, and what’s under
<code class="language-plaintext highlighter-rouge">$if neorepl</code> is for neorepl alone.</li>
  <li>Commands get highlighted as you type them, and a command that doesn’t
exist shows up in red before you press Enter.</li>
</ul>

<p>Not everyone likes that much going on around the cursor, so <code class="language-plaintext highlighter-rouge">,set</code> lists
the REPL’s settings and turns them on and off, C-x C-h, C-x C-p and C-x C-q
toggle eldoc, pretty printing and quiet mode, and
<code class="language-plaintext highlighter-rouge">~/.config/neorepl/config.edn</code> says what they start as:</p>

<div class="language-clojure highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="p">{</span><span class="no">:eldoc</span><span class="w"> </span><span class="n">false</span><span class="w">
 </span><span class="no">:print-length</span><span class="w"> </span><span class="mi">100</span><span class="w">
 </span><span class="no">:autoreload</span><span class="w"> </span><span class="n">true</span><span class="p">}</span><span class="w">
</span></code></pre></div></div>

<h2 id="finding-your-way-around">Finding your way around</h2>

<p><img src="/assets/images/neorepl-browse.gif" alt="Browsing namespaces and specs" /></p>

<p><code class="language-plaintext highlighter-rouge">,ns</code> without a name opens a full-screen browser of the project’s
namespaces, or every loaded one after you press <code class="language-plaintext highlighter-rouge">a</code>. Type <code class="language-plaintext highlighter-rouge">/</code> and part of a
name to narrow them down, → to see a namespace’s public vars with their
docs, Enter to switch to it and <code class="language-plaintext highlighter-rouge">e</code> to open it in your editor. <code class="language-plaintext highlighter-rouge">,spec</code> does
the same for the spec registry: a spec’s form, the specs it names one key
away, and <code class="language-plaintext highlighter-rouge">x</code> for an example generated from it, as long as test.check is on
the server’s classpath. (With cider-nrepl, <code class="language-plaintext highlighter-rouge">x</code> only works since
<a href="https://github.com/nrepl/neorepl/releases/tag/v0.5.1">0.5.1</a>, which came
out today as well. I found that bug recording the GIF above.)</p>

<p><code class="language-plaintext highlighter-rouge">,refs</code> lists the functions that use a var, and <code class="language-plaintext highlighter-rouge">,deps</code> the ones a function
uses, courtesy of cider-nrepl’s <code class="language-plaintext highlighter-rouge">fn-refs</code> and <code class="language-plaintext highlighter-rouge">fn-deps</code>. They come in handy
before you change a function’s arguments, and even more so for coding
agents, which get them as <code class="language-plaintext highlighter-rouge">neorepl refs</code> and the MCP <code class="language-plaintext highlighter-rouge">refs</code> tool. They only
look through the project’s code that’s loaded, mind you.</p>

<h2 id="reloading-and-friends">Reloading and friends</h2>

<p><img src="/assets/images/neorepl-reload.gif" alt="Reloading what changed" /></p>

<p><code class="language-plaintext highlighter-rouge">,autoreload</code> has the REPL reload the namespaces whose files changed before
each evaluation, and before <code class="language-plaintext highlighter-rouge">,test</code>, <code class="language-plaintext highlighter-rouge">,inspect</code> and <code class="language-plaintext highlighter-rouge">,ns</code>, so you’re never
calling yesterday’s version of a function. It’s
<a href="https://github.com/tonsky/clj-reload">clj-reload</a> under cider-nrepl, which
reloads the namespaces that depend on the changed ones too, in the right
order, and keeps what <code class="language-plaintext highlighter-rouge">defonce</code> defined. When a reload fails you get its
error, rather than an evaluation against half-reloaded code.</p>

<p>Coding agents need this even more than people do, as they edit files all
day long and forget to load them about as often. <code class="language-plaintext highlighter-rouge">neorepl eval --reload</code> and
the <code class="language-plaintext highlighter-rouge">reload</code> option of the MCP <code class="language-plaintext highlighter-rouge">eval</code> tool take care of that.</p>

<p><img src="/assets/images/neorepl-profile.gif" alt="Taps and profiling" /></p>

<p>A few more things CIDER users will recognize:</p>

<ul>
  <li>Values sent to <code class="language-plaintext highlighter-rouge">tap&gt;</code> show up above the prompt, and <code class="language-plaintext highlighter-rouge">,tap</code> opens the last
one in the inspector, with cider-nrepl 0.64 or newer.</li>
  <li>What the server’s own threads print, like a web server’s handlers, shows
up above the prompt as well, instead of getting lost in the server’s
terminal, with nREPL 1.5 or newer and babashka.</li>
  <li><code class="language-plaintext highlighter-rouge">,profile</code> times every call of the functions you name, or of a whole
namespace, and without a name shows what it measured: how many calls each
function had, and how long they took, on average, in all, at the shortest
and the longest. <code class="language-plaintext highlighter-rouge">neorepl profile</code> does the same from the shell.</li>
</ul>

<h2 id="beside-your-editor">Beside your editor</h2>

<p>The CLI was meant for scripts from day one, and it turns out an editor
doesn’t need a plugin to use it. <code class="language-plaintext highlighter-rouge">neorepl eval -f FILE --line N:COL -</code>
evaluates the top-level form at the cursor in the file’s namespace, with
the buffer’s text on standard input, so unsaved changes count too, and
<code class="language-plaintext highlighter-rouge">neorepl eval --ns NS -</code> does the same for a selection.
<a href="https://helix-editor.com">Helix</a> can’t send a buffer to a command, so there
the keys save the file first, and that’s all it takes:</p>

<div class="language-toml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nn">[keys.normal."+"]</span>
<span class="py">e</span> <span class="p">=</span> <span class="p">[</span><span class="s">":write"</span><span class="p">,</span> <span class="s">":sh neorepl eval -s editor -f %{buffer_name} --line %{cursor_line}:%{cursor_column}"</span><span class="p">]</span>
<span class="py">l</span> <span class="p">=</span> <span class="p">[</span><span class="s">":write"</span><span class="p">,</span> <span class="s">":sh neorepl load %{buffer_name}"</span><span class="p">]</span>
</code></pre></div></div>

<p><a href="https://github.com/nrepl/neorepl/blob/main/doc/editors.md">doc/editors.md</a>
has complete setups for Neovim, Emacs and Helix. (Yes, Emacs. Please don’t
tell anyone.) The REPL sees whatever the editor evaluates, as they share a
server, so with the REPL in a split next to your editor you get a pretty
decent setup out of a few lines of config. The setups evaluate in a session
of their own, called <code class="language-plaintext highlighter-rouge">editor</code>, so <code class="language-plaintext highlighter-rouge">,sessions editor</code> takes the REPL there,
and <code class="language-plaintext highlighter-rouge">,pst</code> shows the last error your editor ran into.</p>

<h2 id="more-servers-tested-for-real">More servers, tested for real</h2>

<p>neorepl’s tests run against fakes that behave like cider-nrepl, which says
nothing about the next cider-nrepl, or the next babashka. So now CI also
runs neorepl against the real thing: nREPL with cider-nrepl, started by the
Clojure CLI and by Leiningen, babashka’s server, ClojureScript on Node
through piggieback and through shadow-cljs, nbb and Basilisp. That turned
up a fair share of bugs on both sides of the wire. Running a ClojureScript
namespace’s tests through piggieback failed with a circular dependency, a
ClojureScript test’s error came with the line <code class="language-plaintext highlighter-rouge">NaN</code>, code that threw on nbb
didn’t fail <code class="language-plaintext highlighter-rouge">neorepl eval</code>, and <code class="language-plaintext highlighter-rouge">source</code>, <code class="language-plaintext highlighter-rouge">macroexpand</code> and <code class="language-plaintext highlighter-rouge">apropos</code> didn’t
work on Basilisp. All fixed now.</p>

<p>neorepl needs babashka 1.13.227 or newer these days, as that’s the first
release with all the JLine and socket classes it used to work around.</p>

<h2 id="making-the-neighbours-better-round-three">Making the neighbours better, round three</h2>

<ul>
  <li>I filed a bunch of issues for nbb’s nREPL server, about errors, sessions
sharing state and <code class="language-plaintext highlighter-rouge">in-ns</code>, and Michiel fixed them within a day or two.
They’ll be in the next nbb release. Thanks again, Michiel! On the
babashka side, the test output going to the wrong message and <code class="language-plaintext highlighter-rouge">info</code>
knowing nothing about namespaces are fixed on master.</li>
  <li>Building on cider-nrepl’s profiler and taps turned up a few rough edges
in its ops for them, all filed by now.</li>
  <li>The nREPL fixes I wrote about last time are merged and waiting for the
next nREPL release, and I found a few more ways for an interrupted
evaluation to leave a session in a bad state. Interrupts are hard.</li>
  <li>The piggieback changes are still in review. No news there, I’m afraid.</li>
</ul>

<h2 id="whats-next">What’s next</h2>

<p>0.6 is about getting neorepl to more people:</p>

<ul>
  <li>neorepl on Clojars, which also lets you install it as a Clojure tool and
run it inside your project’s JVM, plus an uberjar and Homebrew</li>
  <li>proper Windows support, at long last</li>
  <li>a documentation site, as the README is getting rather long</li>
  <li>the frames of ClojureScript errors, from the JavaScript stack, which have
been “next” since 0.2</li>
</ul>

<p>After that comes 1.0, where the CLI’s exit codes, its edn and JSON output and
the MCP tools become a contract I promise to keep.</p>

<h2 id="try-it">Try it</h2>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>bbin <span class="nb">install </span>io.github.nrepl/neorepl
<span class="nv">$ </span><span class="nb">cd </span>my-project
<span class="nv">$ </span>neorepl
</code></pre></div></div>

<p>The <a href="https://github.com/nrepl/neorepl/blob/main/CHANGELOG.md">CHANGELOG</a> has
everything I skipped here, and the <a href="https://github.com/nrepl/neorepl">README</a>
has the details. Please keep the issues and ideas coming!</p>

<p>Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="neorepl" /><summary type="html"><![CDATA[neorepl 0.5 is out! When I announced neorepl last month, I wrote that I’d always wanted a terminal REPL that felt like CIDER, without the Emacs part. A few releases later I think neorepl is mostly there, so this one went out with “CIDER in a terminal” for a tagline. It also has everything from the “What’s next” list in the 0.4 post, which almost never happens with my plans.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">nREPL, Right in Your Browser</title><link href="https://metaredux.com/posts/2026/11/01/nrepl-right-in-your-browser.html" rel="alternate" type="text/html" title="nREPL, Right in Your Browser" /><published>2026-11-01T09:06:00+00:00</published><updated>2026-11-01T09:06:00+00:00</updated><id>https://metaredux.com/posts/2026/11/01/nrepl-right-in-your-browser</id><content type="html" xml:base="https://metaredux.com/posts/2026/11/01/nrepl-right-in-your-browser.html"><![CDATA[<p>Last week <a href="https://nrepl.org">nrepl.org</a> got a makeover. The docs moved to
<a href="https://docs.nrepl.org">docs.nrepl.org</a>, and nrepl.org itself became a
landing page that explains what nREPL is and how its protocol works, with
“wire windows” showing real exchanges between a client and a server, as EDN or
as the bencode that actually goes over the wire. Reading about a protocol only
gets you so far, though, so the page now also has a <a href="https://nrepl.org/#try">“Try it”
section</a> with a real nREPL server running right in
your browser. There’s one in this post as well! In the rest of it I’ll tell
you how it came about, why it was harder than it looks, and how you can use
the server behind it for your own projects.</p>

<!--more-->

<p>Here it is:</p>

<!-- A REPL talking to nrepl-sci (https://github.com/nrepl/nrepl-sci), an
     nREPL server that runs in Web Workers. The worker takes the bencode of
     each request and posts back the bencode of each reply, so everything
     below the markup is a small nREPL client. -->
<div class="nrepl-demo" data-worker="/assets/js/nrepl-sci-worker-0.1.0.js">
  <div class="nrepl-demo-log" aria-live="polite"></div>
  <form class="nrepl-demo-input">
    <label for="nrepl-demo-code">user=&gt;</label>
    <input id="nrepl-demo-code" type="text" placeholder="(+ 1 2)" spellcheck="false" autocomplete="off" autocapitalize="off" data-1p-ignore="" data-lpignore="true" data-bwignore="" />
  </form>
  <div class="nrepl-demo-bar">
    <button type="button" data-code="(+ 1 2)">(+ 1 2)</button>
    <button type="button" data-code="(println &quot;Hello from nREPL!&quot;)">(println "Hello from nREPL!")</button>
    <button type="button" data-code="(map inc (range 10))">(map inc (range 10))</button>
    <button type="button" data-code="(doc map)">(doc map)</button>
    <button type="button" data-code="(range)">(range)</button>
    <button type="button" class="nrepl-demo-interrupt" hidden="">interrupt</button>
    <label class="nrepl-demo-wire"><input type="checkbox" /> show the messages</label>
  </div>
</div>
<style>
  .nrepl-demo { margin: 0 0 15px; border: 1px solid #e8e8e8; border-radius: 3px; background: #eef; font: 14px/1.5 Menlo, Monaco, Consolas, monospace; }
  .nrepl-demo-log { max-height: 20em; overflow: auto; padding: 8px 12px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
  .nrepl-demo-log:empty { display: none; }
  .nrepl-demo-log .input { color: #828282; }
  .nrepl-demo-log .value { color: #1a7f37; }
  .nrepl-demo-log .err { color: #c62828; }
  .nrepl-demo-log .wire { color: #6a737d; font-size: 12px; }
  .nrepl-demo-input { display: flex; gap: 8px; padding: 8px 12px; }
  .nrepl-demo-input input { flex: 1; min-width: 0; padding: 0; border: 0; outline: none; background: none; font: inherit; }
  .nrepl-demo-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 8px 12px; border-top: 1px solid #e8e8e8; }
  .nrepl-demo-bar button { padding: 1px 8px; border: 1px solid #ccc; border-radius: 3px; background: #fff; font: 12px Menlo, Monaco, Consolas, monospace; cursor: pointer; }
  .nrepl-demo-bar .nrepl-demo-interrupt { border-color: #c62828; color: #c62828; }
  .nrepl-demo-wire { margin-left: auto; font-size: 12px; color: #6a737d; }
</style>

<script>
(() => {
  const demo = document.querySelector(".nrepl-demo");
  const log = demo.querySelector(".nrepl-demo-log");
  const input = demo.querySelector("#nrepl-demo-code");
  const prompt = demo.querySelector("label[for]");
  const interruptButton = demo.querySelector(".nrepl-demo-interrupt");
  const showWire = demo.querySelector(".nrepl-demo-wire input");
  const encoder = new TextEncoder();
  const decoder = new TextDecoder();

  // nREPL's messages go over the wire as bencode: dictionaries of strings,
  // integers and lists.
  const encode = (x) =>
    typeof x === "number" ? `i${x}e`
    : typeof x === "string" ? `${encoder.encode(x).length}:${x}`
    : Array.isArray(x) ? `l${x.map(encode).join("")}e`
    : `d${Object.keys(x).sort().map((k) => encode(k) + encode(x[k])).join("")}e`;

  function decode(bytes) {
    let i = 0;
    const next = () => {
      const c = bytes[i];
      if (c === 0x69) { // i42e
        const end = bytes.indexOf(0x65, i);
        const n = Number(decoder.decode(bytes.subarray(i + 1, end)));
        i = end + 1;
        return n;
      }
      if (c === 0x6c || c === 0x64) { // l...e and d...e
        i++;
        const items = [];
        while (bytes[i] !== 0x65) items.push(next());
        i++;
        if (c === 0x6c) return items;
        const dict = {};
        for (let k = 0; k < items.length; k += 2) dict[items[k]] = items[k + 1];
        return dict;
      }
      const colon = bytes.indexOf(0x3a, i); // 5:hello
      const start = colon + 1;
      i = start + Number(decoder.decode(bytes.subarray(i, colon)));
      return decoder.decode(bytes.subarray(start, i));
    };
    return next();
  }

  // The messages, shown as EDN
  const edn = (x) =>
    Array.isArray(x) ? `[${x.map(edn).join(" ")}]`
    : typeof x === "object" ? `{${Object.entries(x).map(([k, v]) => `:${k} ${edn(v)}`).join(", ")}}`
    : typeof x === "string" ? JSON.stringify(x)
    : String(x);

  let scrolling = false;
  function print(kind, text) {
    const line = document.createElement("div");
    line.className = kind;
    line.textContent = text.replace(/\n$/, "");
    log.append(line);
    while (log.childElementCount > 500) log.firstElementChild.remove();
    if (!scrolling) {
      scrolling = true;
      requestAnimationFrame(() => { scrolling = false; log.scrollTop = log.scrollHeight; });
    }
  }

  let worker = null;
  let started = null;
  let session = null;
  let nextId = 0;
  let ns = "user";
  let running = null;
  const handlers = {};

  // Sends a request, calling `handle` with each of its replies.
  function send(msg, handle) {
    msg.id = String(++nextId);
    if (session) msg.session = session;
    if (handle) handlers[msg.id] = handle;
    if (showWire.checked) print("wire", `→ ${edn(msg)}`);
    worker.postMessage(encoder.encode(encode(msg)));
    return msg.id;
  }

  function receive(event) {
    const msg = decode(event.data);
    if (showWire.checked) print("wire", `← ${edn(msg)}`);
    const handle = handlers[msg.id];
    if (msg.status?.includes("done")) delete handlers[msg.id];
    if (handle) handle(msg);
  }

  // The server starts the first time it's needed, with a session of our own.
  function start() {
    started ??= new Promise((resolve) => {
      worker = new Worker(demo.dataset.worker);
      worker.onmessage = receive;
      worker.onerror = () => print("err", "The server didn't start.");
      send({ op: "clone" }, (msg) => resolve(session = msg["new-session"]));
    });
    return started;
  }

  async function evaluate(code) {
    if (running) return;
    running = true;
    print("input", `${ns}=> ${code}`);
    await start();
    running = send({ op: "eval", code }, (msg) => {
      if (msg.out) print("out", msg.out);
      if (msg.err) print("err", msg.err);
      if ("value" in msg) print("value", msg.value);
      if (msg.ns) prompt.textContent = `${ns = msg.ns}=>`;
      if (msg.status?.includes("done")) running = null;
      interruptButton.hidden = !running;
    });
    interruptButton.hidden = false;
  }

  demo.querySelector("form").addEventListener("submit", (event) => {
    event.preventDefault();
    if (running || !input.value.trim()) return;
    evaluate(input.value.trim());
    input.value = "";
  });
  demo.querySelectorAll("[data-code]").forEach((button) =>
    button.addEventListener("click", () => evaluate(button.dataset.code)));
  interruptButton.addEventListener("click", () =>
    send({ op: "interrupt", "interrupt-id": running }));
  input.addEventListener("focus", start);
})();
</script>

<p>Go ahead, evaluate something! Tick “show the messages” to see the requests
and the responses going back and forth, and try <code class="language-plaintext highlighter-rouge">(range)</code> if you’re curious
what happens to code that never finishes.</p>

<h2 id="picking-an-approach">Picking an approach</h2>

<p>An interactive nREPL playground always runs into the same problem: you need
an nREPL server somewhere, and a server that evaluates code from random people
on the internet is just about the worst thing you can host. (It would also
cost money that I’d rather spend on something else.) So the server had to run
in the browser, and I looked at a few ways to get there.</p>

<p>The first one was the real thing. <a href="https://cheerpj.com">CheerpJ</a> is a JVM
that runs in the browser, and nREPL 1.8 and Clojure 1.12 worked on it
remarkably well. Every op I tried worked, <code class="language-plaintext highlighter-rouge">stdin</code> included! The
problem was everything around that - about 8 seconds to a ready server on a
fast machine, about 4.5MB to download, a busy loop that freezes the whole page
unless you put the JVM in a Web Worker, and an <code class="language-plaintext highlighter-rouge">interrupt</code> that works only on
code that’s sleeping.<sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup> That’s a lot to ask of someone who just opened a
landing page.</p>

<p>The second one was <a href="https://github.com/babashka/scittle">scittle</a>, which runs
<a href="https://github.com/babashka/sci">SCI</a> (Michiel Borkent’s Clojure interpreter)
in the browser and comes with an nREPL server,
<a href="https://github.com/babashka/sci.nrepl">sci.nrepl</a>. It solves a different
problem, though - it lets your editor evaluate code in a page, through a relay
that runs in babashka or on the JVM, and its replies differ from nREPL’s in
quite a few places. (I’ve filed <a href="https://github.com/babashka/sci.nrepl/issues">some
issues</a> about those.)
<a href="https://github.com/babashka/nbb">nbb</a> has a pretty complete nREPL server of
its own, but it runs only on Node.</p>

<p>None of those fit, so I ended up writing a small nREPL server for SCI that
runs entirely in a web page, with the page as its client -
<a href="https://github.com/nrepl/nrepl-sci">nrepl-sci</a>. SCI does all the heavy
lifting, and evaluation, completion and docs lookup took just a few hundred
lines of ClojureScript. The whole thing is about 230KB gzipped and it’s ready
in a fraction of a second. Not bad, right?</p>

<h2 id="the-hard-part">The hard part</h2>

<p>A basic nREPL server is easy enough. The trouble starts with two ops most
people never think about - <code class="language-plaintext highlighter-rouge">interrupt</code> and <code class="language-plaintext highlighter-rouge">stdin</code>.</p>

<p>JavaScript gives you one thread, and SCI evaluates code in one go. While
<code class="language-plaintext highlighter-rouge">(loop [] (recur))</code> runs nothing else does, so the server can’t even read the
<code class="language-plaintext highlighter-rouge">interrupt</code> request that would stop it, and code calling <code class="language-plaintext highlighter-rouge">read-line</code> can’t
wait for input without blocking the very thread that would receive it. There’s
a third problem hiding in there as well. nREPL sessions are supposed to be
independent, so an eval in one session (say, your editor’s) shouldn’t hold up
another one (say, a test runner connected to the same server).</p>

<p>Here’s how nrepl-sci deals with all of that:</p>

<ul>
  <li>The server runs in two Web Workers. A supervisor takes the requests, queues
them, and answers <code class="language-plaintext highlighter-rouge">interrupt</code> and <code class="language-plaintext highlighter-rouge">stdin</code> itself, while an evaluator runs
SCI.</li>
  <li>The two share some memory (a <code class="language-plaintext highlighter-rouge">SharedArrayBuffer</code>) that serves as a
mailbox. The evaluator waits for mail with <code class="language-plaintext highlighter-rouge">Atomics.wait</code>, which blocks a
worker without spinning, so <code class="language-plaintext highlighter-rouge">read-line</code> waits for its input there, much like
it would on the JVM.</li>
  <li>SCI calls a hook of your choice on every function call and every <code class="language-plaintext highlighter-rouge">recur</code>.
nrepl-sci uses it to check its mailbox, to see if it’s been interrupted, or
if there’s a request from another session it could take in between. Checking
on every call made code noticeably slower, so it checks on every 256th call,
which still means every few microseconds. Benchmarks run about as fast as
without any of this.</li>
  <li>Endless seqs like <code class="language-plaintext highlighter-rouge">(range)</code> and <code class="language-plaintext highlighter-rouge">(iterate inc 0)</code> check as they go, so
<code class="language-plaintext highlighter-rouge">(count (range))</code> stops when you interrupt it.</li>
  <li>Some code never calls back into SCI - a regex that backtracks forever, for
instance. The supervisor gives it a second to stop, then kills the evaluator
and starts a new one. Your sessions survive that, but everything you
evaluated in them is gone.</li>
</ul>

<p>In the end the supervisor, the evaluator and the mailbox took more code than
the nREPL server itself, which tells you something about where the
complexity is.</p>

<p><strong>Note:</strong> All of this works only when the page is <a href="https://web.dev/articles/cross-origin-isolation-guide">cross-origin
isolated</a>, as browsers
hand out <code class="language-plaintext highlighter-rouge">SharedArrayBuffer</code> only to pages served with the
<code class="language-plaintext highlighter-rouge">Cross-Origin-Opener-Policy</code> and <code class="language-plaintext highlighter-rouge">Cross-Origin-Embedder-Policy</code> headers.</p>

<p>Sadly, GitHub Pages, which hosts both nrepl.org and this blog, can’t send
those. Without them nrepl-sci falls back to doing one thing at a time:
<code class="language-plaintext highlighter-rouge">read-line</code> throws, and interrupting code means starting over, which is exactly
what you saw if you tried <code class="language-plaintext highlighter-rouge">(range)</code> above. Evaluation, output, errors,
completion and <code class="language-plaintext highlighter-rouge">doc</code> work the same either way, though.</p>

<h2 id="testing-with-proof">Testing with proof</h2>

<p>Back in 2023 I listed the lack of a protocol compatibility test suite among
the <a href="/posts/2023/03/26/bad-nrepl.html">things people hate about nREPL</a>,
and asked if one of you was looking for a fun small OSS project. Eventually I
took my own advice and started <a href="https://github.com/nrepl/proof">proof</a>, and
nrepl-sci is the first server I’ve written with proof around from day one. It
made a huge difference! Building an nREPL server used to involve a lot of
guessing, as the protocol is small, but what clients actually expect from a
server is spread across their source code.</p>

<p>A proof profile is a short TOML file that tells proof how to start your server
and how to say a few things in its language: a value, some output, an
exception, reading a line, code that runs until it’s stopped. <code class="language-plaintext highlighter-rouge">proof run</code>
takes it from there, with checks covering the protocol and the exact requests
CIDER, Calva, Conjure, vim-fireplace, REPLy and neorepl send. When a check
fails, proof also tells you why it matters:</p>

<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>FAIL   robust.sessions-at-once      An eval in one session doesn't hold up the others
       clone request got no reply with "done" within 10s
       why: Each client has sessions of its own (e.g. an editor and neorepl,
       connected to the same server), so a server that runs one eval at a time
       leaves every other client waiting for whatever the code in one of them
       does.
</code></pre></div></div>

<p>That’s a check you can easily shrug off when you’re writing a server for a
playground, and it’s the reason nrepl-sci takes requests in between at all.
Working on the server mostly came down to running <code class="language-plaintext highlighter-rouge">make proof</code> after every
change. Today nrepl-sci passes all 73 checks that apply to it (the other 5 are
about things like vim-fireplace, which needs Java). Without shared memory it
fails exactly two: <code class="language-plaintext highlighter-rouge">stdin.need-input</code> and <code class="language-plaintext highlighter-rouge">robust.sessions-at-once</code>. I guess
that’s a pretty good summary of what you give up without cross-origin
isolation.</p>

<p>If you’re working on an nREPL server of your own, I can’t recommend proof
enough. It also comes with a GitHub Action, so your CI can run it as well.</p>

<h2 id="the-tradeoffs">The tradeoffs</h2>

<p>Nothing comes for free, and nrepl-sci is no exception:</p>

<ul>
  <li>It’s SCI, not Clojure. You’re getting ClojureScript as interpreted by SCI,
so there are no Java classes, no JVM libraries, and some corners of the
language behave differently. That’s fine for a playground, but not for
anything that needs your real project.</li>
  <li>There’s no JavaScript interop. SCI blocks it unless you allow it, and
nrepl-sci doesn’t, so <code class="language-plaintext highlighter-rouge">(js/alert "hi")</code> and even <code class="language-plaintext highlighter-rouge">(.toUpperCase "hi")</code> fail.
Admittedly, that’s a bit annoying, but it’s also what makes nrepl-sci safe
to embed anywhere, as the code people type can’t touch the page, or even the
worker it runs in. (<code class="language-plaintext highlighter-rouge">clojure.string/upper-case</code> works just fine.)</li>
  <li>A request from another session runs on top of the code it interrupted, so
that code can’t stop until the request is done, and a <code class="language-plaintext highlighter-rouge">read-line</code> taken in
between holds it until it gets its input. You’d need two clients fighting
over the same server to notice.</li>
  <li>Starting over loses your definitions, which matters most without
cross-origin isolation, where every interrupt starts over.</li>
  <li>It’s about 1MB of JavaScript (230KB gzipped), loaded the first time you use
the REPL. That’s nothing compared to CheerpJ, but it’s not free either.</li>
</ul>

<h2 id="using-nrepl-sci-yourself">Using nrepl-sci yourself</h2>

<p>nrepl-sci was built for nrepl.org, but nothing in it is specific to the site.</p>

<p>You can embed a REPL in a page - documentation, a tutorial, a blog post. The
worker takes the bencode of each request as a <code class="language-plaintext highlighter-rouge">Uint8Array</code> and posts back the
bencode of each reply, so the whole integration boils down to something like
this:</p>

<div class="language-js highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="kd">const</span> <span class="nx">worker</span> <span class="o">=</span> <span class="k">new</span> <span class="nx">Worker</span><span class="p">(</span><span class="dl">"</span><span class="s2">/assets/js/nrepl-sci-worker-0.1.0.js</span><span class="dl">"</span><span class="p">);</span>
<span class="nx">worker</span><span class="p">.</span><span class="nx">onmessage</span> <span class="o">=</span> <span class="p">(</span><span class="nx">event</span><span class="p">)</span> <span class="o">=&gt;</span> <span class="nx">console</span><span class="p">.</span><span class="nx">log</span><span class="p">(</span><span class="nx">decode</span><span class="p">(</span><span class="nx">event</span><span class="p">.</span><span class="nx">data</span><span class="p">));</span>
<span class="nx">worker</span><span class="p">.</span><span class="nx">postMessage</span><span class="p">(</span><span class="k">new</span> <span class="nx">TextEncoder</span><span class="p">().</span><span class="nx">encode</span><span class="p">(</span><span class="nx">encode</span><span class="p">({</span> <span class="na">op</span><span class="p">:</span> <span class="dl">"</span><span class="s2">eval</span><span class="dl">"</span><span class="p">,</span> <span class="na">code</span><span class="p">:</span> <span class="dl">"</span><span class="s2">(+ 1 2)</span><span class="dl">"</span><span class="p">,</span> <span class="na">id</span><span class="p">:</span> <span class="dl">"</span><span class="s2">1</span><span class="dl">"</span> <span class="p">})));</span>
</code></pre></div></div>

<p><code class="language-plaintext highlighter-rouge">encode</code> and <code class="language-plaintext highlighter-rouge">decode</code> are a few dozen lines of bencode, and the REPL in this
post is about 170 lines in total, styles included - <a href="https://github.com/bbatsov/metaredux/blob/master/_includes/nrepl-sci-demo.html">have a
look</a>.
Grab <code class="language-plaintext highlighter-rouge">nrepl-sci-worker.js</code> from the <a href="https://github.com/nrepl/nrepl-sci/releases/latest">latest
release</a> and serve it from
your own site, as browsers start workers only from the page’s own origin. If
you can send the cross-origin isolation headers, you get <code class="language-plaintext highlighter-rouge">stdin</code> and proper
interrupts for free. nrepl.org’s
<a href="https://github.com/nrepl/nrepl.org/blob/master/assets/js/playground.js">playground</a>
is a bigger example, with completion, history and the wire windows.</p>

<p>You can also test nREPL clients without a JVM. The Node build is a regular
nREPL server on a socket (<code class="language-plaintext highlighter-rouge">node nrepl-sci.js --port 7888</code>) that’s up in about
a tenth of a second, which makes it handy for the test suites of clients and
editor plugins.</p>

<p>Finally, if you’re after an nREPL server for some other language that runs on
a single thread, the supervisor and the mailbox might give you a few ideas.
The server itself knows nothing about threads or sockets, and the trick with
the mailbox works for any interpreter that can call back now and then while
it runs.</p>

<h2 id="whats-next">What’s next</h2>

<p>The obvious next step is getting cross-origin isolation on nrepl.org. A
service worker can add the headers GitHub Pages won’t send, at the cost of a
reload when it’s first installed, so I might try that on a page of its own.
I’d also like to allow some harmless interop, so that <code class="language-plaintext highlighter-rouge">(.toUpperCase "hi")</code>
works as people expect, and to publish nrepl-sci on npm.</p>

<h2 id="epilogue">Epilogue</h2>

<p>Back in 2018 I wrote that there was <a href="/posts/2018/10/29/nrepl-redux.html">“the big dream to port nREPL to
ClojureScript”</a>, so it could be used in
self-hosted environments, and in 2023 I was still hoping we’d see more native
ClojureScript nREPL servers. nrepl-sci isn’t quite that dream - it’s a much
smaller nREPL server for SCI - but it’s a step in that direction.</p>

<p>Big thanks to Michiel Borkent for SCI, which did most of the hard work here.
None of this would exist without it! And, as usual, special thanks to
<a href="https://www.clojuriststogether.org/">Clojurists Together</a> for supporting my
work on nREPL!</p>

<p>That’s all I have for you today. Play with the REPL, try to break it, and let
me know how it went! Keep hacking!</p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>CheerpJ’s free tier also covers only non-commercial open-source projects that load it from Leaning Technologies’ CDN. That would have been fine for nrepl.org, but it’s one more string attached. <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="nrepl-sci" /><summary type="html"><![CDATA[Last week nrepl.org got a makeover. The docs moved to docs.nrepl.org, and nrepl.org itself became a landing page that explains what nREPL is and how its protocol works, with “wire windows” showing real exchanges between a client and a server, as EDN or as the bencode that actually goes over the wire. Reading about a protocol only gets you so far, though, so the page now also has a “Try it” section with a real nREPL server running right in your browser. There’s one in this post as well! In the rest of it I’ll tell you how it came about, why it was harder than it looks, and how you can use the server behind it for your own projects.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">neorepl 0.4: Tests, Inspector, Tracing and Agents</title><link href="https://metaredux.com/posts/2026/10/30/neorepl-0-4.html" rel="alternate" type="text/html" title="neorepl 0.4: Tests, Inspector, Tracing and Agents" /><published>2026-10-30T12:30:00+00:00</published><updated>2026-10-30T12:30:00+00:00</updated><id>https://metaredux.com/posts/2026/10/30/neorepl-0-4</id><content type="html" xml:base="https://metaredux.com/posts/2026/10/30/neorepl-0-4.html"><![CDATA[<p><a href="https://github.com/nrepl/neorepl/releases/tag/v0.4.0">neorepl 0.4</a> came out
last week, and since I never got around to writing about 0.2 and 0.3, it
feels like a good moment to look back at what happened since the <a href="/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html">original
announcement</a>.
Three releases in two weeks, and neorepl now has most of what I listed under
“What’s next” back then - a test runner, a full-screen inspector and
stacktrace browser, an MCP server and a skill for coding agents - plus a few
things that weren’t on the list at all, like tracing and peeking into your
coding agent’s REPL session.</p>

<!--more-->

<h2 id="running-tests">Running tests</h2>

<p><img src="/assets/images/neorepl-tests.gif" alt="Running tests in neorepl" /></p>

<p><code class="language-plaintext highlighter-rouge">,test</code> in the REPL, or <code class="language-plaintext highlighter-rouge">neorepl test</code> in your shell, runs the tests in the
namespaces you name, the tests you name or, without either, the whole
project’s. Failures come with their file and line, and errors with a stack
trace that stops at the test that hit them, instead of wandering off into
<code class="language-plaintext highlighter-rouge">clojure.test</code>’s guts. <code class="language-plaintext highlighter-rouge">,retest</code> (<code class="language-plaintext highlighter-rouge">neorepl retest</code>) reruns only what didn’t
pass, which is exactly what you want while you’re fixing things.</p>

<p>As usual, the server does the heavy lifting. cider-nrepl runs the tests when
it’s around, and so does babashka’s nREPL server, which bundles CIDER’s test
ops these days. Without either, neorepl falls back to plain <code class="language-plaintext highlighter-rouge">clojure.test</code>,
as long as you tell it which namespaces to test. And in a ClojureScript
session the same commands run your ClojureScript tests.</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>neorepl <span class="nb">test</span>
<span class="nv">$ </span>neorepl <span class="nb">test </span>my.app-test my.app.db-test
<span class="nv">$ </span>neorepl <span class="nb">test</span> <span class="nt">--format</span> json my.app-test/start-test
</code></pre></div></div>

<h2 id="stack-traces-and-the-inspector">Stack traces and the inspector</h2>

<p><code class="language-plaintext highlighter-rouge">,stacktrace</code> shows the last error full-screen. Pick a frame, press Enter,
and its source opens in your <code class="language-plaintext highlighter-rouge">$EDITOR</code> at that line (as a copy, for code in a
jar), and when you quit the editor you’re back where you were. By default you
see only the frames that matter, and <code class="language-plaintext highlighter-rouge">a</code> brings back the rest - the REPL’s own
machinery and the repeated frames of the same function. With cider-nrepl, <code class="language-plaintext highlighter-rouge">i</code>
inspects the cause you’re looking at and <code class="language-plaintext highlighter-rouge">d</code> its ex-data. After a test run
with errors, <code class="language-plaintext highlighter-rouge">,stacktrace</code> shows those, each under the test it came from.
(You can see that at the end of the GIF above.)</p>

<p><code class="language-plaintext highlighter-rouge">,inspect</code> puts cider-nrepl’s inspector (babashka has one too) in full-screen:</p>

<p><img src="/assets/images/neorepl-inspect.gif" alt="The neorepl inspector" /></p>

<p>The arrow keys (or <code class="language-plaintext highlighter-rouge">j</code> and <code class="language-plaintext highlighter-rouge">k</code>) move around, Enter digs into a value and
Backspace goes back up, <code class="language-plaintext highlighter-rouge">[</code> and <code class="language-plaintext highlighter-rouge">]</code> page through big collections, <code class="language-plaintext highlighter-rouge">v</code> shows
an object’s fields, <code class="language-plaintext highlighter-rouge">P</code> toggles pretty printing and <code class="language-plaintext highlighter-rouge">g</code> refreshes values that
change, like an atom’s. The handiest one is <code class="language-plaintext highlighter-rouge">d</code>, which defines whatever
you’re looking at as a var. Dig five levels deep into some big API response, press
<code class="language-plaintext highlighter-rouge">d</code>, give it a name, and you can play with that piece in the REPL right away.</p>

<p><code class="language-plaintext highlighter-rouge">neorepl inspect</code> does the same one step at a time, for scripts and agents,
since the inspector keeps its state in the session:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>neorepl inspect <span class="s1">'(System/getProperties)'</span>
<span class="nv">$ </span>neorepl inspect <span class="nt">--push</span> 3
<span class="nv">$ </span>neorepl inspect <span class="nt">--def</span> props
</code></pre></div></div>

<h2 id="tracing">Tracing</h2>

<p><img src="/assets/images/neorepl-trace.gif" alt="Tracing in neorepl" /></p>

<p><code class="language-plaintext highlighter-rouge">,trace</code> traces a function, or every function in a namespace, and from then
on each call shows its arguments and what it returned, nested in the calls
it’s part of. It’s often the quickest way to see what some code is actually
doing, and there are no <code class="language-plaintext highlighter-rouge">println</code>s to forget to remove afterwards. Calls on
other threads, like an HTTP handler’s or a future’s, show up above the prompt
too. <code class="language-plaintext highlighter-rouge">,trace</code> without arguments lists what’s traced and <code class="language-plaintext highlighter-rouge">,untrace</code> stops
tracing. Scripts and agents get <code class="language-plaintext highlighter-rouge">neorepl trace</code>, with the calls showing up in
the output of the <code class="language-plaintext highlighter-rouge">neorepl eval</code> that made them. Tracing needs cider-nrepl
on the server.</p>

<p>(Fun fact: tracing a function that the tracing itself calls, like
<code class="language-plaintext highlighter-rouge">clojure.core/map</code>, used to take the whole server down. neorepl refuses to
trace those, and as of orchard 0.48 the server no longer falls over on them
anyway.)</p>

<h2 id="coding-agents">Coding agents</h2>

<p>0.3 was all about coding agents. The CLI was usable by agents from day one,
but now they get a lot more help:</p>

<ul>
  <li>
    <p><code class="language-plaintext highlighter-rouge">neorepl mcp</code> serves neorepl’s features as MCP tools over stdio, for agents
that would rather call tools than run commands. With Claude Code it’s a
one-liner:</p>

    <div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>claude mcp add neorepl <span class="nt">--</span> neorepl mcp
</code></pre></div>    </div>

    <p>The tools are <code class="language-plaintext highlighter-rouge">eval</code>, <code class="language-plaintext highlighter-rouge">load</code>, <code class="language-plaintext highlighter-rouge">doc</code>, <code class="language-plaintext highlighter-rouge">source</code>, <code class="language-plaintext highlighter-rouge">where</code>, <code class="language-plaintext highlighter-rouge">apropos</code>,
<code class="language-plaintext highlighter-rouge">macroexpand</code>, <code class="language-plaintext highlighter-rouge">reload</code>, <code class="language-plaintext highlighter-rouge">test</code>, <code class="language-plaintext highlighter-rouge">retest</code>, <code class="language-plaintext highlighter-rouge">pst</code>, <code class="language-plaintext highlighter-rouge">interrupt</code>, <code class="language-plaintext highlighter-rouge">check</code> and
<code class="language-plaintext highlighter-rouge">ports</code>. That’s fewer than the CLI’s commands on purpose: an agent pays for
every tool’s description in its context on every turn, whether it uses the
tool or not. Evaluations get cut at 10,000 characters and interrupted after
60 seconds by default, so a stray <code class="language-plaintext highlighter-rouge">(range)</code> or an infinite loop can’t eat
the agent’s context or its session.</p>
  </li>
  <li>A <a href="https://github.com/nrepl/neorepl/blob/main/skills/neorepl/SKILL.md">skill</a>
teaches agents the workflow I’d like them to follow: after editing a file,
check its parens, load it, run its tests, and read the stack trace when
something fails. It costs nothing until the agent actually works on Clojure
code. <a href="https://github.com/nrepl/neorepl/blob/main/doc/agents.md">doc/agents.md</a>
explains how to set it up with Claude Code, Codex, Gemini CLI, Cursor and
VS Code.</li>
  <li>
    <p><code class="language-plaintext highlighter-rouge">neorepl check --fix</code> repairs unbalanced delimiters the way parinfer’s
indent mode would, trusting the indentation over the parens. Mismatched
parens are still the most common way for an agent to break a Clojure file,
and now fixing them doesn’t take another trip through the model:</p>

    <div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>neorepl check src/demo/orders.clj
src/demo/orders.clj:3:1: Unclosed <span class="o">(</span>
<span class="nv">$ </span>neorepl check <span class="nt">--fix</span> src/demo/orders.clj
src/demo/orders.clj:3:1: Unclosed <span class="o">(</span>, repaired from the indentation
</code></pre></div>    </div>
  </li>
</ul>

<p>The CLI and the MCP tools share named sessions, the one called <code class="language-plaintext highlighter-rouge">agent</code> unless
told otherwise, which brings me to my favourite addition in 0.4.</p>

<h2 id="looking-over-your-agents-shoulder">Looking over your agent’s shoulder</h2>

<p><img src="/assets/images/neorepl-sessions.gif" alt="Stepping into an agent's session" /></p>

<p><code class="language-plaintext highlighter-rouge">,sessions</code> lists the server’s named sessions, and <code class="language-plaintext highlighter-rouge">,sessions agent</code> steps
into the agent’s, with its name in the prompt. Everything the agent left
behind is right there: its namespace, its <code class="language-plaintext highlighter-rouge">*1</code>, its <code class="language-plaintext highlighter-rouge">*e</code>. So when an agent
tells you that a test fails with a <code class="language-plaintext highlighter-rouge">NullPointerException</code>, you can look at
the exception yourself instead of asking it to paste the stack trace.
<code class="language-plaintext highlighter-rouge">,sessions -</code> takes you back to your own session.</p>

<p>The lookups take <code class="language-plaintext highlighter-rouge">--session</code> too, so <code class="language-plaintext highlighter-rouge">neorepl doc --session agent foo</code> looks
up <code class="language-plaintext highlighter-rouge">foo</code> the way that session sees it, in its namespace and its language,
ClojureScript included.</p>

<h2 id="the-repl-round-two">The REPL, round two</h2>

<p>0.4 also spent a lot of time on the REPL itself:</p>

<ul>
  <li><code class="language-plaintext highlighter-rouge">,ns</code> switches namespaces, loading the one you name if it isn’t loaded
yet, and lists the project’s namespaces when you don’t name one.</li>
  <li>C-x C-s shows the source of the symbol at the cursor and C-x C-a the vars
whose names contain it, next to the C-x C-d for docs that was there from
the start. All three come from rebel-readline.</li>
  <li><code class="language-plaintext highlighter-rouge">,doc</code> and the arglists that show up as you type cover Java classes,
methods and fields too, with their Javadoc as text (that one needs
cider-nrepl).</li>
  <li><code class="language-plaintext highlighter-rouge">,edit</code> and the stacktrace browser open definitions that live in jars,
instead of telling you they can’t.</li>
  <li>Ctrl-C got a lot more reliable. An interrupt sent right after an
evaluation could get lost when the server hadn’t started running it yet,
the forms after an interrupted one ran anyway, and whatever an interrupted
evaluation printed later could show up in the next one’s output. All fixed.</li>
  <li>neorepl sends the forms you enter to the server one at a time now, which
is a big part of the interrupt fixes, and as a bonus piggieback evaluates
all of them, not only the first.</li>
  <li>On Linux, every evaluation used to wait 40ms on the server’s socket,
courtesy of TCP’s delayed ACKs. neorepl turns those off now, on the JVM
and on babashka 1.13.227 or newer, and evaluating a file with 100 forms
went from 4.5 seconds to about 150ms.</li>
  <li>Lots of error messages got friendlier: a build tool that isn’t installed,
a server that dies while starting, loading a file with unbalanced parens, a
named session the server lost when it restarted, and so on.</li>
</ul>

<p>So much for keeping neorepl small, by the way - the code has about doubled
since 0.1. In my defense, it does a lot more than twice as much.</p>

<h2 id="making-the-neighbours-better-round-two">Making the neighbours better, round two</h2>

<p>Just like last time, building neorepl turned up problems elsewhere, and a
good part of these two weeks went into fixing them at the source:</p>

<ul>
  <li>I filed a batch of issues for babashka’s nREPL server: test runs that hung
or killed the session, <code class="language-plaintext highlighter-rouge">:project?</code> being ignored, a session that never
answered again after its client disconnected, a couple of JLine classes
neorepl’s line editor needed. Michiel fixed every single one of them within
days, and they’re all in babashka 1.13.227. Thanks, Michiel!</li>
  <li>cider-nrepl 0.64 and orchard 0.48 came out this week with fixes for the
problems I ran into: what tests print now comes back with the test results
(it used to go to the connection of the session’s previous message, which
for a CLI is long gone), the test op no longer goes silent for a namespace
that isn’t loaded or runs every test when the one you asked for doesn’t
exist, ClojureScript tests run on shadow-cljs, a traced call that throws
shows up as such, and Javadoc no longer comes with stray spaces in it.
CIDER gets all of that too, which is my favourite kind of side effect.
<a href="https://github.com/nrepl/neorepl/releases/tag/v0.4.1">neorepl 0.4.1</a>,
out the day after this post, uses cider-nrepl 0.64 when it starts a server.</li>
  <li>In nREPL, the fix for an interrupted evaluation’s last response going to
the wrong connection is merged, and so is <code class="language-plaintext highlighter-rouge">TCP_NODELAY</code> on the server’s
sockets, which takes 100 evaluations with nREPL’s own client from 4.4
seconds to 90ms on Linux. Both will be in the next nREPL release.</li>
  <li>The piggieback improvements I mentioned last time are a bit behind
schedule. A lot of ClojureScript REPLs run on top of piggieback, so a
mistake there has a pretty big blast radius, and evaluating every form of a
message is something we never found a good way to do in the past. I’d
rather take my time with those than rush them out. neorepl isn’t waiting on
them, at least, since it sends the forms one at a time now.</li>
</ul>

<h2 id="whats-next">What’s next</h2>

<p>0.5 is about more runtimes and better navigation:</p>

<ul>
  <li>integration tests against real servers in CI: cider-nrepl and babashka
first, then shadow-cljs and piggieback with Node</li>
  <li>nbb and Basilisp in CI, with their gaps documented</li>
  <li>cross-references (<code class="language-plaintext highlighter-rouge">,refs</code>), on top of cider-nrepl’s <code class="language-plaintext highlighter-rouge">fn-refs</code> and
<code class="language-plaintext highlighter-rouge">fn-deps</code></li>
  <li>a full-screen namespace browser</li>
  <li>a couple of ideas borrowed from clojure-cli.repl: evaluating the form at the
cursor, and the last evaluation’s outcome and time in the prompt</li>
  <li>indenting continuation lines, and a way to pick the vi keymap</li>
</ul>

<p>Better Windows support, the one item from the 0.1 list that’s still open, is
planned for 0.6, together with easier ways to install neorepl.</p>

<h2 id="try-it">Try it</h2>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>bbin <span class="nb">install </span>io.github.nrepl/neorepl
<span class="nv">$ </span><span class="nb">cd </span>my-project
<span class="nv">$ </span>neorepl
</code></pre></div></div>

<p>The <a href="https://github.com/nrepl/neorepl/blob/main/CHANGELOG.md">CHANGELOG</a> has
everything I skipped here, and the <a href="https://github.com/nrepl/neorepl">README</a>
has the details. Please keep the issues and ideas coming!</p>

<p>Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="neorepl" /><summary type="html"><![CDATA[neorepl 0.4 came out last week, and since I never got around to writing about 0.2 and 0.3, it feels like a good moment to look back at what happened since the original announcement. Three releases in two weeks, and neorepl now has most of what I listed under “What’s next” back then - a test runner, a full-screen inspector and stacktrace browser, an MCP server and a skill for coding agents - plus a few things that weren’t on the list at all, like tracing and peeking into your coding agent’s REPL session.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">neorepl: A Terminal REPL for Clojure (and Friends)</title><link href="https://metaredux.com/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html" rel="alternate" type="text/html" title="neorepl: A Terminal REPL for Clojure (and Friends)" /><published>2026-10-10T09:38:00+00:00</published><updated>2026-10-10T09:38:00+00:00</updated><id>https://metaredux.com/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends</id><content type="html" xml:base="https://metaredux.com/posts/2026/10/10/neorepl-a-terminal-repl-for-clojure-and-friends.html"><![CDATA[<p>For more than a decade the Clojure REPL most people saw in a terminal was
<a href="https://github.com/trptcolin/reply">REPLy</a>, the one behind <code class="language-plaintext highlighter-rouge">lein repl</code>. It
served us well, but it’s showing its age, and I kept wishing for a terminal
REPL that felt like CIDER, without the Emacs part. So I finally built one.
<a href="https://github.com/nrepl/neorepl">neorepl</a> 0.1 is out today!</p>

<!--more-->

<h2 id="why-another-repl">Why another REPL?</h2>

<p>There’s no shortage of Clojure REPLs, so it’s fair to ask. Here’s what I was
after:</p>

<ul>
  <li>nREPL all the way down. neorepl only speaks nREPL, so it works with anything
that runs an nREPL server: Clojure, babashka, shadow-cljs, Basilisp,
ClojureCLR and so on. The smarts live on the server. When cider-nrepl is
there neorepl uses it, the same way CIDER does, and when it isn’t it falls
back to nREPL’s built-in ops, and then to evaluating a bit of code.</li>
  <li>A REPL that’s pleasant to use: a proper line editor, highlighting,
completion, arglists as you type, pretty printing, history per project and
a Ctrl-C that actually interrupts the evaluation.</li>
  <li>A CLI that’s just as good for scripts and coding agents. Every lookup the
REPL can do is also a command, with structured output and exit codes that
mean something.</li>
  <li>Something small and modern. Clojure 1.10+, nREPL and JLine 4 are the only
dependencies, and the same code runs on the JVM and on babashka. The whole
thing is about 3,300 lines right now, and I’d like to keep it that way.</li>
</ul>

<p><code class="language-plaintext highlighter-rouge">rebel-readline</code> and <code class="language-plaintext highlighter-rouge">bb repl --connect</code> are both great, and I borrowed from
them freely, but neither tries to be an nREPL-first tool with CIDER’s tooling,
jack-in and a CLI for agents. That combination is the whole point of neorepl.</p>

<p><strong>Update (2026-10-11):</strong> A few people asked how neorepl relates to the
<a href="https://github.com/clojure/clojure-cli.repl">Clojure CLI REPL</a>, which the
Clojure team released a couple of weeks ago, and to <code class="language-plaintext highlighter-rouge">bb repl --connect</code>. (I’m a
bit embarrassed to admit I hadn’t heard of the former until after I announced
neorepl.) Funny enough, all three are nREPL clients under the hood, but they’re
after pretty different things. In practical terms:</p>

<ul>
  <li>The Clojure CLI REPL runs only on the JVM and needs Clojure 1.12+. It ships
its own nREPL server, and its docs and data inspector are ops of that server,
so against any other server you can only evaluate code. It’s deps.edn only.
Its editing is really nice, though - structural editing, evaluating the form
at the cursor and a <code class="language-plaintext highlighter-rouge">datafy</code>-based inspector - and I’ll be borrowing some
ideas from it. It doesn’t do completion yet.</li>
  <li><code class="language-plaintext highlighter-rouge">bb repl --connect</code> puts babashka’s console REPL in front of any nREPL server,
with completion, arglists and docs, in very little code. It’s a great way to
poke at a running server, but it won’t start one for you.</li>
  <li>neorepl works with any nREPL server and gets the most out of the ones with
cider-nrepl (or babashka’s take on it), without any middleware of its own.
It starts a server for Leiningen, deps.edn, babashka and shadow-cljs projects,
follows you into ClojureScript, and everything the REPL does is also a
command with JSON output for scripts and agents. No structural editing yet,
however.</li>
</ul>

<p>So, if you want the fanciest line editing and you live in deps.edn land, give
the Clojure CLI REPL a try. If you want CIDER in your terminal, for you and
for your agents, that’s what neorepl is for. The neat part is that babashka’s
server bundles CIDER’s inspector and test runner ops these days, so neorepl’s
test runner (already on <code class="language-plaintext highlighter-rouge">main</code>) and the inspector that’s coming next work with
babashka out of the box.</p>

<h2 id="for-humans">For humans</h2>

<p>Here’s the REPL in action:</p>

<p><img src="/assets/images/neorepl-repl.gif" alt="The neorepl REPL" /></p>

<p>A few things worth pointing out:</p>

<ul>
  <li>Enter only submits the input once its forms are complete, so pasting a whole
function just works.</li>
  <li>TAB completes, with the candidates’ types next to them, and the arglist of
the function you’re calling shows up after the cursor.</li>
  <li>Values get pretty printed on the server and highlighted on the client.</li>
  <li>Commands start with a comma, the CIDER way: <code class="language-plaintext highlighter-rouge">,doc</code>, <code class="language-plaintext highlighter-rouge">,source</code>, <code class="language-plaintext highlighter-rouge">,apropos</code>,
<code class="language-plaintext highlighter-rouge">,macroexpand</code>, <code class="language-plaintext highlighter-rouge">,pst</code>, <code class="language-plaintext highlighter-rouge">,reload</code>, <code class="language-plaintext highlighter-rouge">,edit</code> (which opens a definition in your
<code class="language-plaintext highlighter-rouge">$EDITOR</code>) and <code class="language-plaintext highlighter-rouge">,help</code> for the rest. The Clojure reader sees a comma as
whitespace, so they can’t clash with real code.</li>
  <li>Ctrl-C interrupts what’s running, and code that reads <code class="language-plaintext highlighter-rouge">*in*</code> gets its input,
something REPLy never quite got right.</li>
</ul>

<p>Without a server to connect to, <code class="language-plaintext highlighter-rouge">neorepl</code> starts one for the project, the way
CIDER’s jack-in does, with cider-nrepl on the classpath, and stops it when you
exit. It knows Leiningen, the Clojure CLI, babashka and shadow-cljs projects.</p>

<p>ClojureScript works too. Start a ClojureScript REPL in the session (through
shadow-cljs or piggieback, which jack-in adds for you) and neorepl follows
along: evaluation, completion, docs and the rest switch to ClojureScript, and
<code class="language-plaintext highlighter-rouge">:cljs/quit</code> takes you back.</p>

<h2 id="for-agents">For agents</h2>

<p>Coding agents are surprisingly good at Clojure, as long as they have a REPL
to talk to. Most of them drive CLIs much better than anything else, so neorepl
has a CLI that’s meant to be driven:</p>

<p><img src="/assets/images/neorepl-agent.gif" alt="neorepl's CLI" /></p>

<ul>
  <li><code class="language-plaintext highlighter-rouge">neorepl eval</code> evaluates code on the project’s server. Calls share a
session, so <code class="language-plaintext highlighter-rouge">*ns*</code>, <code class="language-plaintext highlighter-rouge">*1</code> and <code class="language-plaintext highlighter-rouge">*e</code> carry over from one call to the next, and
<code class="language-plaintext highlighter-rouge">--session</code> keeps separate lines of work apart.</li>
  <li><code class="language-plaintext highlighter-rouge">--format json</code> (or <code class="language-plaintext highlighter-rouge">edn</code>) gives you the values, the output and the
namespace as data.</li>
  <li><code class="language-plaintext highlighter-rouge">--timeout</code> interrupts the evaluation before giving up, so an infinite loop
doesn’t take the server down with it, and <code class="language-plaintext highlighter-rouge">--max-output</code> keeps a stray
<code class="language-plaintext highlighter-rouge">(range)</code> from eating the agent’s context.</li>
  <li><code class="language-plaintext highlighter-rouge">neorepl check</code> finds unbalanced parens, brackets and braces without a
server. That’s the most common way for an agent (or a human) to break a
Clojure file.</li>
  <li><code class="language-plaintext highlighter-rouge">neorepl doc</code>, <code class="language-plaintext highlighter-rouge">source</code>, <code class="language-plaintext highlighter-rouge">apropos</code>, <code class="language-plaintext highlighter-rouge">complete</code>, <code class="language-plaintext highlighter-rouge">where</code>, <code class="language-plaintext highlighter-rouge">macroexpand</code> and
<code class="language-plaintext highlighter-rouge">reload</code> do what the REPL’s commands do.</li>
  <li><code class="language-plaintext highlighter-rouge">neorepl server</code> starts a server that stays up, for editors, agents and
<code class="language-plaintext highlighter-rouge">neorepl eval</code> to share.</li>
</ul>

<p>The exit codes are boring on purpose: 0 when all went well, 1 for an
evaluation error, 3 when there’s no server to talk to and 124 for a timeout
(like <code class="language-plaintext highlighter-rouge">timeout(1)</code>).</p>

<h2 id="playing-nicely-with-nrepl">Playing nicely with nREPL</h2>

<p>A new client is also a new way to break servers, or to be broken by them, and
the nREPL world has quite a few servers these days. Fortunately I’ve been
working on <a href="https://github.com/nrepl/proof">proof</a>, a compatibility suite for
nREPL, which made neorepl a good test subject.</p>

<p>proof checks both sides of the conversation. <code class="language-plaintext highlighter-rouge">proof proxy</code> sits between a
client and a server and grades everything the client sends: every request has
an id, <code class="language-plaintext highlighter-rouge">need-input</code> gets answered with <code class="language-plaintext highlighter-rouge">stdin</code> in the right session, and so on.
<code class="language-plaintext highlighter-rouge">proof serve</code> is a small nREPL server that can behave like other servers in
very specific ways - sending only the last value of the code like Basilisp and
jank, dropping stderr, having no <code class="language-plaintext highlighter-rouge">interrupt</code> op, splitting output into one
message per character, and so on. I ran neorepl’s REPL and CLI through both,
against nREPL, babashka, Basilisp and jank, and through every quirk <code class="language-plaintext highlighter-rouge">proof
serve</code> knows about.</p>

<p>neorepl came out of it in decent shape, but not unscathed:</p>

<ul>
  <li>Code read from stdin (<code class="language-plaintext highlighter-rouge">neorepl eval -</code>) that then read <code class="language-plaintext highlighter-rouge">*in*</code> itself crashed
neorepl and left the evaluation waiting on the server for input that was
never coming.</li>
  <li>neorepl’s errors could leave the shell’s prompt dangling at the end of a
line with servers that don’t end their error reports with a newline (hello,
jank!).</li>
  <li><code class="language-plaintext highlighter-rouge">neorepl eval</code> exited with 1 when it lost the server, which is the status
for code that failed.</li>
</ul>

<p>All of those are fixed in 0.1. It also turned up a couple of things that are
nREPL’s fault rather than neorepl’s: <code class="language-plaintext highlighter-rouge">need-input</code> and the end of an
interrupted evaluation can go to the wrong connection when a session is used
from more than one. Those will be fixed in nREPL itself.</p>

<p>It works the other way around too. proof now checks servers with the exact
requests neorepl sends while starting its REPL and evaluating code, next to
the ones CIDER, Calva, Conjure, vim-fireplace and REPLy send, so a server that
breaks neorepl finds out from proof, not from a bug report. nREPL, babashka,
Basilisp and jank all pass those checks today.</p>

<h2 id="making-the-neighbours-better">Making the neighbours better</h2>

<p>Building neorepl turned up a few problems elsewhere, which is one of my
favourite side effects of writing a new client. piggieback used to evaluate
only the first form you sent it and silently drop the rest, and it loaded the
ClojureScript compiler at startup even when nobody asked for a ClojureScript
REPL, which added almost half a second to the startup of every server with
ClojureScript on the classpath. The fixes for both
(<a href="https://github.com/nrepl/piggieback/pull/162">piggieback#162</a> and
<a href="https://github.com/nrepl/piggieback/pull/161">piggieback#161</a>) will be in the
next piggieback release. The Node.js
REPL in ClojureScript itself doesn’t cope well with interrupted evaluations,
and that one is next on my list.</p>

<h2 id="whats-next">What’s next</h2>

<p>0.1 is the foundation. Here’s what I’d like to tackle next:</p>

<ul>
  <li>a test runner with proper reports</li>
  <li>a full-screen inspector and stacktrace browser</li>
  <li>an MCP server and a ready-made skill for coding agents</li>
  <li>better Windows support</li>
</ul>

<h2 id="try-it">Try it</h2>

<p>The easiest way to install neorepl is <a href="https://github.com/babashka/bbin">bbin</a>:</p>

<div class="language-shell highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nv">$ </span>bbin <span class="nb">install </span>io.github.nrepl/neorepl
<span class="nv">$ </span><span class="nb">cd </span>my-project
<span class="nv">$ </span>neorepl
</code></pre></div></div>

<p>The <a href="https://github.com/nrepl/neorepl">README</a> has the details.</p>

<p>It’s early days, so I’m sure you’ll find rough edges. Please file issues,
and tell me what you’d like to see next. And if you’re one of the people who
kept <code class="language-plaintext highlighter-rouge">lein repl</code> and REPLy going over the years - thank you! neorepl wouldn’t
exist without you.</p>

<p>Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Clojure" /><category term="nREPL" /><category term="neorepl" /><summary type="html"><![CDATA[For more than a decade the Clojure REPL most people saw in a terminal was REPLy, the one behind lein repl. It served us well, but it’s showing its age, and I kept wishing for a terminal REPL that felt like CIDER, without the Emacs part. So I finally built one. neorepl 0.1 is out today!]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry><entry><title type="html">RuboCop 1.92: Agents Welcome</title><link href="https://metaredux.com/posts/2026/10/10/rubocop-1-92.html" rel="alternate" type="text/html" title="RuboCop 1.92: Agents Welcome" /><published>2026-10-10T09:30:00+00:00</published><updated>2026-10-10T09:30:00+00:00</updated><id>https://metaredux.com/posts/2026/10/10/rubocop-1-92</id><content type="html" xml:base="https://metaredux.com/posts/2026/10/10/rubocop-1-92.html"><![CDATA[<p><a href="https://github.com/rubocop/rubocop/releases/tag/v1.92.0">RuboCop 1.92</a> is out! Last time I talked about the long road to 2.0. This
time the theme is more down to earth, and probably closer to how a lot of you use
RuboCop today - AI coding agents.</p>

<p>These days plenty of RuboCop runs aren’t started by a person at all. Claude Code,
Codex, Cursor and friends run it after every batch of edits, read whatever it prints
and try to fix what it found. That’s a very different user from the one RuboCop was
built for. An agent has endless patience, but everything RuboCop prints ends up in its
context window, and it can’t glance at a terminal and tell what’s obviously noise. So
I spent most of this cycle making RuboCop a better citizen in that world.</p>

<!--more-->

<h2 id="output-an-agent-can-act-on">Output an agent can act on</h2>

<p><code class="language-plaintext highlighter-rouge">--format json</code> now tells you exactly what autocorrection would do with each offense.
Every correctable offense carries the edits, and whether a plain <code class="language-plaintext highlighter-rouge">rubocop -a</code> would
apply them:</p>

<div class="language-json highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nl">"correction"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w">
  </span><span class="nl">"safe"</span><span class="p">:</span><span class="w"> </span><span class="kc">true</span><span class="p">,</span><span class="w">
  </span><span class="nl">"edits"</span><span class="p">:</span><span class="w"> </span><span class="p">[</span><span class="w">
    </span><span class="p">{</span><span class="w">
      </span><span class="nl">"start_line"</span><span class="p">:</span><span class="w"> </span><span class="mi">1</span><span class="p">,</span><span class="w">
      </span><span class="nl">"start_column"</span><span class="p">:</span><span class="w"> </span><span class="mi">6</span><span class="p">,</span><span class="w">
      </span><span class="nl">"last_line"</span><span class="p">:</span><span class="w"> </span><span class="mi">1</span><span class="p">,</span><span class="w">
      </span><span class="nl">"last_column"</span><span class="p">:</span><span class="w"> </span><span class="mi">12</span><span class="p">,</span><span class="w">
      </span><span class="nl">"begin_pos"</span><span class="p">:</span><span class="w"> </span><span class="mi">5</span><span class="p">,</span><span class="w">
      </span><span class="nl">"end_pos"</span><span class="p">:</span><span class="w"> </span><span class="mi">12</span><span class="p">,</span><span class="w">
      </span><span class="nl">"replacement"</span><span class="p">:</span><span class="w"> </span><span class="s2">"'hello'"</span><span class="w">
    </span><span class="p">}</span><span class="w">
  </span><span class="p">]</span><span class="w">
</span><span class="p">}</span><span class="w">
</span></code></pre></div></div>

<p>A cop that crashes on a file is now listed with that file’s results, instead of only
on stderr, where nothing that parses JSON ever looks. (And the <code class="language-plaintext highlighter-rouge">--parallel</code> notice no
longer goes to stdout, where it used to break the JSON output. Oops.)</p>

<p>There are also a few new options aimed squarely at agents (humans are welcome to use
them too):</p>

<ul>
  <li><code class="language-plaintext highlighter-rouge">--max-offenses-per-cop=N</code> caps how many offenses each cop reports. A legacy
codebase can easily have thousands of <code class="language-plaintext highlighter-rouge">Style/StringLiterals</code> offenses, and an agent
doesn’t need to read all of them to get the idea.</li>
  <li><code class="language-plaintext highlighter-rouge">--explain COP</code> prints what a cop checks, its good and bad examples, its
configuration as your project resolves it, and whether it autocorrects. Offense
messages are terse by design, and often that’s not enough to fix the code the way
the cop actually wants.</li>
  <li><code class="language-plaintext highlighter-rouge">--show-cops</code> and <code class="language-plaintext highlighter-rouge">--show-docs-url</code> now complain about cop names they don’t
recognize instead of silently ignoring them. Agents make up plausible-sounding cop
names more often than you’d think.</li>
</ul>

<h2 id="a-much-better-mcp-server">A much better MCP server</h2>

<p>Koichi added an experimental <a href="https://docs.rubocop.org/rubocop/usage/mcp.html">MCP server</a> back in RuboCop 1.85, and in this
release it got a serious overhaul:</p>

<ul>
  <li><code class="language-plaintext highlighter-rouge">rubocop_inspection</code> answers in the same shape as <code class="language-plaintext highlighter-rouge">--format json</code> instead of as LSP
diagnostics. LSP diagnostics are great for editors, but an agent had to wade through
0-based lines and quick fixes it had no use for, and the results were about twice as
big.</li>
  <li>A new <code class="language-plaintext highlighter-rouge">rubocop_explain</code> tool does what <code class="language-plaintext highlighter-rouge">--explain</code> does.</li>
  <li>Inspection and autocorrection take <code class="language-plaintext highlighter-rouge">only</code>, <code class="language-plaintext highlighter-rouge">except</code> and <code class="language-plaintext highlighter-rouge">changed</code>, so an agent can
check just the files it touched, or just <code class="language-plaintext highlighter-rouge">Lint</code>.</li>
  <li>Autocorrection can preview its changes as a diff, reports the offenses it couldn’t
fix, and leaves alone the files it has nothing to correct in.</li>
  <li>Cops with <code class="language-plaintext highlighter-rouge">AutoCorrect: contextual</code>, like <code class="language-plaintext highlighter-rouge">Lint/UselessAssignment</code>, are held back by
default, since the code is probably mid-edit. An agent that’s done editing can ask
for them with <code class="language-plaintext highlighter-rouge">contextual: true</code>.</li>
  <li>A cop crashing on one file no longer fails the entire request.</li>
</ul>

<p>The server is still marked experimental, but it’s in a much better place now. If
you’re using it with your agent of choice, I’d love to hear how it goes.</p>

<h2 id="agents-and-rubocopdisable">Agents and <code class="language-plaintext highlighter-rouge">rubocop:disable</code></h2>

<p>There’s a new <a href="https://docs.rubocop.org/rubocop/usage/ai_agents.html">AI Agents</a> page in the docs that covers all of the above,
plus a few lines you can drop into your <code class="language-plaintext highlighter-rouge">AGENTS.md</code> or <code class="language-plaintext highlighter-rouge">CLAUDE.md</code> so the agent knows
how your project wants RuboCop run.</p>

<p>It also deals with my favorite agent “fix” - the <code class="language-plaintext highlighter-rouge"># rubocop:disable</code> that makes the
offense go away. Banning directives outright is too blunt, since some offenses really
are better left alone, but you can make the agent explain itself:</p>

<div class="language-yaml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="na">Style/DisableCopsWithinSourceCodeDirective</span><span class="pi">:</span>
  <span class="na">Enabled</span><span class="pi">:</span> <span class="no">true</span>
  <span class="na">AllowWithReason</span><span class="pi">:</span> <span class="no">true</span>
</code></pre></div></div>

<p>Now every directive needs a <code class="language-plaintext highlighter-rouge">--</code> justification, and whoever reviews the change gets to
decide whether the reason holds up.</p>

<h2 id="sandboxes">Sandboxes</h2>

<p>More and more agents run in sandboxes that only allow access to the project
directory. Filesystem calls outside of it fail with <code class="language-plaintext highlighter-rouge">EPERM</code>, and RuboCop was mostly
prepared for <code class="language-plaintext highlighter-rouge">EACCES</code>, so a cache it couldn’t write to took the whole run down with
it. Now it just carries on without the cache. One more crash of that kind, in the
lookup of your target Ruby version, has a fix lined up for the next release.</p>

<h2 id="autocorrection-you-can-trust">Autocorrection you can trust</h2>

<p>This one isn’t specific to agents, but agents are the ones who suffer the most from
it. A person notices when <code class="language-plaintext highlighter-rouge">-a</code> produces garbage. An agent might happily build on top
of it. This release has a mountain of bug fixes, and most of them are about
autocorrection - dozens of infinite loops between cops, and an even longer list of
corrections that produced broken (or subtly different) code. Plenty of them came out
of a systematic audit of our autocorrections, and Koichi, <a href="https://github.com/viralpraxis">viralpraxis</a> and
<a href="https://github.com/Starlexxx">Starlexxx</a> fixed a staggering number of them.</p>

<h2 id="the-rest-of-the-release">The rest of the release</h2>

<ul>
  <li><code class="language-plaintext highlighter-rouge">Lint/UselessAssignment</code> now catches a variable that a block keeps assigning but
nothing ever reads.</li>
  <li><code class="language-plaintext highlighter-rouge">Security/JSONLoad</code> now reports <code class="language-plaintext highlighter-rouge">JSON.load(src, create_additions: false)</code>. Before
json 2.17 the option is ignored in that position, so the “safe” call wasn’t safe at
all. <code class="language-plaintext highlighter-rouge">JSON.load(src, nil, create_additions: false)</code> works everywhere.</li>
  <li><code class="language-plaintext highlighter-rouge">Style/NegativeArrayIndex</code> is now marked as unsafe.</li>
  <li><code class="language-plaintext highlighter-rouge">--changed</code>, <code class="language-plaintext highlighter-rouge">--diff</code> and the SARIF formatter, all new in 1.91, got a round of fixes.</li>
  <li>RuboCop no longer loads <code class="language-plaintext highlighter-rouge">net/http</code> on every run, only when it fetches a remote
config.</li>
  <li><code class="language-plaintext highlighter-rouge">regexp_parser</code> 2.11.3 or newer is now required.</li>
</ul>

<p>The <a href="https://github.com/rubocop/rubocop/releases/tag/v1.92.0">release notes</a> have the full list.</p>

<h2 id="epilogue">Epilogue</h2>

<p>Agents are already a big part of how RuboCop gets used, and I think we’re only getting
started on adapting to that. Next on my list is <code class="language-plaintext highlighter-rouge">--changed-lines</code>, so an agent (or a
person) can focus on the offenses in the lines it actually changed. If you’re running
RuboCop through an agent and something about it annoys you, <a href="https://github.com/rubocop/rubocop/issues">tell us</a>.</p>

<p>One more thing before I go - <a href="https://rubocop.org">rubocop.org</a> got completely reworked recently.
Most of what it shows now comes straight out of RuboCop itself, there’s an index of
every cop, and there’s a <a href="https://rubocop.org/playground/">playground</a> that runs RuboCop right in your
browser, courtesy of ruby.wasm. Go check it out and take the playground for a spin!
Feedback on the new design and features is most welcome - just
<a href="https://github.com/rubocop/rubocop.org/issues">open an issue</a> if something looks off or you’re missing something.</p>

<p>Big thanks to everyone who contributed to this release! Koichi, viralpraxis and
Starlexxx carried the bug-fixing once again, and <a href="https://github.com/bquorning">bquorning</a> reported the sandbox
crash that got me looking into the rest of them.</p>

<p>That’s all I have for you today. Keep hacking!</p>]]></content><author><name>Bozhidar Batsov</name></author><category term="posts" /><category term="Ruby" /><category term="RuboCop" /><summary type="html"><![CDATA[RuboCop 1.92 is out! Last time I talked about the long road to 2.0. This time the theme is more down to earth, and probably closer to how a lot of you use RuboCop today - AI coding agents. These days plenty of RuboCop runs aren’t started by a person at all. Claude Code, Codex, Cursor and friends run it after every batch of edits, read whatever it prints and try to fix what it found. That’s a very different user from the one RuboCop was built for. An agent has endless patience, but everything RuboCop prints ends up in its context window, and it can’t glance at a terminal and tell what’s obviously noise. So I spent most of this cycle making RuboCop a better citizen in that world.]]></summary><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://metaredux.com/assets/og-image.png" /><media:content medium="image" url="https://metaredux.com/assets/og-image.png" xmlns:media="http://search.yahoo.com/mrss/" /></entry></feed>