Fork me on GitHub

yeah, the expansion @hiredman showed of let would do the map construction I was mentioning


neat, need to stop postponing the macro chapter 😉


hi all how to get the current url from address bar in clojure for ex "" is the current url , then how to get this using clojure

Lennart Buit06:04:27

sorry you will have to be a bit more specific, for example which web server library you are using


we are using Ring Lib and i want current url from address bar please help


Such info usually resides in the request map (or equivalent construct)


Is there a way to get all the positions of a regex match in a string with clojure?


thank you! I think I'll just proceed differently, the patterns are rather simple I should be able to do it without going to java

Lennart Buit06:04:52

well if you are using clj, there is interop with Java

Lennart Buit06:04:43

on cljs you are probably out of luck 😛


I am using clj, but precisely, I'd rather avoid java

Lennart Buit06:04:17

(hope that helps!)


If you’re just learning #clojure or spec, but also want to do something useful for other community members, contribute a missing spec to re-find.web: It’s easy and fun.

parrot 4

Wow, that’s really nice!

Robert Nikander09:04:44

So if I instrument a function with spec, it checks the :args. Anyone know if they are planning to add an option to also check the :ret and :fn parts of the spec?

Alex Miller (Clojure team)12:04:50

There may be some changes around this in spec 2, still discussing


Probably not (I don't know either). Instrumenting is only about checking if you are calling you're function correctly. Whether it returns the right thing is a different concern that generative testing helps with. There are libraries that provide this though (Orchestra if I remember the name correctly)

Robert Nikander09:04:16

Okay, I see the Clojure JIRA where the idea was declined, at least for now. I'll try orchestra. I feel like this is more useful in UI/cljs code, where unit testing is harder.

Lennart Buit10:04:39

I noticed that it is a bit of a performance hit

Lennart Buit10:04:01

so that is something to look out for


@dpsutton @hiredman Thanks for your help with the polynomial stuff last week. Hash-maps were definitely the way to go! Managed to implement the extent of my knowledge about polynomials.

👏 4

How to add days in current date using clj-time library ?


(t/plus (t/now) (t/days 2))?


@shraddha.paktolus BTW here's my require (require '[clj-time.core :as t])


Also, consider using which wraps the java standard library instead of joda.


how to assign variable in selmer ?


I'd like to "dip my toes into the water" of deep learning in Clojure. Where are the right places to begin? The ideal for me would be a "hello world" sized project from which I could explore by reading its dependencies and building on its project.

dpsutton13:04:18 see "Deep Learning From SCratch to GPU" I imagine


@dpsutton thanks for the post this is awesome


8 part series 🙂


Thanks. Actually, that's where I started but sadly got lost at the first two lines of "basic setup": - In "Getting Started" it's not obvious (though I can guess) if the tasks under Installation are needed, or are superseded by the next section With Leineingen - In "Hello world" there is basically no readme; nor is the project setup to work with lein run. I don't see how to take the first baby steps. It is obvious that a lot of work and love went into Neanderthal and the "Deep Learning From ..." articles. I don't want to be "that guy" who is bothered by the tiny bits of instruction missing at the beginning. But, I'm stuck.


you absolutely should be that guy


because you are the target audience


Ok, yeah, you are right. But, I had hoped to learn a bit more first and make sure that these weren't just my personal blind spots. But, yes. I'm stuck at those points.


hm, I think it's saying, you'll have to choose an engine with either #2 or #3


that you can either put a jar on the classpath manually, or use Leiningen


as for the jvm-options, I'm not sure about "--add-opens=java.base/jdk.internal.ref=ALL-UNNAMED" in jvm-options-form


the sole time i tried some DL, getting the engine set up correctly was a bear