Re: Callbacks as Sequences

2013-02-07 Thread Erik Bakstad
Not sure it applies, but I found this very interesting: http://oobaloo.co.uk/clojure-from-callbacks-to-sequences Erik kl. 19:45:36 UTC+1 onsdag 6. februar 2013 skrev da...@dsargeant.com følgende: > > I'm not to clojure/clojurescript and was wondering if anyone has taken a > crack at writing a

Re: Can a protocol method have the same name as a clojure.core function?

2013-02-07 Thread Meikel Brandmeyer (kotarak)
Hi, you can still use a defrecord. Just don't implement the protocol inline. Clojure user=> (ns foo.bar (:refer-clojure :exclude [get])) nil foo.bar=> (defprotocol FooBar (get [this])) FooBar foo.bar=> (ns foo.baz) nil foo.baz=> (alias 'fb 'foo.bar) ; this is due to working only in the repl. Nor

Re: Can a protocol method have the same name as a clojure.core function?

2013-02-07 Thread Don Jackson
That makes perfect sense, and I should have figured that out since defrecord is implementing a bunch of useful protocols underneath…. Thanks for the quick response! On Feb 7, 2013, at 9:38 PM, Ben Wolfson wrote: > You just can't use defrecord, because defrecord macroexpands into a > deftype t

Re: Can a protocol method have the same name as a clojure.core function?

2013-02-07 Thread Ben Wolfson
You just can't use defrecord, because defrecord macroexpands into a deftype that implements a *different* protocol with a function *also* named "get". On Thu, Feb 7, 2013 at 9:24 PM, Don Jackson wrote: > > I'd like to name a protocol method to be the same name as a clojure.core > function, for ex

Can a protocol method have the same name as a clojure.core function?

2013-02-07 Thread Don Jackson
I'd like to name a protocol method to be the same name as a clojure.core function, for example, get. Is this possible, and if so, how? user=> (ns ptest.protocol (:refer-clojure :exclude [get])) nil ptest.protocol=> (defprotocol TestProtocol (get [_ ke

Re: Clojure/West (Portland, Mar 18-20) - Mission Kontrol, unsessions, lightning talks

2013-02-07 Thread Alex Miller
CORRECT! Apparently I was hitting the Nyquil a little too hard the other night. If someone wants to sponsor the night at Ground Kontrol, please let me know! It's available. Alex On Thursday, February 7, 2013 10:58:07 AM UTC-6, Austin Haas wrote: > > > The arcade is called Ground Kontrol (not

Re: Clojure - Python Style suggestion

2013-02-07 Thread Dave Sann
yes, I did not mean to imply otherwise. On Friday, 8 February 2013 09:04:43 UTC+11, Jason Lewis wrote: > > `quote` is a feature, not a bug. Its not just for distinguishing between > lists and function calls, its for deferring evaluation. Its also been part > of Lisp since the beginning... IIRC,

Re: Simple Network Messaging

2013-02-07 Thread Feng Shen
For json, Clojure has a convenient lib: https://github.com/clojure/data.json for networking, how about using HTTP as the transport? Clojure has many libraries for HTTP server & client, c# has many libraries too. On Friday, February 8, 2013 5:44:06 AM UTC+8, JvJ wrote: > > I'm looking to d

Re: Sending Clojure Objects over TCP

2013-02-07 Thread Feng Shen
slacker - Transparent, non-invasive RPC by clojure and for clojure. https://*github*.com/sunng87/*slacker* * * 1. 2. On Thursday, February 7, 2013 9:16:03 AM UTC+8, JvJ wrote: > > Does anyone know if there's a simplified networking library that allows > this? -- -- You received

Re: Sending Clojure Objects over TCP

2013-02-07 Thread Matthew
Aleph On Thursday, February 7, 2013 12:16:03 PM UTC+11, JvJ wrote: > > Does anyone know if there's a simplified networking library that allows > this? -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to

Re: Clojure - Python Style suggestion

2013-02-07 Thread Herwig Hochleitner
On Feb 4, 2013 7:58 PM, "Dave Sann" wrote: > The syntax does complect in one case. > When you really do want a list as opposed to a function call. hence quote > and (list ...) > The evaluation rules are clojure's implementation of reduction in lambda calculus. Every clojure form has an associate

Re: Simple Network Messaging

2013-02-07 Thread Herwig Hochleitner
I'd use sockets (or even pipes, if you really don't need any flexibility in the setup), it doesn't get much simpler than that. They just work. cheers 2013/2/7 JvJ > I'm looking to do some simple messaging (json strings) between programs > running on the same machine. One will be in C# and one

Re: Clojure - Python Style suggestion

2013-02-07 Thread Jason Lewis
`quote` is a feature, not a bug. Its not just for distinguishing between lists and function calls, its for deferring evaluation. Its also been part of Lisp since the beginning... IIRC, its in McCarthy's paper that defined the first lisp. On Feb 4, 2013 7:58 PM, "Dave Sann" wrote: > The syntax do

Re: Callbacks as Sequences

2013-02-07 Thread JvJ
Thanks, but I'm looking for something that would let me sent strings between programs on localhost. On Wednesday, 6 February 2013 22:17:02 UTC-5, Feng Shen wrote: > > I did something for a http lib: > > ;; get them concurrently(let [response1 (http/get "http://http-kit.org/";) > response2 (

Simple Network Messaging

2013-02-07 Thread JvJ
I'm looking to do some simple messaging (json strings) between programs running on the same machine. One will be in C# and one will be in Clojure. Is there a library/set of libraries that could simplify this communication? I haven't done much networking in the past, and I'd like to keep this

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
Fantastic insight. Thanks much, it is working great now on all browsers (the bug had mostly appeared on IE). On Thursday, February 7, 2013 11:48:50 AM UTC-5, James Reeves wrote: > > On 7 February 2013 16:37, larry google groups > > > wrote: > >> Okay, got all this working. Thank you very muc

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Jason Wolfe
On Thu, Feb 7, 2013 at 10:54 AM, AtKaaZ wrote: > Hello. > https://github.com/Prismatic/plumbing/blob/master/test/plumbing/graph_examples_test.clj#L148 > Why do they return in a map instead of maybe a set ? do we ever get {:key > false} ? > Thanks. The leaf value for output schemata is always 'tru

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread AtKaaZ
Hello. https://github.com/Prismatic/plumbing/blob/master/test/plumbing/graph_examples_test.clj#L148 Why do they return in a map instead of maybe a set ? do we ever get {:key false} ? Thanks. On Thu, Feb 7, 2013 at 7:22 PM, Jason Wolfe wrote: > We've just posted a blog post with more high-level

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Jason Wolfe
We've just posted a blog post with more high-level context on what we're trying to accomplish with Graph (plus more examples!) http://blog.getprismatic.com/blog/2013/2/1/graph-abstractions-for-structured-computation We're also answering questions and reading comments in the Hacker News thread,

Re: [ANN] Kern 0.5.0 -- A text-parsing library

2013-02-07 Thread Armando Blancas
Ragnar, thanks for your kind words; I'm glad you're finding kern fun and useful. The lexer module has parsers that take care of whitespace, and conveniences like parens, braces, comma-sep (and others) that shorten things. You might start with the namespace blancas.kern.lexer.basic and use simil

[ClojureScript] Please test CLJS-418, fixing browser REPL

2013-02-07 Thread David Nolen
http://dev.clojure.org/jira/browse/CLJS-418 Some of you may have encountered bizarre problems when trying to use browser REPL with the latest releases of ClojureScript. This ticket contains a patch that should resolve the issue but we need people to test. Thanks, David -- -- You received this

Re: Clojure/West (Portland, Mar 18-20) - Mission Kontrol, unsessions, lightning talks

2013-02-07 Thread Austin Haas
The arcade is called Ground Kontrol (not Mission Kontrol). http://groundkontrol.com/ Last summer, I attended another conference that rented Ground Kontrol for a few hours of free play. Most games are multi-player, and you know everyone is there for the conference, so it can be a really fun way t

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Jason Wolfe
Interesting. Our model came from large 'let' statements in Clojure, which I think is similar (I'm not too familiar with Haskell). The advantage over the let statement is that now you can manipulate the composition, run only part of it, wrap the value functions to monitor them, and so on. I th

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Jason Wolfe
Hi Edmund, Thanks for your interest. There's actually no way to fill in ??? in your example, because it's a requirement of Graph that node names must be unique, and distinct from top-level input keys. This ensures that the Graph has a unique topological order, and it's always clear where the

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread James Reeves
On 7 February 2013 16:37, larry google groups wrote: > Okay, got all this working. Thank you very much for your tip. Can you say > what you think the problem was? I noticed that the wrap-resource middleware didn't account for the HTTP HEAD method, while route/resources does. According to the HT

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
Okay, got all this working. Thank you very much for your tip. Can you say what you think the problem was? On Thursday, February 7, 2013 11:16:46 AM UTC-5, larry google groups wrote: > > Any reason this would work on all browsers except IE? > > > On Thursday, February 7, 2013 10:45:02 AM UTC-5,

Re: [ANN] Morph v0.1.0 Monads & friends: pure functions, less boilerplate

2013-02-07 Thread Armando Blancas
Yeap, I've had looked at Jim Duey's projects and had read his articles at his website; it's good content. On Thursday, February 7, 2013 1:48:12 AM UTC-8, Marek Srank wrote: > > btw, have you seen https://github.com/jduey/protocol-monads ? > > Marek > > On Thursday, February 7, 2013 1:06:39 AM UTC

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
Any reason this would work on all browsers except IE? On Thursday, February 7, 2013 10:45:02 AM UTC-5, larry google groups wrote: > > Ah, sorry, that does seem to have worked (I think I forgot to recompile). > What do you think the problem was? > > > On Thursday, February 7, 2013 10:41:00 AM UT

Re: ANN: Tawny-OWL 0.9

2013-02-07 Thread Phillip Lord
Frank Siebenlist writes: > There is one more important difference between EPL and GPL/LGPL that > we should be aware off: > > You cannot copy snippets out of Philip's LGPL'ed code and use them in > your own EPL'ed code. This is a true and is, indeed, a risk. Most of the code in tawny is not that

Re: ANN: Tawny-OWL 0.9

2013-02-07 Thread Phillip Lord
Michael Klishin writes: > 2013/2/6 Phillip Lord > >> You mean "what is the name of this library as maven artifact"? Rather >> than it's dependencies. > > Are you sure people will find it there if it's not in the README? The > thinking "if I can't even get started with it, why do I need to see >

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
Ah, sorry, that does seem to have worked (I think I forgot to recompile). What do you think the problem was? On Thursday, February 7, 2013 10:41:00 AM UTC-5, larry google groups wrote: > > About this: > > >(defroutes app-routes > > (ANY "/" request (index request)) > >;; > > (GET "/finish-u

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
About this: >(defroutes app-routes > (ANY "/" request (index request)) >;; > (GET "/finish-user-sign-up" request (finish-user-sign-up request)) > (route/resources "/") > (route/not-found "Page not found")) I removed (wrap-resource) and added (route/resources "/") to the routes, in the pe

Re: CSS sometimes disappears in uberjar web app using wrap-resource

2013-02-07 Thread larry google groups
> You've also got a max-age of 90 for your session cookies, which would mean your sessions will > time out in 90 seconds. Is that what you want? Yes, a painful compromise, since the designers didn't want to make the "Start Over" link obvious, we went with a short session. This is for a little

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread László Török
+1, was also wondering 2013/2/7 Valentin Golev > Graph definitions really remind me of `do` syntax in Haskell, where you > can bind values and then use them in later steps of the computation. > > > On Tuesday, January 29, 2013 10:46:54 PM UTC+4, Aria Haghighi wrote: >> >> Hey all, >> >> Pri

Type hints ignored in proxy-super

2013-02-07 Thread Vladimir Tsichevski
Hi, seems type hints are ignored when we use proxy-super: (set! *warn-on-reflection* true) (proxy [Object][] (equals[o] (proxy-super equals))) Reflection warning, null:3 - reference to field equals can't be resolved. Regards, Vladimir PS: I'm on clojure-1.4 -- -- You received this mes

Re: Clojure/West (Portland, Mar 18-20) - Mission Kontrol, unsessions, lightning talks

2013-02-07 Thread Leonardo Borges
ah now that makes sense. I'll watch the twittersphere :) Leonardo Borges www.leonardoborges.com On Thu, Feb 7, 2013 at 7:07 PM, Rich Morin wrote: > On Feb 6, 2013, at 21:07, Leonardo Borges wrote: >> Where can we find more about this datomic hack session? > > Sorry, it appears that I only posted

Re: Clojure - Python Style suggestion

2013-02-07 Thread Softaddicts
Having worked with a number of languages sensitive to white spaces including "magic" columns reminiscent of the paper cards, I honestly do not find any sex-appeal in a syntax relying on spaces, line breaks and indentation. It's error prone, errors are harder to detect, and breaks the tool chain.

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Valentin Golev
Graph definitions really remind me of `do` syntax in Haskell, where you can bind values and then use them in later steps of the computation. On Tuesday, January 29, 2013 10:46:54 PM UTC+4, Aria Haghighi wrote: > > Hey all, > > Prismatic has open-sourced our Plumbing and Graph library on > githu

Re: [ANN] Kern 0.5.0 -- A text-parsing library

2013-02-07 Thread Ragnar Dahlén
Hi Armando, Thank you for your great work with this library! I don't have much previous experience with parser combinators, but with your implementation, and the wonderful documentation, I've had a lot of fun playing and learning. I've been hacking on a small project for implementing a subset o

Re: mysql auth issue when using upstart for ring

2013-02-07 Thread Omer Iqbal
Thanks Michael. That was the problem! On Thu, Feb 7, 2013 at 5:20 PM, Michael Wood wrote: > Hi > > On 7 February 2013 09:12, Omer Iqbal wrote: > > Hey, I used a similar upstart script which works fine for ring. > > However, weirdly enough, my auth with a mysql database fails. I'm using > > korm

Re: Prismatic Plumbing and Graph Open-Source Release

2013-02-07 Thread Edmund
Hey Aria / Jason, Thanks for OSing this library, its really useful. One question: how do you deal with nesting on the output side of graph declaration ? I understand it for fnk, but but how would I achieve: {:a {:b 1}} -> {:a {:b 1, :c 2}} with a single declaration: (graph/eager-compile

Re: [ANN] Morph v0.1.0 Monads & friends: pure functions, less boilerplate

2013-02-07 Thread Marek Šrank
btw, have you seen https://github.com/jduey/protocol-monads ? Marek On Thursday, February 7, 2013 1:06:39 AM UTC+1, Armando Blancas wrote: > > Morph is a new implementation of monads based on protocols. It's intended > to provide the common patterns of error-handling, short-circuit sequencing,

Re: mysql auth issue when using upstart for ring

2013-02-07 Thread Michael Wood
Hi On 7 February 2013 09:12, Omer Iqbal wrote: > Hey, I used a similar upstart script which works fine for ring. > However, weirdly enough, my auth with a mysql database fails. I'm using > korma to interface with the db. The problem only occurs with upstart > script,, because it works fine when I

Re: Clojure/West (Portland, Mar 18-20) - Mission Kontrol, unsessions, lightning talks

2013-02-07 Thread Rich Morin
On Feb 6, 2013, at 21:07, Leonardo Borges wrote: > Where can we find more about this datomic hack session? Sorry, it appears that I only posted about this to the Datomic list: There will be some unconference sessions Monday evening, so I'll try to schedule something then for Codeq / Datomic.