sci

a13 2025-08-11T12:27:39.332899Z

Is it possible to use a namespaced symbol in :bindings?

borkdude 2025-08-11T12:31:42.854899Z

:bindings is actually a very old feature that just expands into

{:namespaces {'user bindings}}
so it just adds vars into the user namespace. Vars can't have qualified names but are qualified by their namespace. So this:
user=> (sci/eval-string "(foo/bar 1)" {:bindings {'foo/bar identity}})
Execution error (ExceptionInfo) at sci.impl.utils/throw-error-with-location (utils.cljc:45).
Could not resolve symbol: foo/bar
user=> (sci/eval-string "(foo/bar 1)" {:namespaces {'foo {'bar identity}}})
1

🙌 1
borkdude 2025-08-11T12:31:54.761899Z

So you can use the latter to accomplish what you want perhaps

a13 2025-08-11T12:34:11.586649Z

thanks