Q about using RELEASE and/or LATEST in :mvn/version with the CLI: I know that they're deprecated and not really recommended, although they can be convenient for dev tooling.
If I use clojure -Sdeps ... {:mvn/version "RELEASE"} ..., how often will the version actually be checked for/updated? I know RELEASE defeats the cache staleness check, since the "version" isn't changing, but does that completely prevent new versions being picked up, or does it just cause a lag as the actual release version is only checked for once a day or whatever?
it won't be checked
so it will never be updated
Okay, so picking up new versions would happen only when other deps got changed or -Sforce was used?
yes
Thanks. The context of this is a thread in #calva discussing the jack-in deps going stale.
RELEASE is just seen as another "version" by deps and doesn't cause staleness by itself
I think that's the useful thing to say
Fair.
for all Maven virtual versions (including SNAPSHOT)
if I was going to "fix" this, then that would be the generic approach I would take - virtual versions should become stale based on some policy (there is a per-repo one for snapshots, would need one for others)
but I think the flip side of this is needing to (slowly) run code to determine staleness more often, which would affect startup time. current staleness checks are local, needing only file timestamp checks from bash, which is fast
Yeah, I just use occasional clojure -Sforce invocations (although I've now moved away from using RELEASE in my dot-clojure repo).
hm i’m curious now whether it would be possible to improve startup time by reducing process spawning in bash
i might take a look at that at some point
the purpose of the current caching is to reduce process spawning (skip classpath computation when known) and improve perf time
I’ve been using RELEASE in my dot files too. I got it from @seancorfield’s examples. I didn’t realize it was deprecated! What’s the next best alternative if you want to be running “the current” thing? It seems like the cache having a TTL would make sense. Maybe something like 24 hours. One lookup per day.
I run clojure -Tantq outdated regularly 🙂
I used to think RELEASE was good for dev tools since you'd "always" get the most recent version (modulo the caching -- so when other deps in your project changed) but partly it felt weird having git deps which had to be tag/sha versions and other stuff being just "recent", combined with caching issues making RELEASE not update to important new versions a couple of times... so I switched away from it completely.
Yeah, have an “outdated” alias too. It seems like it should be a built in—especially since RELEASE is deprecated. Finding the latest version of something seems like a behavior that should be scope for a dependency resolver.
antq is one of my globally installed tools
Yeah. Me too.
https://github.com/seancorfield/dot-clojure/tree/develop/tools
Well, I should clarify. I have it set up as an alias and not as a tool. But I set it up globally.