Re: New AWS services supported by Cognitect Labs' aws-api.

2019-12-04 Thread Michael Glaesemann



> On 2019–12–04, at 16:41, David Chelimsky  wrote:
> 
> Over the past couple of days, AWS has announced a number of new services at 
> AWS re:Invent, and released support for these services in their SDKs. As of 
> today, Cognitect Labs' aws-api supports the new services listed below. See 
> https://github.com/cognitect-labs/aws-api/blob/master/latest-releases.edn for 
> a full listing of all of the services aws-api supports.
> 
> Enjoy!

You rock, David!

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/A4027188-98E5-4C1D-8ABC-DCFF1C5A7DD5%40seespotcode.net.


Re: [ANN] Clojure 1.10 has been released!

2018-12-17 Thread Michael Glaesemann



> On 2018–12–17, at 17:12, Sean Corfield  wrote:
> 
> I'm not touching it until Sean Corfield has it running in production ;)
>  
> We have a mix of RC3 and RC4 in production right now. Clojure 1.10 “gold” is 
> already on QA so it’ll go to production in the next few days 
>  
> And, yeah, this was the first release of Clojure itself that I got a patch 
> into… and it was just a backport of a patch from the ASM Java code, so it 
> wasn’t really even my contribution!

Thanks, Sean :)

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] com.cognitect.aws/api-0.8.155

2018-12-12 Thread Michael Glaesemann



> On 2018–12–12, at 19:07, David Chelimsky  wrote:
> 
> com.cognitect.aws/api-0.8.155 is now available.

Rock on!

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] Programming Clojure, 3rd edition

2018-02-21 Thread Michael Glaesemann
Congrats!

> On 2018-02-21, at 10:04, Alex Miller <a...@puredanger.com> wrote:
> 
> The 3rd edition of Programming Clojure is now available on Pragmatic:
> 
> https://pragprog.com/book/shcloj3/programming-clojure-third-edition
> 
> The 1st edition was the first Clojure book available and was written by 
> Stuart Halloway around Clojure 1.0. The second edition was an update by Aaron 
> Bedra around Clojure 1.3 timeframe. 
> 
> This 3rd edition is an update by me bringing everything up to date with 
> Clojure 1.9. There is a new chapter on spec, a new section on transducers (as 
> a more intermediate topic, this is really just an intro - Clojure Applied has 
> more detail), a bit on clj (what I could do based on timing), and many small 
> updates throughout.
> 
> Alex
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with your 
> first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> --- 
> You received this message because you are subscribed to the Google Groups 
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] Clojure 1.9.0-RC2

2017-11-27 Thread Michael Glaesemann

> On 2017-11-27, at 16:17, Alex Miller <a...@puredanger.com> wrote:
> 
> I should also mention that I've re-built the Clojure doc automation process 
> and the Clojure docs have refreshed for the first time in a long while.

Thanks, Alex!

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Stubbing with instrument and generators

2017-06-30 Thread Michael Glaesemann
Thanks for taking a look. Here's a ticket: 
https://dev.clojure.org/jira/browse/CLJ-2197

> On 2017-06-30, at 11:52, Alex Miller <a...@puredanger.com> wrote:
> 
> I don't think this is the same case as CLJ-2095 as the instrumented var 
> should have the opportunity to use the gen overrides you've included. In 
> particular, it seems like stest/instrument-choose-fn is currently passing the 
> :gen overrides map when getting the gen for the stubbed var. I'm wondering if 
> there is a bug there where the spec has already been resolved and thus the 
> gen key (::y) is not getting matched. Feel free to file a ticket for this.
> 
> On Friday, June 30, 2017 at 9:37:42 AM UTC-5, Michael Glaesemann wrote:
> Using spec instrument to stub functions is really helpful. I'm using stubbing 
> to test Stuart Sierra-style components with some success. However, I've been 
> surprised that generator override doesn't work as I would expect it to. 
> Here's an example: 
> 
> ;; [org.clojure/spec.alpha "0.1.123"] 
> 
> (require '[clojure.spec.alpha :as s]) 
> (require '[clojure.spec.gen.alpha :as gen]) 
> (require '[clojure.spec.test.alpha :as stest]) 
> 
> (defprotocol Y 
>   (-do-y [r])) 
> 
> (def y? (partial satisfies? Y)) 
> (s/def ::y y?) 
> 
> ;; Protocol methods can't be spec'd, so wrap it in a function. 
> 
> (defn do-y [r] 
>   (-do-y r)) 
> 
> (s/fdef do-y :args (s/cat :y-er ::y)) 
> 
> ;; Example of the protocol implementation that we're going to stub. 
> 
> (defrecord BadYer [] 
>   Y 
>   (-do-y [_] (throw (Exception. "can't make me!" 
> 
> 
> ;; Confirm BadYer instances are valid with respect to the protol spec. 
> 
> (s/valid? ::y (->BadYer)) 
> ;; => true 
> 
> ;; And confirm BadYer instances will throw when called. 
> 
> (try 
>   (do-y (->BadYer)) 
>   (catch Exception e 
> (.getMessage e))) 
> ;; => "can't make me!" 
> 
> 
> (def y-gen (gen/return (->BadYer))) 
> 
> ;; Confirm generator works as expected: 
> 
> (gen/sample y-gen 1) 
> ;; => (#spec_ex.core.BadYer{}) 
> 
> ;; We want to stub `do-y`, providing y-gen as a generator for `::y` 
> 
> (try 
>   (stest/instrument `do-y {:stub #{`do-y} 
>:gen {::y (fn [] y-gen)}}) 
>   (catch Exception e 
> (ex-data e))) 
> ;; => #:clojure.spec.alpha{:path [:y-er], :form :spec-ex.core/y, :failure 
> :no-gen} 
> 
> ;; However, we *can* stub `do-y` if we replace its spec. 
> 
> (stest/instrument `do-y 
>   {:stub #{`do-y} 
>:spec {`do-y (s/fspec 
>   :args (s/cat :y-er (s/with-gen ::y 
>(fn [] y-gen}}) 
> ;; => [spec-ex.core/do-y] 
> 
> There is a ticket open[ (CLJ-2095[1]) regarding using overrides s/gen with 
> custom generators. Is this a case where this applies? I can imagine that it 
> could be. Not overriding something that isn't there would result in the thing 
> still not being there, thus the :no-gen failure. And it is something that can 
> be worked around.  It would be decidedly more succinct if the gen override 
> worked rather than the spec override. 
> 
> Best, 
> 
> Michael Glaesemann 
> grzm seespotcode net 
> 
> 
> [1]: https://dev.clojure.org/jira/browse/CLJ-2095 
> 
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with your 
> first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> --- 
> You received this message because you are subscribed to the Google Groups 
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Michael Glaesemann
grzm seespotcode net



-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Stubbing with instrument and generators

2017-06-30 Thread Michael Glaesemann
Using spec instrument to stub functions is really helpful. I'm using stubbing 
to test Stuart Sierra-style components with some success. However, I've been 
surprised that generator override doesn't work as I would expect it to. Here's 
an example:

;; [org.clojure/spec.alpha "0.1.123"]

(require '[clojure.spec.alpha :as s])
(require '[clojure.spec.gen.alpha :as gen])
(require '[clojure.spec.test.alpha :as stest])

(defprotocol Y
  (-do-y [r]))

(def y? (partial satisfies? Y))
(s/def ::y y?)

;; Protocol methods can't be spec'd, so wrap it in a function.

(defn do-y [r]
  (-do-y r))

(s/fdef do-y :args (s/cat :y-er ::y))

;; Example of the protocol implementation that we're going to stub.

(defrecord BadYer []
  Y
  (-do-y [_] (throw (Exception. "can't make me!"


;; Confirm BadYer instances are valid with respect to the protol spec.

(s/valid? ::y (->BadYer))
;; => true

;; And confirm BadYer instances will throw when called.

(try
  (do-y (->BadYer))
  (catch Exception e
(.getMessage e)))
;; => "can't make me!"


(def y-gen (gen/return (->BadYer)))

;; Confirm generator works as expected:

(gen/sample y-gen 1)
;; => (#spec_ex.core.BadYer{})

;; We want to stub `do-y`, providing y-gen as a generator for `::y`

(try
  (stest/instrument `do-y {:stub #{`do-y}
   :gen {::y (fn [] y-gen)}})
  (catch Exception e
(ex-data e)))
;; => #:clojure.spec.alpha{:path [:y-er], :form :spec-ex.core/y, :failure 
:no-gen}

;; However, we *can* stub `do-y` if we replace its spec.

(stest/instrument `do-y
  {:stub #{`do-y}
   :spec {`do-y (s/fspec
  :args (s/cat :y-er (s/with-gen ::y
   (fn [] y-gen}})
;; => [spec-ex.core/do-y]

There is a ticket open[ (CLJ-2095[1]) regarding using overrides s/gen with 
custom generators. Is this a case where this applies? I can imagine that it 
could be. Not overriding something that isn't there would result in the thing 
still not being there, thus the :no-gen failure. And it is something that can 
be worked around.  It would be decidedly more succinct if the gen override 
worked rather than the spec override.

Best,

Michael Glaesemann
grzm seespotcode net


[1]: https://dev.clojure.org/jira/browse/CLJ-2095

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.