This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2023-08-27
Channels
- # announcements (1)
- # beginners (29)
- # biff (14)
- # calva (13)
- # cider (8)
- # clj-kondo (6)
- # cljdoc (8)
- # clojure (8)
- # clojure-europe (2)
- # clojurescript (2)
- # conjure (2)
- # emacs (45)
- # holy-lambda (8)
- # honeysql (5)
- # integrant (2)
- # jobs (2)
- # kaocha (1)
- # life (1)
- # malli (3)
- # missionary (30)
- # nrepl (3)
- # off-topic (26)
- # scittle (6)
- # sql (6)
- # tools-deps (8)
- # xtdb (3)
Hi.
I think I’ve found a problem with Kaocha’s watch functionality not respecting :lambdaisland.tools.namespace.repl/load
and lambdaisland.tools.namespace.repl/unload
metadata on namespaces — it unloads/loads namespaces regardless.
I’ve hacked a fix for this by adding a call of lambdaisland.tools.namespace.repl/remove-disabled
on the tracker in kaocha.watch/plugin
. It seems to work for me, and the tests pass, but I don’t think I’m familiar enough with the repo to submit a PR — for example I don’t know whether my change is the right way to do things or whether tests should be added. Also, lambdaisland.tools.namespace.repl/remove-disabled
is private, so that would probably need to be made public.
(See https://github.com/simon-katz/kaocha-with-nomis-hacks/commit/ca1602984338e779eb3db1e2f3e4bf9014b638e0?w=1 for my change.)
A couple of related points:
• No reloading happens if any paths in the watch-paths
function don’t exist. I’ve hacked a fix for this at https://github.com/simon-katz/kaocha-with-nomis-hacks/commit/69963e7ecb26b0137637db4e6ea698013998229a
• I wonder whether lambdaisland’s tools.namespace should respect clojure.tools.namespace.repl load/unload metadata. For a POC which works for my limited use case at least, see https://github.com/simon-katz/tools.namespace/commit/0df94efeec606ee1d97d1bbe63542842d9a28cab
I’m happy to create issues in GitHub if it’s agreed these are issues.