lambdaisland

2024-02-28T23:51:03.155679Z

I have a deps.edn that have logback-classic and slf4j as dependencies but I had no logback.xml , so launchpad ran in debug mode, and I could see that it starts many watchers, including directories starting with . like .clj-kondo .idea .git . Is that desirable ?

plexus 2024-03-04T08:38:42.893129Z

So I do think this is actually expected, see this message:

DEBUG io.methvin.watcher.DirectoryWatcher - Assuming ExtendedWatchEventModifier.FILE_TREE is not supported
Linux does not support watching directories recursively, so the watcher lib we use sets up watchers for all subdirectories. We don't really need that, would be worth looking into how to turn that off for efficiency, but it's not a problem as such.

2024-03-04T09:06:56.002959Z

I think not entering node_modules would be good and dot directories would be good.

plexus 2024-03-07T09:08:49.725099Z

This is fundamentally the issue: https://github.com/gmethvin/directory-watcher/issues/54 . We use nextjournal.beholder for the watcher, which uses io.methvin/directory-watcher, which doesn't have a good mechanism for non-recursively watching directories.

plexus 2024-03-07T09:14:14.743919Z

So there probably are ways to solve this, the linked issue hints at a way to call specific methods through reflection, but that might mean opening up specific modules in a post java-9 world. Or we look at other watcher solutions, or implement something ourselves (so replicate what io.methvin/directory-watcher does). But doing it cross platform is a pain (which is why we use this lib), and it seems it's not actually solvable on mac os. So, this might be something that will only gets fixed if a community contribution comes through that fixes it.

2024-03-02T12:22:04.769109Z

@plexus was the output good evidence ?

plexus 2024-03-01T06:46:43.654019Z

That seems odd. Can you share a repro or at least copy the output?

2024-03-01T09:15:28.838839Z