This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-07-02
Channels
- # aleph (1)
- # architecture (4)
- # beginners (39)
- # boot (12)
- # cider (25)
- # cljs-dev (3)
- # cljsrn (5)
- # clojure (175)
- # clojure-dusseldorf (1)
- # clojure-italy (13)
- # clojure-nl (4)
- # clojure-russia (1)
- # clojure-spec (52)
- # clojure-uk (110)
- # clojurescript (35)
- # data-science (2)
- # datomic (61)
- # editors (8)
- # emacs (2)
- # fulcro (7)
- # graphql (15)
- # hoplon (1)
- # hyperfiddle (3)
- # jobs (4)
- # jobs-discuss (12)
- # juxt (2)
- # lein-figwheel (6)
- # leiningen (35)
- # off-topic (4)
- # onyx (5)
- # parinfer (1)
- # pedestal (63)
- # re-frame (38)
- # reitit (7)
- # ring-swagger (7)
- # rum (2)
- # shadow-cljs (27)
- # tools-deps (10)
- # uncomplicate (16)
Hi! any solution for this? https://github.com/bhauman/lein-figwheel/issues/541
I’m drawing a blank, and google doesn’t help — I have a data structure, that I want to convert to JSON in UTF-8 and get the byte length so I can put that in a “Content-Length” header. I’m using Cheshire and Pedestal, but I’m not sure if the String I get back with cheshire/generate-string
is in UTF-8 or not — or how I should convert that or count its bytes?
I plan to work on some OpenCV code soonly. I hope Clojure could help me in this job. I see a lot of mentions around “connect a REPL to a running program” and I’m looking for good references on the subject. There is my idea : - Writing a simple “infinite loop” which capture the webcam and send frames to an analysis function. - Launch the program. - Connect (?) to the program via REPL - Update (?) the analysis function and check the results until I get what I want Is it realistic ? Or did I misundertand the concept ?
@charles.fourdrignier There's a great guide on using the REPL on the clojure site: https://clojure.org/guides/repl/introduction
You're correct in your interpretation of how it can be used 🙂
Hi. Is there a neater way to write this anon fn? It does what I want (remove optional list wrapping around some elements) but I find it quite ugly.
(def hic [:p {:moo 123} '("pew" "dew") [:b "oops"]])
(apply concat (map #(if (list? %) (vec %) (vector %)) hic))
I can't see a way to make that anon fn neater, but you can also do the same with a reduce:
(reduce (fn [acc e] (if (list? e) (into acc e) (conj acc e))) [] hic)
Thanks. Your version is nicer cos it returns a vector instead of a list. Also just noticed that in mine, mapcat can replace the apply concat map 🙂
True! I always forget that mapcat
exists 😛
@andre.stylianos Thanks ! I’ll try this and get back when hitting too much walls.
I want to do some machine learning and/or neural nets with clojure today. aside from Cortex what can I use?
Follow Carin Meier on Twitter and find her giggasquid blog. She's very big into this I believe
Something else ... Where does the clojure ecosystem have anything that implements so called back-pressure??
@matan you mean back prop? (backwards propagation) i'm not sure what back-pressure is.
@sova backpressure is a behavior in an asynchronous system which intentionally slows a producer down when a consumer is overloaded, it leads to better failure and degradation behaviors
@matan core.async and manifold both implement good backpressure when used properly
Thanks @noisesmith! Long time :-))
right, but backpressure is just one behavior of a distributed processing system, and clojure doesn't have something all tied up with a bow and ready to go like akka
core.async only works inside one vm, akka works across vms / hosts iirc
Quick question. What is the correct way of using the clojure.java.jdbc/get-by-id
function? I am doing this.
(sql/get-by-id @url
(keyword (:my-table-name table-names))
id
:guid))
But I get an error that states: PSQLException ERROR: operator does not exist: uuid = character varying
I am assuming here that :guid
is telling the jdbc wrapper that :guid
is the primary key.
The id
I am passing is generated by java.util.UUID/randomUUID
and it is of type string
It doesn't like that I am passing a string representation of a UUID. So I think I need to find a way to convert that string into a UUID and then send that over.
Does anybody have a problem with running the compojure example? I tried:
lein new compojure new-app
cd new-app
lein ring server
and poof:
Could not transfer artifact org.eclipse.jetty.orbit:javax.servlet:jar:2.5.0.v201103041518 from/to central ( ): Read timed out
Could not find artifact org.eclipse.jetty.orbit:javax.servlet:jar:2.5.0.v201103041518 in clojars ( )
Could not find artifact org.eclipse.jetty.orbit:javax.servlet:jar:2.5.0.v201103041518 in ()
Could not find artifact org.eclipse.jetty.orbit:javax.servlet:jar:2.5.0.v201103041518 in sonatype ()
Could not find artifact org.eclipse.jetty.orbit:javax.servlet:jar:2.5.0.v201103041518 in redhat ( )
Could not transfer artifact org.eclipse.jetty.orbit:javax.servlet:pom:2.5.0.v201103041518 from/to central ( ): Read timed out
This could be due to a typo in :dependencies, file system permissions, or network issues.
If you are behind a proxy, try setting the 'http_proxy' environment variable.
works fine here, I would check all the things it mentions there (network, permissions, proxies)
ok that's problem with my network
😕 has anybody had a similar issue?
is it repeatable? it says there "Read timed out". Possible its just a transient thing?
It's repeatable. It seems that's something wrong with my router. I am able to surf the net without any problems but when I try to download the jar manually then chrome says that this jar can harm my computer https://repo1.maven.org/maven2/javax/servlet/servlet-api/2.5/.
What is funny it;s not a problem with the antivirus. 😛 Tried with mobile network and it worked perfectly.