Skip to content

Add brepl nREPL client compatibility - #23

Merged
norbot7865 merged 1 commit into
masterfrom
norbot/issue-15-brepl-compat
Jul 15, 2026
Merged

norbot7865 merged 1 commit into
masterfrom
norbot/issue-15-brepl-compat

Conversation

@norbot7865

Copy link
Copy Markdown
Collaborator

Summary

Addresses the requested brepl validation from issue #15:

  • adds bounded Clojure-compatible music.core/load-file evaluation
  • runs loaded top-level forms sequentially inside the caller's existing serialized/session namespace context
  • limits editor-requested files to 16 MiB
  • adds raw nREPL coverage matching brepl's eval request containing (load-file "...")
  • documents actual brepl v2.7.1/Babashka v1.12.218 validation, port discovery behavior, and commands
  • links brepl from the README nREPL overview

Actual brepl validation

Against lgs repl --no-audio --nrepl 0:

  • .nrepl-port discovery: pass
  • brepl -e '(+ 1 2 3)': 6
  • stdout plus value response: hello-from-brepl, then 42
  • raw verbose describe: pass, expected operations returned
  • brepl -f out/brepl-controls.lg: pass; sequential defsynth, ctl, and ramp evaluated, returning the ramp handle
  • unknown function: structured let-go error and brepl exit code 2

The initial validation identified that brepl's -f uses eval of the load-file function rather than the standard nREPL load-file op; this PR closes that compatibility gap.

Automated validation

  • make test-nrepl
  • go test ./...
  • go test -race ./internal/lisp ./internal/nrepl

Refs #15.

@norbot7865
norbot7865 merged commit fca59fe into master Jul 15, 2026
4 checks passed
@norbot7865
norbot7865 deleted the norbot/issue-15-brepl-compat branch July 15, 2026 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant