Re: What to use for serializing reference types?

2014-08-10 Thread Jozef Wagner
Assign a unique name to the prototype object. Serialize instances as map and put the reference to the prototype object under one of their keys. Something like {:prototype-components {:r10k {:resistance 10, :type :fixed, :unit :kΩ}} :components [{:name "resistor 1", :proto :r10k}, {:name "resistor

Re: CIDER vs Org Mode: "Symbol's definition is void: nrepl-send-string-sync" (workaround)

2014-08-10 Thread Gary Johnson
I've been using the following patch for quite some time now, and it works reasonably well. The table generation is pretty suboptimal though, so if anyone has an better version, I'd love to see it. (defun org-babel-execute:clojure (body params) > "Execute a block of Clojure code with Babel." >

What to use for serializing reference types?

2014-08-10 Thread Patrick Logan
You'll have to adopt some form of reference designator. JSON-LD defines these. More domain specific, you could implement a subset of or borrow ideas from EDIF, a standard Electronic Design Interchange Format, which happens to be based on Lisp. http://en.m.wikipedia.org/wiki/EDIF -- You rece

Re: setting c3p0 logging

2014-08-10 Thread Sean Corfield
So that's new in 0.9.5? Good to know. We're still on 0.9.2.1. On Aug 9, 2014, at 10:08 AM, Brian Craft wrote: > In case anyone hits the same problem: > > strace showed the file being read, but it was having no effect, and c3p0 > reported no errors in the config. Checking the c3p0 changelog, I f

Re: Success Stories w/US Government Projects

2014-08-10 Thread Alex Miller
The Consumer Financial Protection Bureau has done some visible Clojure work. http://cfpb.github.io/articles/seeking-clojure-developers-to-work-on-qu/ https://github.com/cfpb/qu Alex On Friday, August 8, 2014 7:54:08 PM UTC-5, rcg wrote: > > Hello; > > We are looking for Clojure success storie

Re: Howto write test.check custom generators

2014-08-10 Thread Timothy Washington
Oook, this is starting to sink in. I've gotten a little farther, in that I can run quick-check with my custom generator. However, after a bunch of values had been generated, it fails on a NullPointerException. How can I know where the breakdown is happening? => (tc/quick-check 100 u/has-agroup) {

Re: Can I compare ::logging from one namespace with ::logging from another?

2014-08-10 Thread Matching Socks
By the way, Keywords in a hierarchy need not be namespaced unless they are in the global hierarchy. user> (def H (-> (make-hierarchy) (derive :klutz :person))) user> (isa? H :klutz :person) true user> (isa? H :eggplant :person) false user> (isa? H :person :klutz) false ;; just to show contras

CIDER vs Org Mode: "Symbol's definition is void: nrepl-send-string-sync" (workaround)

2014-08-10 Thread Matching Socks
Using Org Mode's org-babel-execute-src-block, I ran into "Symbol's definition is void: nrepl-send-string-sync" after installing a recent update of the cider package from Melpa. cider-eval-sync appears to be an adequate substitute for the function that vanished. The new function is in the cider

Re: using Stuarts component library correctly

2014-08-10 Thread Matt Mitchell
Here's some relevant info about tools.namespace and protocols: https://github.com/clojure/tools.namespace#warnings-for-protocols - Matt On Saturday, August 9, 2014 6:04:03 PM UTC-4, Sven Richter wrote: > > Hi, > > First I would like to thank everybody for your answers and hints. > > I setup a sm

Re: Howto write test.check custom generators

2014-08-10 Thread Sam Ritchie
You can to use gen/fmap to build up generators. Here's an example: ;; generates a millisecond using gen/choose, then maps that to a time instance using my u/ms-to-time function. (def result-gen (->> (gen/choose 0 u/max-time) (gen/fmap u/ms-to-time))) ;; Generates EITHER a result or ni

Howto write test.check custom generators

2014-08-10 Thread Timothy Washington
Hi there, I'm trying to get my head wrapped around test.check . My current stumbling block is custom generators. Of course I've combed through the docs and source

What to use for serializing reference types?

2014-08-10 Thread MS
I'm trying to write an EE schematic capture program in clojure. I'd like to be able to define a prototype component, say a resistor with value=10k, then be able to instantiate that many times, with each instance having an additional property such as a name string. It's easy to ensure (identica

Re: Success Stories w/US Government Projects

2014-08-10 Thread Jozef Wagner
For the context, recent discussion about EPL Vs Government https://groups.google.com/forum/#!topic/clojure/jNEYM04TLiU Jozef On Sunday, August 10, 2014 1:19:48 PM UTC+2, Paul Butcher wrote: > > Out of interest, which aspect(s) of the EPL are your lawyers objecting to? > > -- > paul.butcher->msgC

Re: using Stuarts component library correctly

2014-08-10 Thread Brendan Younger
Hi Sven, Take out the wrap-reload middleware in your routes. That's what's causing you problems. You will have to manually call (reset) every time you have a code change, but Stuart recommends binding it to a key sequence in you editor. Brendan On Saturday, August 9, 2014 6:04:03 PM UTC-4,

Re: [ClojureScript] Re: [ANN] Silk, an isomorphic routing library for Clojure and ClojureScript

2014-08-10 Thread Dom Kiva-Meyer
Good stuff, Marc! Thanks for the feedback. That behavior in `composite` is a bug. Thanks for reporting. Sorting the query map seems reasonable. Good suggestion! Thanks again, Marc. On Sat, Aug 9, 2014 at 8:05 PM, marc wrote: > I've been playing and like Silk a lot! > > However the following

Re: using Stuarts component library correctly

2014-08-10 Thread Timothy Washington
If it helps, there's a lein plugin that creates a new component based app implementing the reloaded workflow. I haven't used it myself. But maybe it gets an initial version going, that you can build on. Tim Washington Interruptsoftware.com

Re: Howto Use isComponent with Adi

2014-08-10 Thread Timothy Washington
Hey Chris, sure thing. It did seem a bit weird, and maybe I'm using it wrong. But the issue I logged, and code details, are here . Let me know if you need anything else. Cheers Tim On Fri, Aug 8, 2014 at 5:43 PM, zcaudate wrote: > Hey Tim, > > adi's

Re: Success Stories w/US Government Projects

2014-08-10 Thread Paul Butcher
Out of interest, which aspect(s) of the EPL are your lawyers objecting to? -- paul.butcher->msgCount++ Silverstone, Brands Hatch, Donington Park... Who says I have a one track mind? http://www.paulbutcher.com/ LinkedIn: http://www.linkedin.com/in/paulbutcher Skype: paulrabutcher Author of Seven

Re: using Stuarts component library correctly

2014-08-10 Thread Sven Richter
Hi Alan, that's right, I did not call (reset) before reloading the page. But that's what happens sometimes, you change some things, don't call reset and then an exception will be thrown. Afterwards the state seems to be broken and nothing works anymore. In this special case, when I change the i