This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-10-26
Channels
- # announcements (9)
- # babashka (98)
- # beginners (53)
- # boot (2)
- # calva (19)
- # cider (58)
- # clj-kondo (4)
- # cljdoc (11)
- # clojure (49)
- # clojure-dev (12)
- # clojure-nl (3)
- # clojure-uk (4)
- # clojurescript (42)
- # core-async (6)
- # cursive (9)
- # data-science (1)
- # fulcro (23)
- # jobs-discuss (2)
- # nrepl (30)
- # off-topic (42)
- # pedestal (6)
- # re-frame (8)
- # reitit (7)
- # remote-jobs (2)
- # shadow-cljs (134)
- # specter (1)
- # vim (13)
I'm having trouble getting the threeagent project to run ( https://github.com/DougHamil/threeagent )... I ran 'lein repl' in a terminal, cider-connect'ed from emacs, and when trying to evaluate
(ns threeagent.dev.core
(:require [threeagent.core :as th]
["three" :as three]))
in emacs, getting
Call to clojure.core/ns did not conform to spec:
thoughts?
are there additional steps I need to be taking?I don't know if I should be doing something with figwheel, too... didn't explicitely start that. I'm definitely guessing I've left out a bunch of steps to get this to run.
hmm... ok.
The only thing allowed there are symbols (which name namespaces) which is why you got that error telling you your call to the ns macro is malformed
ok, so maybe something that never worked in the original code ( https://github.com/DougHamil/threeagent/blob/master/src/dev/threeagent/core.cljs )
definitely in over my head but this is so cool I want to see it work!
It may be valid clojurescript(the cljs ext means clojurescript not clojure), but lein repl is a clojure reply, not a clojurescript repl
oookay... just realized I cloned the master branch (the default) and there is a 'release' branch...
stand by.
I doubt changing the branch will fix things if you are try to run clojurescript code in a clojure reply, they are different languages that only share a vaguely defined subset of syntax and semantics
ah ok just absorbed what you were saying...
although I use figwheel from a terminal launched repl usually via figwheel.
so, in that case, somehow, lein repl leads to cljs happiness, but it's all fuzzy. and your point about #clojurescript is true.
How's the status of using graalvm native image with clojure? Any significant gotchas to be aware of?
Hello everybody, can you recommend me a function that I should use to get these results? I know that problem is the data
input to extract-info function. I can't find a right function to use with merge-with to pack all the elements into list ( current implementation creates nested list for every element ) with unique occurences (sets). Thank you
<@U7S5E44DB> yes -- i don't know of a nice summary page, iirc, there is some locking-related things and on windows, there appears to be an issue involving _*in_* -- <@U04V15CAJ> knows pretty well, so you might ask him for more specifics. there's also a <#CAJN79WNT|graalvm>, fwiw.
ah, i found this: https://github.com/taylorwood/lein-native-image#user-content-caveats
why does tools.reader accept multiple :features
in a set?
user=> (r/read-string {:read-cond :allow :features #{:clj :cljs}} "[#?(:cljs 1 :clj 2)]")
[1]
user=> (r/read-string {:read-cond :allow :features #{:clj :cljs}} "[#?(:clj 1 :cljs 2)]")
[1]
what does it mean to support multiple features? and what happens when there are multipe overlapping branches/features?
I don't know if this is related, but when reader conditionals were first added to Clojure, before the first official release containing them, they were designed to contain any keywords you wanted, for 'sub platforms', i.e. much more specific than just :clj :cljs :cljr
That was pared back to only those choices shortly before the release, in hopes of keeping things simpler for everyone, especially for other tools that parsed Clojure.
@andy.fingerhut I guess that is related, since most parsers will probably only use one feature at a time and not a multiple?
I don't recall the history, but when the feature was originally proposed, it was perhaps necessary for the proposed generality that there be multiple features 'enabled'.
The paring back to at most one of :clj :cljs :cljr being enabled, when that restriction was made, perhaps did not cause the developers to change the API to eliminate that generality, so hence a set rather than a single keyword as a parameter.
And perhaps they wanted to leave it open for that future generality again, later.
The reader, as an independent component, can still take multiple features and do something useful when reading arbitrary code. So that feature still exists and is potentially useful.
Separately, the reader is used by the language platforms to parse source code for that particular language. In these cases, a “platform” feature is injected when reading source files and that is not currently an open set.
Doing so is still a possibility in the future but we decided that was a lot of flexibility with a lot of pros and cons and we would leave that decision to a future date
Hi! One question:
Is there a library that can help me with this?
I need a function to create an interval N minutes around some timestamp
and a function to check if a timestamp is contained in that interval.
I tried java-time
but the interval
function (`http://dm3.github.io/clojure.java-time/java-time.html#var-interval`) doesn't seem to exist anymore.
I created some functions to solve this using java-time/instant
and interop but I feel I might be doing extra work that a library can do for me.
https://github.com/juxt/tick this one right?
Has anyone used marginalia with clj? There's mostly just a lein plugin. (And a "zi" plugin which appears to be some kind of maven thing.)
@lvh Yeah, been a while since I did it tho'...
Pretty sure we just called this function via -e
https://github.com/gdeer81/marginalia/blob/master/src/marginalia/core.clj#L251