Re: clojure.spec merge+or bug?

2018-08-16 Thread shlomivaknin
Thank you for explaining! Just in case, I opened a bug here https://dev.clojure.org/jira/browse/CLJ-2388 On Thursday, August 16, 2018 at 6:47:30 PM UTC-7, Alex Miller wrote: > > The non-flowing behavior on conform is expected behavior. > > Failure to roundtrip conform then unform is a bug (so I

Re: clojure.spec merge+or bug?

2018-08-16 Thread shlomivaknin
Achhh, just spent the last few hours fighting this unexpected behavior with s/merge, until I finally came to realize that this is what it was.. I see this thread is quite old, did anyone open a bug for it as mentioned above? @Alex, you said this was the expected behavior, but then asked to ope

Re: ANN: Cognitect acquired by Microsoft

2017-04-02 Thread shlomivaknin
Man, what a good one! You ruined me for a moment there :D On Saturday, April 1, 2017 at 1:00:16 PM UTC-7, Gregg Reynolds wrote: > > made ya look! > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegro

Re: Strange problem with input stream starting clojure 1.7.0-alpha6

2016-03-07 Thread shlomivaknin
@Kevin, yes, I did just that to test coll-reduce, thanks for helping me out! @Alex, thanks for the detailed response, it sure demystified this error and gave a bunch of different solutions, awesome! On Monday, March 7, 2016 at 5:17:45 PM UTC-8, Alex Miller wrote: > > Iterator, seqs, and chunkin

Re: Strange problem with input stream starting clojure 1.7.0-alpha6

2016-03-07 Thread shlomivaknin
Thanks for your reply, ArchiveReader is actually an Iterator for ArchiveRecord (see https://github.com/iipc/webarchive-commons/blob/master/src/main/java/org/archive/io/ArchiveReader.java#L51). I also tried to explicitly do (iterator-seq (.iterator warc-value)) but got the same "got 0" everyw

Strange problem with input stream starting clojure 1.7.0-alpha6

2016-03-07 Thread shlomivaknin
Hey clojurians, I am using a java library that reads WARC files (an internet archive format) to use with hadoop. I was recently motivated to upgrade this project's clojure from 1.6 to 1.8 (to be able to use the recent (wonderful!) cider), and I got quite a strange behavior, that I managed to

Re: [ANN] Clojure 1.7.0-beta2

2015-05-01 Thread shlomivaknin
Right you are, silly me :) thanks! On Friday, May 1, 2015 at 11:17:42 AM UTC-7, Nicola Mometto wrote: > > > The type-hint on init-state is wrong. > > It has to be either > > (defn {:tag 'longs} init-state [] (long-array 1)) > or (preferred) > (defn init-state ^longs [] (long-array 1)) > > >

Re: [ANN] Clojure 1.7.0-beta2

2015-05-01 Thread shlomivaknin
I tried playing around with the new primitive type hints and got the following weird behavior on [org.clojure/clojure "1.7.0-beta2"]: (defn ^longs init-state [] (long-array 1)) (defn ^long store-state [^longs c ^long a] (aset c 0 a)) running the following line resulted in an exception: (let [

Re: Help sought on issue with AOT, hadoop, classloaders, and consistency of Clojure fn classes

2015-01-29 Thread shlomivaknin
Hey, Just to be sure, are you loading the full uberjar to hadoop? On Wednesday, January 28, 2015 at 11:39:54 PM UTC-8, Jason Wolfe wrote: > > First off, I apologize in advance for not having a reduced test case, and > express my sincere gratitude in advance for any assistance. I've been > te

Re: Is Clojure fit for giant space-efficient in-memory tree structures?

2014-07-01 Thread shlomivaknin
I have done something quite similar, only that the structure consumed hundred of GB's of RAM and was the main bottleneck of the application. Attempting it on the jvm (either java or clojure) resulted in a lot of wasted bits per bits and GC hangs, so I tried to use ByteBuffers (Direct, Mapped, e

Re: fast parallel reduction into hash-set/map

2014-02-20 Thread shlomivaknin
Hey Jules, Really nice stuff your making! One note about your SuperVecs idea though, it seems that using that approach we could get a deeply nested tree to represent our a vector, and I think this is the exact thing vectors are trying to avoid.. On Friday, February 21, 2014 1:39:56 AM UTC+2,

Re: question about let

2013-11-04 Thread shlomivaknin
hey, you could simply use do: (do (f1) (f2) (f3)) On Tuesday, November 5, 2013 2:18:56 AM UTC+2, julius wrote: > > Hi, > > I have a question, if there are a sequence of fn like (f1) (f2) (f3) ,I > just want to return the evaluation of last fn, for example > > ((f1) > (f2) > (f3)) > > now I

Re: Functions using locks are slowed even when locks are never taken

2013-11-03 Thread shlomivaknin
same results on my machine as well. I tried decompiling the jar (with cider-decompile), and the parts that actually run (the "then" clause) seems almost identical. If you'r interested, i can post them later tonight. On Sunday, November 3, 2013 2:32:42 AM UTC+2, Michael Blume wrote: > > Hmm, it

Re: Clojure - Where to start?

2013-10-12 Thread shlomivaknin
Hey Jeff, On Thursday, October 10, 2013 11:41:05 PM UTC+2, Jeff Heon wrote: > > I remember reading a post with a list of open source projects with > excellent clojure code. did you mean this post http://stackoverflow.com/questions/2444893/clojure-open-source-projects ? -- -- You received

Re: Future of clojure.contrib.core/-?> macro

2013-06-10 Thread shlomivaknin
Hey, its been a while since this discussion ended.. I read through it and now i am fully confused, where did -?> and -?>> end up being in? Thanks, Shlomi On Thursday, April 21, 2011 5:51:59 PM UTC+3, Ivan Koblik wrote: > > Hi Paul, > > Thanks, good to know. Sorry for the misleading email. > >

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
oh, right. thats a good point. ill re-post that correction on the bug report.. thanks for the review! On Wednesday, March 13, 2013 1:42:51 PM UTC+2, Marko Topolnik wrote: > > Hm. You shouldn't have made ConcreteChild a nested class, that is a > distraction that may set people on a wrong trail. I

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
here is the bug report: http://dev.clojure.org/jira/browse/CLJ-1183 Thanks! On Wednesday, March 13, 2013 1:02:25 PM UTC+2, shlomi...@gmail.com wrote: > > right, i managed to reproduce it here, thanks! > > so i am opening a bug and linking back here > > On Wednesday, March 13, 2013 12:48:43 PM UTC

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
right, i managed to reproduce it here, thanks! so i am opening a bug and linking back here On Wednesday, March 13, 2013 12:48:43 PM UTC+2, Marko Topolnik wrote: > > Yes, the error is there. I also created a *lein new app* project, which > by default creates a gen-classed main namespace: > > (ns

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
very interesting.. are you getting the same error as i originally got? On Wednesday, March 13, 2013 12:38:26 PM UTC+2, Marko Topolnik wrote: > > Detailed finding: it *doesn't* fail at compile time; it always fails at > runtime. > > Reason: at compile time there is a *reflection warning*, which me

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
That is very true. is here the right place? is there a a different group/forum for the language developers? should i file a bug on github? On Wednesday, March 13, 2013 12:17:45 PM UTC+2, Marko Topolnik wrote: > > The netty people are not to blame; harass Rich instead :) > > On Wednesday, March 1

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
hmmm, that what i was afraid of :) ill take my chances harassing the netty people now before i go down that path.. On Wednesday, March 13, 2013 12:09:44 PM UTC+2, Marko Topolnik wrote: > > I see, that's very unfortunate then. It fails even when it is not actually > making the reflective call. Yo

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
I fully agree with you, only it doesnt work.. ServerBootstrap does not override that specific method, which is what causing this pain, so i dont know what other options i have. here is my attempt: user> (.channel ^ServerBootstrap b ^Class io.netty.channel.socket.nio.NioServerSocketChannel) Ref

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
hey we dont need to be almost certain, we can just look at the code : https://github.com/netty/netty/blob/master/transport/src/main/java/io/netty/bootstrap/AbstractBootstrap.java and see that it is not a public ancestor. more then that, i annotated the code and it didnt work. here is a repl dum

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
here is the full exception when compiling: Exception in thread "main" java.lang.IllegalArgumentException: Can't call public method of non-public class: public io.netty.bootstrap.AbstractBootstrap io.netty.bootstrap.AbstractBootstrap.channel(java.lang.Class), compiling:(netty.clj:31:1) at cloju

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
yes you are right, it is a compile-time error.. On Wednesday, March 13, 2013 11:19:25 AM UTC+2, Marko Topolnik wrote: > > When you annotate, is it a runtime or a compile-time error? I would be > very surprised if it happened at runtime (when the function is actuall > called). > > On Wednesday,

Re: Java interop: "Can't call public method of non-public class"

2013-03-13 Thread shlomivaknin
Hey Sean, Your attempt worked because in Netty 4.0.0.Alpha8 AbstractBootstrap was still public.. Try it out with 4.0.0.Beta2.. Thanks! On Wednesda

Re: Java interop: "Can't call public method of non-public class"

2013-03-12 Thread shlomivaknin
I meant to post this as a reply to https://groups.google.com/d/msg/clojure/jYfEKVH5GsQ/3Hq5hU0u6UQJ In my case i am trying to get clojure working with netty 4, here is the code: (def #^AbstractBootstrap b (ServerBootstrap.)) (.channel ^AbstractBootstrap

Re: New Clojure user group in Israel

2013-01-10 Thread shlomivaknin
Hey Daniel, are you making a clojure-israel google group? On Monday, December 17, 2012 12:58:21 PM UTC+2, Daniel Szmulewicz wrote: > > Hi everybody, > > Happy to announce that Israel has its first Clojure user group. > > http://www.meetup.com/Clojure-Israel/ > > Sincerely, > > Daniel Szmulewicz