<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Clojure Q&amp;A - Recent questions tagged bug</title>
<link>https://ask.clojure.org/index.php/tag/bug</link>
<description></description>
<item>
<title>`(:k m)` returns `nil` while `(identical? (first (keys m)) :k)` is `true` — two coexisting `Keyword` instances?</title>
<link>https://ask.clojure.org/index.php/15073/returns-while-identical-first-coexisting-keyword-instances</link>
<description>&lt;p&gt;We're seeing what looks like a violation of the keyword-interning invariant in production. The bug is deterministic (repeats thousands of times in the same order on the same Aleph/Netty thread) and is cleared by recompiling the affected namespaces via nREPL.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(when (and (map? result) (nil? (:payload result)))   ; this WHEN fires
  (let [payload-key (-&amp;gt;&amp;gt; (keys result)
                         (filter #(.contains (pr-str %) &quot;payload&quot;))
                         first)
        payload-via-key (when payload-key (get result payload-key))]
    (log/warn {:result-type                   (str (type result))
               :result-keys                   (pr-str (keys result))
               :payload-key-equals-literal?   (= payload-key :payload)
               :payload-key-identical?        (identical? payload-key :payload)
               :payload-via-found-key-nil?    (nil? payload-via-key)}
              &quot;diagnostic&quot;)))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Logged values when the bug fires:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;{:result-type                   clojure.lang.PersistentArrayMap
 :result-keys                   (:payload :aws-xray)
 :payload-key-equals-literal?   true
 :payload-key-identical?        true
 :payload-via-found-key-nil?    false}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;So:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;(:payload result)&lt;/code&gt; in the &lt;code&gt;when&lt;/code&gt; returned nil.&lt;/li&gt;
&lt;li&gt;A few lines later, the diagnostic body proves that the first key in &lt;code&gt;(keys result)&lt;/code&gt; IS the body-site &lt;code&gt;:payload&lt;/code&gt; literal by identity (and therefore by &lt;code&gt;=&lt;/code&gt;, since &lt;code&gt;Keyword&lt;/code&gt; inherits &lt;code&gt;Object.equals&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;(get result that-key)&lt;/code&gt; returns the actual non-nil payload value.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;code&gt;PersistentArrayMap.indexOf&lt;/code&gt; uses &lt;code&gt;==&lt;/code&gt; for &lt;code&gt;Keyword&lt;/code&gt; keys, so the only way &lt;code&gt;(:payload result)&lt;/code&gt; returns nil while &lt;code&gt;(keys result)&lt;/code&gt; yields a key that is &lt;code&gt;identical?&lt;/code&gt; to &lt;code&gt;:payload&lt;/code&gt; at a nearby site is if &lt;strong&gt;the &lt;code&gt;:payload&lt;/code&gt; literal at the WHEN site and the &lt;code&gt;:payload&lt;/code&gt; literal at the body site are two different &lt;code&gt;Keyword&lt;/code&gt; instances&lt;/strong&gt;, even though they're written identically in one source-level function.&lt;/p&gt;
&lt;p&gt;We compareed the &lt;code&gt;:payload&lt;/code&gt; literal with the &lt;code&gt;payload-key&lt;/code&gt; and found that both have - &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;identical content hashcode (&lt;code&gt;-383036092&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;identical name bytes &lt;code&gt;[0x70 0x61 0x79 0x6C 0x6F 0x61 0x64]&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;identical codepoints&lt;/li&gt;
&lt;li&gt;same classloader&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;so it really looks like two distinct interned &lt;code&gt;Keyword&lt;/code&gt; instances with the same name.&lt;/p&gt;
&lt;h4&gt;Environment&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;Clojure &lt;code&gt;1.12.4&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Eclipse Temurin JDK 25, Shenandoah GC, virtual threads enabled&lt;/li&gt;
&lt;li&gt;ARM64 (AWS Graviton, ECS Fargate)&lt;/li&gt;
&lt;li&gt;Aleph + Netty, transit-clj/transit-java for decoding&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;Questions&lt;/h4&gt;
&lt;ol&gt;
&lt;li&gt;Could this be a bug in JVM / Clojure runtime?&lt;/li&gt;
&lt;li&gt;Has similar behavior been seen in other cases?&lt;/li&gt;
&lt;li&gt;What more evidence could we capture?&lt;/li&gt;
&lt;/ol&gt;
</description>
<category>Clojure</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/15073/returns-while-identical-first-coexisting-keyword-instances</guid>
<pubDate>Mon, 11 May 2026 12:59:06 +0000</pubDate>
</item>
<item>
<title>`derive [tag] [parent]` accepts non namespaced keyword/symbol as `tag` ?</title>
<link>https://ask.clojure.org/index.php/14759/derive-tag-parent-accepts-non-namespaced-keyword-symbol-tag</link>
<description>&lt;p&gt;Hello &lt;/p&gt;
&lt;p&gt;&lt;code&gt;derive&lt;/code&gt;'s doc says:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;Establishes a parent/child relationship between parent and&lt;br&gt;
  tag. &lt;strong&gt;Parent must be a namespace-qualified symbol or keyword and&lt;br&gt;
  child can be either a namespace-qualified symbol or keyword or a&lt;br&gt;
  class.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;But in practice,  ClojureScript accepts non-namespaced tag:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(derive :a ::b)
; nil
(isa? :a ::b)
; true
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Clojure throws.&lt;/p&gt;
&lt;p&gt;Is ClojureScript behavior expected or a bug?&lt;/p&gt;
&lt;p&gt;Same question for the &lt;code&gt;derive [h tag parent]&lt;/code&gt; form, which seems to accept non-namespaced keyword/symbol for both tag and parent, this time on both Clojure and ClojureScript:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(derive (make-hierarchy) :a :b)
; {:parents {:a #{:b}}, :ancestors {:a #{:b}}, :descendants {:b #{:a}}}
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/14759/derive-tag-parent-accepts-non-namespaced-keyword-symbol-tag</guid>
<pubDate>Wed, 19 Nov 2025 21:23:15 +0000</pubDate>
</item>
<item>
<title>Cannot compile namespace including `+` in clojurescript</title>
<link>https://ask.clojure.org/index.php/14551/cannot-compile-namespace-including-in-clojurescript</link>
<description>&lt;p&gt;Trying to compile any namespace including &lt;code&gt;+&lt;/code&gt; fails in clojurescript&lt;/p&gt;
&lt;p&gt;e.g.:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(ns test+.core)

(println &quot;Hello, World!&quot;)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;compiled with clojurescript &quot;1.12.42&quot; &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -M --main cljs.main --compile test+.core
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;results in&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; `Namespace test+.core does not exist.`
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Trying to include the namespace from another gives:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Unexpected error (ExceptionInfo) compiling at (REPL:1).
No such namespace: test+.core, could not locate test_PLUS_/core.cljs, test_PLUS_/core.cljc, or JavaScript source providing &quot;test+.core&quot; (Please check that namespaces with dashes use underscores in the ClojureScript file name) in file /home/sigvesn/clojure/cljs-test/src/other.cljs
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Note that it is possible to compile the namespace from regular clojure.&lt;/p&gt;
&lt;p&gt;This is relevant because the &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/tonsky/clojure-plus/&quot;&gt;clojure walk library&lt;/a&gt;  uses &lt;code&gt;+&lt;/code&gt; in the namespace&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/sigvesn/cljs-ns-special-char-error&quot;&gt;Repo with code to reproduce &lt;/a&gt;&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/14551/cannot-compile-namespace-including-in-clojurescript</guid>
<pubDate>Tue, 20 May 2025 10:12:48 +0000</pubDate>
</item>
<item>
<title>Comparing ratios with BigDecimals can throw</title>
<link>https://ask.clojure.org/index.php/14411/comparing-ratios-with-bigdecimals-can-throw</link>
<description>&lt;p&gt;Observe:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(&amp;lt; 1/4 0.5M)
;=&amp;gt; true        ; as expected

(&amp;lt; 1/3 0.5M)
; Execution error (ArithmeticException) at java.math.BigDecimal/divide (BigDecimal.java:1783).
; Non-terminating decimal expansion; no exact representable decimal result.
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is because Clojure tries to coerce the ratio to a BigDecimal, which can fail.&lt;/p&gt;
&lt;p&gt;This worked (and produced expected results) in Clojure up to 1.2.1; the current behaviour is from 1.3.0 onwards. Not sure whether this is a bug or expected behaviour; in either case, I haven’t seen it documented.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&amp;gt;&lt;/code&gt;, &lt;code&gt;&amp;lt;=&lt;/code&gt;, &lt;code&gt;&amp;gt;=&lt;/code&gt; all exhibit the same behaviour. &lt;code&gt;=&lt;/code&gt; works.&lt;/p&gt;
&lt;p&gt;I’ve also noticed that &lt;code&gt;=&lt;/code&gt; can’t determine whether a ratio is equal to a bigdec, although &lt;code&gt;&amp;lt;&lt;/code&gt; and &lt;code&gt;&amp;gt;&lt;/code&gt; do sometimes produce a good answer:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;((juxt &amp;lt; = &amp;gt;) 1/2 0.5M)
;=&amp;gt; [false false false]

((juxt &amp;lt; = &amp;gt;) 1/4 0.5M)
;=&amp;gt; [true false false]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The same is true of ratios and doubles:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;((juxt &amp;lt; = &amp;gt;) 1/2 0.5M)
;=&amp;gt; [false false false]

((juxt &amp;lt; = &amp;gt;) 1/4 0.5M)
;=&amp;gt; [true false false]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This seems contrary to the docstring of &lt;code&gt;=&lt;/code&gt;, which states that „[it] compares numbers and collections in a type-independent manner”.&lt;/p&gt;
</description>
<category>Compiler</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/14411/comparing-ratios-with-bigdecimals-can-throw</guid>
<pubDate>Fri, 21 Feb 2025 20:52:49 +0000</pubDate>
</item>
<item>
<title>clojure.pprint/pprint bug when using the code-dispatch table</title>
<link>https://ask.clojure.org/index.php/13455/clojure-pprint-pprint-bug-when-using-the-code-dispatch-table</link>
<description>&lt;p&gt;There seams to be a bug in clojure.pprint/pprint when using the code-dispatch table  and printing let. It happens on Clojure and ClojureScript.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Clojure 1.11.1
user=&amp;gt; (require '[clojure.pprint :as pp])

user=&amp;gt; 
(binding [pp/*print-pprint-dispatch* pp/code-dispatch]
  (pp/pprint
   '(let)))

((let)) ;; prints some extra parenthesis

(binding [pp/*print-pprint-dispatch* pp/code-dispatch]
  (pp/pprint
   '(let*)))

(let*) ;; doesn't happen when pprinting any other form
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Printing</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/13455/clojure-pprint-pprint-bug-when-using-the-code-dispatch-table</guid>
<pubDate>Fri, 10 Nov 2023 14:06:05 +0000</pubDate>
</item>
<item>
<title>Clojurescript issue in 1.11.121 and master when compiling</title>
<link>https://ask.clojure.org/index.php/13279/clojurescript-issue-in-1-11-121-and-master-when-compiling</link>
<description>&lt;p&gt;When compiling a file with :&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -Sdeps '{:paths [&quot;src&quot;] :deps {org.clojure/clojurescript {:mvn/version &quot;1.11.121&quot;}}}' -M -m cljs.main -co '{:main org.foo.myscript}' --compile
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;the compilation will work fine, but if after that you run cljs.main --repl the browser repl will start, but evaluating forms on it will not work since evaluation will never finish.&lt;/p&gt;
&lt;p&gt;This exact same commands work fine in 1.11.60.&lt;/p&gt;
&lt;p&gt;After some debugging the issue seems to be caused by the current compiler never adding &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;document.write('&amp;lt;script&amp;gt;goog.require(&quot;clojure.browser.repl.preload&quot;);&amp;lt;/script&amp;gt;'); 
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;to the resulting js file.&lt;/p&gt;
&lt;p&gt;This is caused by :&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojurescript/blob/master/src/main/clojure/cljs/closure.clj#L2500-L2501&quot;&gt;https://github.com/clojure/clojurescript/blob/master/src/main/clojure/cljs/closure.clj#L2500-L2501&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;not adding the preload because :browser-repl isn't true. &lt;/p&gt;
&lt;p&gt;The breaking change comes from this line:&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojurescript/blob/master/src/main/clojure/cljs/cli.clj#L498&quot;&gt;https://github.com/clojure/clojurescript/blob/master/src/main/clojure/cljs/cli.clj#L498&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;which removes :browser-repl from the options because we are just compiling and there is no repl involved.&lt;/p&gt;
&lt;p&gt;Looks like the behavior was explicitly changed by this commit :&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojurescript/commit/9c01d9b0a70ada1cb17cf3ce65ae93d76d0d3b08&quot;&gt;https://github.com/clojure/clojurescript/commit/9c01d9b0a70ada1cb17cf3ce65ae93d76d0d3b08&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Reverting the commit fixes the issue.&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/13279/clojurescript-issue-in-1-11-121-and-master-when-compiling</guid>
<pubDate>Tue, 12 Sep 2023 22:01:58 +0000</pubDate>
</item>
<item>
<title>Why doesn't `type` in CLJS check `:type` on its arguments meta like CLJ does?</title>
<link>https://ask.clojure.org/index.php/13095/why-doesnt-type-cljs-check-type-its-arguments-meta-like-does</link>
<description>&lt;p&gt;In CLJ a check for &lt;code&gt;:type&lt;/code&gt; on the meta happens and then falls back to returning the constructor class. In CLJS only the constructor class is returned. It would be nice to have these consistent for usage with multimethods etc. &lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/13095/why-doesnt-type-cljs-check-type-its-arguments-meta-like-does</guid>
<pubDate>Sun, 23 Jul 2023 14:56:02 +0000</pubDate>
</item>
<item>
<title>Locals clearing issue with a type-hinted vs non-type-hinted letfn?</title>
<link>https://ask.clojure.org/index.php/13019/locals-clearing-issue-with-type-hinted-non-type-hinted-letfn</link>
<description>&lt;p&gt;Hey folks - I seem to be getting a locals clearing issue with a type-hinted vs non-type-hinted &lt;code&gt;letfn&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(defn- letfn-prim []
  (letfn [(f [coll ^long n]
            )]
    (f (take 3 (range)) 0)))

(defn- letfn-noprim []
  (letfn [(f [coll n]
            )]
    (f (take 3 (range)) 0)))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;(in practice, I'm lazily processing coll within &lt;code&gt;f&lt;/code&gt; and wanted to avoid retaining the head)&lt;/p&gt;
&lt;p&gt;The noprim variant clears the coll param correctly; the prim version doesn't seem to.&lt;/p&gt;
&lt;p&gt;(I'm aware &lt;code&gt;letfn&lt;/code&gt; doesn't fully support type-hints, but this one seems to be more than just an unexpected boxing, and affects more than just the hinted variable)&lt;/p&gt;
&lt;p&gt;In both cases, the caller is calling &lt;code&gt;f.invoke(Object)&lt;/code&gt; (&lt;code&gt;invokeinterface clojure/lang/IFn.invoke:(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;&lt;/code&gt;), but the difference comes in the &lt;code&gt;f&lt;/code&gt; function. (Arguably the hinted version could call &lt;code&gt;invokePrim&lt;/code&gt; directly, but as I say, aware &lt;code&gt;letfn&lt;/code&gt; doesn't fully support type-hints)&lt;/p&gt;
&lt;p&gt;In the unhinted case, &lt;code&gt;invoke&lt;/code&gt; is trivial:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  public java.lang.Object invoke(java.lang.Object, java.lang.Object);
    Code:
       0: aconst_null
       1: areturn
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;(adding more of a body clears the param as soon as it can)&lt;/p&gt;
&lt;p&gt;but in the hinted case, we get this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  public final java.lang.Object invokePrim(java.lang.Object, long);
    Code:
       0: aconst_null
       1: areturn

  public java.lang.Object invoke(java.lang.Object, java.lang.Object);
    Code:
       0: aload_0
       1: aload_1
       2: aload_2
       3: checkcast     #22                 // class java/lang/Number
       6: invokestatic  #28                 // Method clojure/lang/RT.longCast:(Ljava/lang/Object;)J
       9: invokeinterface #30,  4           // InterfaceMethod clojure/lang/IFn$OLO.invokePrim:(Ljava/lang/Object;J)Ljava/lang/Object;
      14: areturn
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The &lt;code&gt;invoke&lt;/code&gt; calls through to &lt;code&gt;invokePrim&lt;/code&gt; as normal, but it doesn't clear its locals before doing so. compare to&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(defn- defn-prim [coll ^long n]
  )
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;whose bytecode does clear the object in its invoke method:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  public static java.lang.Object invokeStatic(java.lang.Object, long);
    Code:
       0: aconst_null
       1: areturn

  public java.lang.Object invoke(java.lang.Object, java.lang.Object);
    Code:
       0: aload_1
       1: aconst_null
       2: astore_1      // &amp;lt;--- local cleared here
       3: aload_2
       4: checkcast     #21                 // class java/lang/Number
       7: invokestatic  #27                 // Method clojure/lang/RT.longCast:(Ljava/lang/Object;)J
      10: invokestatic  #29                 // Method invokeStatic:(Ljava/lang/Object;J)Ljava/lang/Object;
      13: areturn

  public final java.lang.Object invokePrim(java.lang.Object, long);
    Code:
       0: aload_1
       1: aconst_null
       2: astore_1
       3: lload_2
       4: invokestatic  #29                 // Method invokeStatic:(Ljava/lang/Object;J)Ljava/lang/Object;
       7: areturn
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Cheers!&lt;/p&gt;
&lt;p&gt;James&lt;/p&gt;
</description>
<category>Clojure</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/13019/locals-clearing-issue-with-type-hinted-non-type-hinted-letfn</guid>
<pubDate>Fri, 16 Jun 2023 16:19:58 +0000</pubDate>
</item>
<item>
<title>Why does this work in CLJS but doesn't in JVM Clojure?</title>
<link>https://ask.clojure.org/index.php/12903/why-does-this-work-in-cljs-but-doesnt-in-jvm-clojure</link>
<description>&lt;p&gt;This looks like a bug in ClojureScript 1.11.54 :&lt;/p&gt;
&lt;p&gt;&lt;code&gt;(conj {} [:a 1] '([:b 2] [:c 3]) '([:d 4]))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;In Clojure on the JVM this is an error:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;cljs.user&amp;gt; (conj {} [:a 1] '([:b 2] [:c 3]) '([:d 4]))
{:a 1, :b 2, :c 3, :d 4}
cljs.user&amp;gt; :cljs/quit
nil
user&amp;gt; (conj {} [:a 1] '([:b 2] [:c 3]) '([:d 4]))
Execution error (ClassCastException) at user/eval17754 (REPL:25).
class clojure.lang.PersistentVector cannot be cast to class java.util.Map$Entry (clojure.lang.PersistentVector is in unnamed module of loader 'app'; java.util.Map$Entry is in module java.base of loader 'bootstrap')
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/12903/why-does-this-work-in-cljs-but-doesnt-in-jvm-clojure</guid>
<pubDate>Thu, 27 Apr 2023 19:12:03 +0000</pubDate>
</item>
<item>
<title>let binding does not infer primitive type of type hinted global var</title>
<link>https://ask.clojure.org/index.php/12599/let-binding-does-not-infer-primitive-type-type-hinted-global</link>
<description>&lt;p&gt;When you type hint a var such as:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def ^{:tag 'long} k 100)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;And refer to it in a &lt;code&gt;let&lt;/code&gt; binding:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(let [i k]
  (+ i 10))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The binding is unable to properly infer that it is a primitive type as it was hinted:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(set! *unchecked-math* :warn-on-boxed)
(def ^{:tag 'long} k 100)
(let [i k]
  (+ i 10))
;;=&amp;gt; Boxed math warning, unchecked_add(java.lang.Object,long).
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It looks like it might be caused by a bug in the Compiler where for some reason, the expression of the var k is marked as not having a java class, even though it has one:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(defmacro inspect-local []
  (println
   (into {}
         (map (fn[[k v]]
                [k {:tag (.-tag v)
                    :class (.getJavaClass v)
                    :primitive? (.isPrimitive (.getJavaClass v))
                    :has-java-class? (.hasJavaClass v)}]))
         &amp;amp;env)))

(let [i k]
  (inspect-local)
  (+ i 10))

;;=&amp;gt; {i {:tag nil, :class long, :primitive? true, :has-java-class? false}}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;As we can see, &lt;code&gt;.hasJavaClass&lt;/code&gt; returns false, but &lt;code&gt;.getJavaClass&lt;/code&gt; returns the &lt;code&gt;Long/TYPE&lt;/code&gt; class.&lt;/p&gt;
&lt;p&gt;I suspect that the compiler checks for &lt;code&gt;.hasJavaClass&lt;/code&gt; before calling &lt;code&gt;.getJavaClass&lt;/code&gt;, and since &lt;code&gt;.hasJavaClass&lt;/code&gt; is erroneously false here, it would cause the compiler to think it isn't, and that the type can't be inferred.&lt;/p&gt;
&lt;p&gt;I'm not too sure where in the Compiler this is, but I found the following: &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/Compiler.java#L1341&quot;&gt;https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/Compiler.java#L1341&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Where we see the compiler is first checking for &lt;code&gt;.hasJavaClass&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; if(e instanceof MaybePrimitiveExpr &amp;amp;&amp;amp; e.hasJavaClass() &amp;amp;&amp;amp; ((MaybePrimitiveExpr)e).canEmitPrimitive())
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Compiler</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/12599/let-binding-does-not-infer-primitive-type-type-hinted-global</guid>
<pubDate>Mon, 30 Jan 2023 03:23:21 +0000</pubDate>
</item>
<item>
<title>`(s/merge X Y)` disables conformation for `:*-un` keys in X</title>
<link>https://ask.clojure.org/index.php/12573/s-merge-x-y-disables-conformation-for-un-keys-in-x</link>
<description>&lt;p&gt;When merging map specs with unqualified keys, only the last spec retains its conformation behavior:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(s/def ::int-or-string (s/or :int int? :str string?))
(s/def ::a ::int-or-string)
(s/def ::b ::int-or-string)
(s/def ::a-un (s/keys :opt-un [::a]))
(s/def ::b-un (s/keys :opt-un [::b]))
(s/def ::merge-un (s/merge ::a-un ::b-un))
(s/conform ::merge-un {:a 100 :b &quot;foo&quot;})
;;=&amp;gt; {:a 100, :b [:str &quot;foo&quot;]}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Compare the behavior with qualified keys:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(s/def ::a-qual (s/keys :opt [::a]))
(s/def ::b-qual (s/keys :opt [::b]))
(s/def ::merge-qual (s/merge ::a-qual ::b-qual))
(s/conform ::merge-qual {::a 100 ::b &quot;foo&quot;})
;;=&amp;gt; #:user{:a [:int 100], :b [:str &quot;foo&quot;]}
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Spec</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/12573/s-merge-x-y-disables-conformation-for-un-keys-in-x</guid>
<pubDate>Sat, 21 Jan 2023 22:21:34 +0000</pubDate>
</item>
<item>
<title>CLI on Powershell cannot read piped input</title>
<link>https://ask.clojure.org/index.php/12533/cli-on-powershell-cannot-read-piped-input</link>
<description>&lt;p&gt;On Powershell, when you run the command&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Write-Output 'foo' | clojure -M -e '(println (slurp *in*))'
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;the process hangs and waits for interactive input, rather than printing the piped input.&lt;/p&gt;
&lt;p&gt;This seems to be because the calls to &lt;code&gt;java&lt;/code&gt; in &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/brew-install/blob/bf8df5c0761c366fdcd1c6338bb1a9eb29371d29/src/main/resources/clojure/install/ClojureTools.psm1#L443-L454&quot;&gt;the Powershell implementation&lt;/a&gt; of &lt;code&gt;clj&lt;/code&gt;/&lt;code&gt;clojure&lt;/code&gt; do not explicitly hand over &lt;code&gt;$Input&lt;/code&gt; when it is bound.&lt;/p&gt;
&lt;p&gt;Based on &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/PowerShell/PowerShell/issues/9497#issuecomment-1246179450&quot;&gt;this discussion&lt;/a&gt; on a similar issue, this proof of concept demonstrates a potential fix:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;PS&amp;gt; Get-Content clj.ps1
if ($MyInvocation.ExpectingInput) {
        $Input | java -classpath &quot;$(clojure -Spath)&quot; clojure.main -e '(println (slurp *in*))'
} else {
        java -classpath &quot;$(clojure -Spath)&quot; clojure.main -e '(println (slurp *in*))'
}
PS&amp;gt; Write-Output 'foo' | .\clj.ps1
foo

PS&amp;gt; .\clj.ps1
This text was supplied interactively, followed by a ^C
This text was supplied interactively, followed by a ^C

PS&amp;gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;h/t @hiredman on the Clojurians Slack for finding that GitHub discussion&lt;/p&gt;
</description>
<category>Clojure CLI</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/12533/cli-on-powershell-cannot-read-piped-input</guid>
<pubDate>Tue, 10 Jan 2023 01:13:51 +0000</pubDate>
</item>
<item>
<title>Pesky loop bug resulting in 0xFFFFFFFF with BufferedReader (java interop)</title>
<link>https://ask.clojure.org/index.php/11415/pesky-loop-resulting-0xffffffff-with-bufferedreader-interop</link>
<description>&lt;p&gt;Hello --&lt;/p&gt;
&lt;p&gt;I'm learning Clojure and its Java interop stuff. I am trying to emulate this function:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; public String readAllCharsOneByOne(BufferedReader bufferedReader) throws IOException {
    StringBuilder content = new StringBuilder();
       
    int value;
    while ((value = bufferedReader.read()) != -1) {
        content.append((char) value);
    }
       
    return content.toString();
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;So far, I've been able to reason that the parts I need are:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def myfile &quot;/path/to/svenska_sample.txt&quot;)
(import java.io.BufferedReader)
(import java.io.FileReader)
(import java.lang.StringBuilder)
(import java.lang.Character)
 
(def a-FileReader (FileReader. myfile))
(def bufferedReader (BufferedReader. a-FileReader))
(def content (StringBuilder.))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;which works&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDe&quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen&quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen &quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen t&quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen ty&quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen typ&quot;]
user&amp;gt; (.append content (Character/toChars (.read bufferedReader)))
#object[java.lang.StringBuilder 0x490447d0 &quot;\nDen typi&quot;]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The file is a small text file UTF-8 encoded in Linux with the following content:&lt;/p&gt;
&lt;p&gt;❯ cat svenska_sample.txt&lt;/p&gt;
&lt;p&gt;Den typiska impulsiva olycksfågeln är en ung man som kraschar flera bilar, och ofta skryter lite med det, i varje fall när han är tillsammans med sina vänner._. För dem har otur i det närmaste blivit en livsstil, och de råkar konstant ut för olyckor, stora som små. Olycksfåglar kallar vi dem. Hur många det finns kan ingen med säkerhet säga, för det finns inga konkreta definitioner på denna grupp, och heller ingen given avgränsning av den. Att de finns, råder det emellertid ingen tvekan om, varken på sjukhusens akutmottagningar eller i försäkringsbranschen&lt;/p&gt;
&lt;p&gt;I wrote a function, with my brand new Clojure Java interop chops, that looks like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;;; COMPILES  - BUT CAN'T GET AROUND THE 0XFFFFFFF BUG
(defn pt%% [file]
   (let [afr (FileReader. file); instances of FileReader, BufferedReader, StringBuffer
         bfr (BufferedReader. afr)
         ct (StringBuilder.)
         val (.read bfr)
         this-list (list afr bfr ct)]
         ; (apply println this-list)
         (loop []
               (when (not (= val -1))
                 (.append ct (Character/toChars (.read bfr))))
               (recur))
                ; when finished...
         (.toString ct)))
     
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;but it borks with the following error:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;user&amp;gt; (pt%% myfile)
Execution error (IllegalArgumentException) at java.lang.Character/toChars (Character.java:8572).
Not a valid Unicode code point: 0xFFFFFFFF
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;What in the world could be causing this (NOTE: I am not a Java programmer)?&lt;br&gt;
Here is the hex dump of the file text file:&lt;/p&gt;
&lt;p&gt;❯ cat svenska_sample.hexdump&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;00000000: 0a44 656e 2074 7970 6973 6b61 2069 6d70  .Den typiska imp
00000010: 756c 7369 7661 206f 6c79 636b 7366 c3a5  ulsiva olycksf..
00000020: 6765 6c6e 20c3 a472 2065 6e20 756e 6720  geln ..r en ung
00000030: 6d61 6e20 736f 6d20 6b72 6173 6368 6172  man som kraschar
00000040: 2066 6c65 7261 2062 696c 6172 2c20 6f63   flera bilar, oc
00000050: 6820 6f66 7461 2073 6b72 7974 6572 206c  h ofta skryter l
00000060: 6974 6520 6d65 6420 6465 742c 2069 2076  ite med det, i v
00000070: 6172 6a65 2066 616c 6c20 6ec3 a472 2068  arje fall n..r h
00000080: 616e 20c3 a472 2074 696c 6c73 616d 6d61  an ..r tillsamma
00000090: 6e73 206d 6564 2073 696e 6120 76c3 a46e  ns med sina v..n
000000a0: 6e65 722e 5f2e 2046 c3b6 7220 6465 6d20  ner._. F..r dem
000000b0: 6861 7220 6f74 7572 2069 2064 6574 206e  har otur i det n
000000c0: c3a4 726d 6173 7465 2062 6c69 7669 7420  ..rmaste blivit
000000d0: 656e 206c 6976 7373 7469 6c2c 206f 6368  en livsstil, och
000000e0: 2064 6520 72c3 a56b 6172 206b 6f6e 7374   de r..kar konst
000000f0: 616e 7420 7574 2066 c3b6 7220 6f6c 7963  ant ut f..r olyc
00000100: 6b6f 722c 2073 746f 7261 2073 6f6d 2073  kor, stora som s
00000110: 6dc3 a52e 204f 6c79 636b 7366 c3a5 676c  m... Olycksf..gl
00000120: 6172 206b 616c 6c61 7220 7669 2064 656d  ar kallar vi dem
00000130: 2e20 4875 7220 6dc3 a56e 6761 2064 6574  . Hur m..nga det
00000140: 2066 696e 6e73 206b 616e 2069 6e67 656e   finns kan ingen
00000150: 206d 6564 2073 c3a4 6b65 7268 6574 2073   med s..kerhet s
00000160: c3a4 6761 2c20 66c3 b672 2064 6574 2066  ..ga, f..r det f
00000170: 696e 6e73 2069 6e67 6120 6b6f 6e6b 7265  inns inga konkre
00000180: 7461 2064 6566 696e 6974 696f 6e65 7220  ta definitioner
00000190: 70c3 a520 6465 6e6e 6120 6772 7570 702c  p.. denna grupp,
000001a0: 206f 6368 2068 656c 6c65 7220 696e 6765   och heller inge
000001b0: 6e20 6769 7665 6e20 6176 6772 c3a4 6e73  n given avgr..ns
000001c0: 6e69 6e67 2061 7620 6465 6e2e 2041 7474  ning av den. Att
000001d0: 2064 6520 6669 6e6e 732c 2072 c3a5 6465   de finns, r..de
000001e0: 7220 6465 7420 656d 656c 6c65 7274 6964  r det emellertid
000001f0: 2069 6e67 656e 2074 7665 6b61 6e20 6f6d   ingen tvekan om
00000200: 2c20 7661 726b 656e 2070 c3a5 2073 6a75  , varken p.. sju
00000210: 6b68 7573 656e 7320 616b 7574 6d6f 7474  khusens akutmott
00000220: 6167 6e69 6e67 6172 2065 6c6c 6572 2069  agningar eller i
00000230: 2066 c3b6 7273 c3a4 6b72 696e 6773 6272   f..rs..kringsbr
00000240: 616e 7363 6865 6e0a                      anschen.
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I then changed the code (see below), because of some suggestions that the problem might be my use of recur.&lt;/p&gt;
&lt;p&gt;And now it complains that a previous form that was working '(.append etc..') doesn't and the same error remains. &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;user&amp;gt; (pt5 myfile)

Execution error (IllegalArgumentException) at java.lang.Character/toChars (Character.java:8572).
Not a valid Unicode code point: 0xFFFFFFFF

(defn pt5 [file]

   (let [afr (FileReader. file); instances of FileReader, BufferedReader, StringBuffer
         bfr (BufferedReader. afr)
         ct (StringBuilder.)
         this-list (list afr bfr ct)]
         ; (apply println this-list)
         (loop [val (.read bfr)]
               (when (not (= val -1))
                 (.append ct (Character/toChars (.read bfr))))
               (recur val))
                ; when finished...
                (.toString ct)))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Harder then it seemed at first sight...&lt;br&gt;
Any help is greatly appreciated.`&lt;br&gt;
-- Hank&lt;/p&gt;
</description>
<category>Java Interop</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11415/pesky-loop-resulting-0xffffffff-with-bufferedreader-interop</guid>
<pubDate>Sun, 26 Dec 2021 13:20:55 +0000</pubDate>
</item>
<item>
<title>Bug in ClojureScript type inference?</title>
<link>https://ask.clojure.org/index.php/11362/bug-in-clojurescript-type-inference</link>
<description>&lt;p&gt;Further to a recent conversation in the ClojureScript topic in Slack, Dan Sutton suggested that I create an issue here.&lt;/p&gt;
&lt;p&gt;I think I may have found a bug in ClojureScript's type inference. I've created a minimal reproduction here:&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/paulbutcher/clojurescript-type-inference-bug&quot;&gt;https://github.com/paulbutcher/clojurescript-type-inference-bug&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The following code generates a warning:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  cljs.core/-, all arguments must be numbers, got [#{js/clj-nil clj-nil} #{js/clj-nil clj-nil}] instead
  (- (ocall js/Math :random) (ocall js/Math :random))
  ^---
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I would expect that I could fix it like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(- ^js/number (ocall js/Math :random) ^js/number (ocall js/Math :random))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;But that gives me exactly the same error.&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11362/bug-in-clojurescript-type-inference</guid>
<pubDate>Tue, 07 Dec 2021 00:21:00 +0000</pubDate>
</item>
<item>
<title>tools.build uber's default conflict handlers don't append to META-INF/services properly</title>
<link>https://ask.clojure.org/index.php/11316/tools-default-conflict-handlers-append-services-properly</link>
<description>&lt;p&gt;Our project has some dependencies that register parsers for various file formats via the java services framework.&lt;/p&gt;
&lt;p&gt;We’re using &lt;code&gt;b/uber&lt;/code&gt; and are finding some &lt;code&gt;META-INF/services/&lt;/code&gt; definitions are not correctly being appended.  &lt;/p&gt;
&lt;p&gt;I’ve chased this down to the regex in the default-handlers being &lt;code&gt;^META-INF/services/&lt;/code&gt; instead of something more like &lt;code&gt;^META-INF/services/.*&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;The current regex would match under &lt;code&gt;re-find&lt;/code&gt;, but not under &lt;code&gt;re-matches&lt;/code&gt; which the implementation uses.&lt;/p&gt;
</description>
<category>tools.build</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11316/tools-default-conflict-handlers-append-services-properly</guid>
<pubDate>Fri, 26 Nov 2021 17:29:12 +0000</pubDate>
</item>
<item>
<title>tools.build uber task fails when the dependency tree contains a dep which has no jar</title>
<link>https://ask.clojure.org/index.php/11156/tools-build-uber-task-fails-when-dependency-contains-which</link>
<description>&lt;p&gt;The &lt;code&gt;clojure.tools.build.api/uber&lt;/code&gt; task fails when the dependency tree contains a dep which has no jar.  &lt;/p&gt;
&lt;p&gt;A relatively minimal failing test case is the following tools.build task:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(ns build 
  (:require [clojure.tools.build.api :as b]))

(defn failing-uber [_]
    (b/uber {:class-dir &quot;classes&quot;
     :uber-file &quot;foo.jar&quot;
     :basis (b/create-basis {:project {:deps {'org.apache.jena/apache-jena-libs {:mvn/version &quot;4.2.0&quot; :extension &quot;pom&quot;} }}})})

(comment 
   (failing-uber {})
 )
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Evaluating the above function results in the following exception:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;1. Unhandled clojure.lang.ExceptionInfo
   Unexpected lib file:
   /Users/rick/.m2/repository/org/apache/jena/apache-jena-libs/4.2.0/apache-jena-libs-4.2.0.pom
   {}
                  uber.clj:  182  clojure.tools.build.tasks.uber/explode
                  uber.clj:  141  clojure.tools.build.tasks.uber/explode
                  uber.clj:  257  clojure.tools.build.tasks.uber/uber/fn/fn
     PersistentVector.java:  343  clojure.lang.PersistentVector/reduce
                  core.clj: 6829  clojure.core/reduce
                  core.clj: 6812  clojure.core/reduce
                  uber.clj:  256  clojure.tools.build.tasks.uber/uber/fn
             protocols.clj:   49  clojure.core.protocols/iter-reduce
             protocols.clj:   75  clojure.core.protocols/fn
             protocols.clj:   75  clojure.core.protocols/fn
             protocols.clj:   13  clojure.core.protocols/fn/G
                  core.clj: 6830  clojure.core/reduce
                  core.clj: 6812  clojure.core/reduce
                  uber.clj:  254  clojure.tools.build.tasks.uber/uber
                  uber.clj:  241  clojure.tools.build.tasks.uber/uber
                  Var.java:  384  clojure.lang.Var/invoke
                   api.clj:  394  clojure.tools.build.api/uber
                   api.clj:  339  clojure.tools.build.api/uber
                      REPL:   21  build/eval25043
                      REPL:   21  build/eval25043
             Compiler.java: 7181  clojure.lang.Compiler/eval
             Compiler.java: 7136  clojure.lang.Compiler/eval
                  core.clj: 3202  clojure.core/eval
                  core.clj: 3198  clojure.core/eval
    interruptible_eval.clj:   87  nrepl.middleware.interruptible-eval/evaluate/fn/fn
                  AFn.java:  152  clojure.lang.AFn/applyToHelper
                  AFn.java:  144  clojure.lang.AFn/applyTo
                  core.clj:  667  clojure.core/apply
                  core.clj: 1977  clojure.core/with-bindings*
                  core.clj: 1977  clojure.core/with-bindings*
               RestFn.java:  425  clojure.lang.RestFn/invoke
    interruptible_eval.clj:   87  nrepl.middleware.interruptible-eval/evaluate/fn
                  main.clj:  437  clojure.main/repl/read-eval-print/fn
                  main.clj:  437  clojure.main/repl/read-eval-print
                  main.clj:  458  clojure.main/repl/fn
                  main.clj:  458  clojure.main/repl
                  main.clj:  368  clojure.main/repl
               RestFn.java:  137  clojure.lang.RestFn/applyTo
                  core.clj:  667  clojure.core/apply
                  core.clj:  662  clojure.core/apply
                regrow.clj:   20  refactor-nrepl.ns.slam.hound.regrow/wrap-clojure-repl/fn
               RestFn.java: 1523  clojure.lang.RestFn/invoke
    interruptible_eval.clj:   84  nrepl.middleware.interruptible-eval/evaluate
    interruptible_eval.clj:   56  nrepl.middleware.interruptible-eval/evaluate
    interruptible_eval.clj:  152  nrepl.middleware.interruptible-eval/interruptible-eval/fn/fn
                  AFn.java:   22  clojure.lang.AFn/run
               session.clj:  202  nrepl.middleware.session/session-exec/main-loop/fn
               session.clj:  201  nrepl.middleware.session/session-exec/main-loop
                  AFn.java:   22  clojure.lang.AFn/run
               Thread.java:  825  java.lang.Thread/run
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I believe this is because the above dependency has no corresponding jar file, and only contains a pom.xml which groups up a set of dependencies.&lt;/p&gt;
</description>
<category>tools.build</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11156/tools-build-uber-task-fails-when-dependency-contains-which</guid>
<pubDate>Tue, 12 Oct 2021 14:00:42 +0000</pubDate>
</item>
<item>
<title>Should tools.build functions respect with-dir (from tools.deps.alpha)?</title>
<link>https://ask.clojure.org/index.php/11027/should-tools-build-functions-respect-with-from-tools-alpha</link>
<description>&lt;p&gt;I ran across this issue with &lt;code&gt;depstar&lt;/code&gt; but observed that &lt;code&gt;tools.build&lt;/code&gt; behaves the same, possibly incorrect, way.&lt;/p&gt;
&lt;p&gt;See &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/seancorfield/with-dir-repro&quot;&gt;https://github.com/seancorfield/with-dir-repro&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;If you wrap &lt;code&gt;(b/create-basis ..)&lt;/code&gt; in &lt;code&gt;with-dir&lt;/code&gt; from &lt;code&gt;tools.deps.alpha&lt;/code&gt;, it calculates the basis from the &lt;code&gt;deps.edn&lt;/code&gt; file in the context of the &lt;code&gt;with-dir&lt;/code&gt; location.&lt;/p&gt;
&lt;p&gt;However, if you use that basis with &lt;code&gt;tools.build&lt;/code&gt; functions, they do not behave correctly -- even if they are also wrapped in the same &lt;code&gt;with-dir&lt;/code&gt; context.&lt;/p&gt;
&lt;p&gt;The dependencies come from the project &lt;code&gt;deps.edn&lt;/code&gt; (Clojure 1.9.0 in this example) but the &lt;code&gt;src&lt;/code&gt; used is from the root of the repo, not from the project folder.&lt;/p&gt;
&lt;p&gt;This is counter-intuitive (and took me a while to track down with &lt;code&gt;depstar&lt;/code&gt; -- where I definitely consider it to be a bug).&lt;/p&gt;
</description>
<category>tools.build</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11027/should-tools-build-functions-respect-with-from-tools-alpha</guid>
<pubDate>Wed, 08 Sep 2021 22:02:10 +0000</pubDate>
</item>
<item>
<title>symbol collision bug in clojurescript?</title>
<link>https://ask.clojure.org/index.php/10886/symbol-collision-bug-in-clojurescript</link>
<description>&lt;p&gt;This this expression in a clojurescript repl:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(let [{:keys [a-b a_b]} {:a-b 0 :a_b 1}] [a-b a_b])
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;will surprisingly return:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;[1 1]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I did some further investigation by creating a clean project like in Clojurescript official guide:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(ns helloworld.core)

;; two identical code blocks

;; first one is at top level
(let [{:keys [a-b a_b]} {:a-b 0 :a_b 1}] [a-b a_b])
;; second one nested inside a function call
(println (let [{:keys [a-b a_b]} {:a-b 0 :a_b 1}] [a-b a_b]))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;and compiled with:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -M --main cljs.main --compile helloworld.core
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;here's the js file:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;// Compiled by ClojureScript 1.10.866 {:optimizations :none}
goog.provide('helloworld.core');
goog.require('cljs.core');
var map__528_529 = new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,&quot;a-b&quot;,&quot;a-b&quot;,-1660985764),(0),new cljs.core.Keyword(null,&quot;a_b&quot;,&quot;a_b&quot;,-1795286609),(1)], null);
var map__528_530__$1 = cljs.core.__destructure_map.call(null,map__528_529);
var a_b_531 = cljs.core.get.call(null,map__528_530__$1,new cljs.core.Keyword(null,&quot;a-b&quot;,&quot;a-b&quot;,-1660985764));
var a_b_532 = cljs.core.get.call(null,map__528_530__$1,new cljs.core.Keyword(null,&quot;a_b&quot;,&quot;a_b&quot;,-1795286609));
new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [a_b_531,a_b_532], null);
cljs.core.println.call(null,(function (){var map__533 = new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,&quot;a-b&quot;,&quot;a-b&quot;,-1660985764),(0),new cljs.core.Keyword(null,&quot;a_b&quot;,&quot;a_b&quot;,-1795286609),(1)], null);
var map__533__$1 = cljs.core.__destructure_map.call(null,map__533);
var a_b = cljs.core.get.call(null,map__533__$1,new cljs.core.Keyword(null,&quot;a-b&quot;,&quot;a-b&quot;,-1660985764));
var a_b = cljs.core.get.call(null,map__533__$1,new cljs.core.Keyword(null,&quot;a_b&quot;,&quot;a_b&quot;,-1795286609));
return new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [a_b,a_b], null);
})());

//# sourceMappingURL=core.js.map
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;as you can see:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;the &lt;code&gt;a-b&lt;/code&gt; and &lt;code&gt;a_b&lt;/code&gt; symbols in first block ended up as &lt;code&gt;var a_b_531&lt;/code&gt; and &lt;code&gt;var a_b_532&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;in the second block they both ended up as &lt;code&gt;var a_b&lt;/code&gt;, therefore their values collided.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I also get the same result with macroexpanded version using &lt;code&gt;cljs.core/let*&lt;/code&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(let* [m {:a-b 0, :a_b 1}
       a-b
       (cljs.core/get m :a-b)
       a_b
       (cljs.core/get m :a_b)]
  [a-b a_b])

(println 
 (let* [m {:a-b 0, :a_b 1}
        a-b
        (cljs.core/get m :a-b)
        a_b
        (cljs.core/get m :a_b)]
   [a-b a_b]))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;so we can eliminate the case that something is wrong with &lt;code&gt;cljs.core/let&lt;/code&gt; macro&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/10886/symbol-collision-bug-in-clojurescript</guid>
<pubDate>Thu, 29 Jul 2021 11:01:41 +0000</pubDate>
</item>
<item>
<title>tools.build create-basis cannot use alias that includes tools.deps.alpha</title>
<link>https://ask.clojure.org/index.php/10852/tools-build-create-basis-cannot-alias-includes-tools-alpha</link>
<description>&lt;p&gt;If you try to call &lt;code&gt;create-basis&lt;/code&gt; with an alias that involves &lt;code&gt;tools.deps.alpha&lt;/code&gt;, you get the following exception:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Execution error (ExceptionInfo) at clojure.tools.deps.alpha.extensions.maven/get-artifact (maven.clj:133).
Could not find artifact org.clojure:tools.deps.alpha:jar:${project.version} in central (https://repo1.maven.org/maven2/)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is because &lt;code&gt;tools.build&lt;/code&gt; includes a source version of &lt;code&gt;deps.edn&lt;/code&gt; with that string, instead of a version number:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;./tools.build/src/main/resources/clojure/tools/deps/deps.edn
    :deps {:extra-deps {org.clojure/tools.deps.alpha {:mvn/version &quot;${project.version}&quot;}}}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Here's the minimal repro: in an otherwise empty directory:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;;; deps.edn 
{:aliases
 {:build
  {:deps {io.github.clojure/tools.build {:git/tag &quot;v0.1.6&quot; :git/sha &quot;5636e61&quot;}}
   :ns-default build}}}

;; build.clj 
(ns build
  (:require [clojure.tools.build.api :as b]))

(defn bug [_]
  (b/create-basis {:aliases [:deps]}))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Then run:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clojure -T:build bug
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Given that &lt;code&gt;tools.build&lt;/code&gt; already explicitly depends on t.d.a as follows, I don't understand why it also needs a copy of t.d.a's &lt;code&gt;deps.edn&lt;/code&gt; source in in the &lt;code&gt;resources&lt;/code&gt; tree?&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;org.clojure/tools.deps.alpha {:mvn/version &quot;0.12.1003&quot;}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Removing that file from the checked out &lt;code&gt;tools.build&lt;/code&gt; (under &lt;code&gt;~/.gitlibs/libs&lt;/code&gt;) seems to solve the problem and doesn't &lt;em&gt;appear&lt;/em&gt; to break anything else...&lt;/p&gt;
</description>
<category>tools.build</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/10852/tools-build-create-basis-cannot-alias-includes-tools-alpha</guid>
<pubDate>Mon, 26 Jul 2021 23:38:47 +0000</pubDate>
</item>
<item>
<title>Bug when using nested sorted maps</title>
<link>https://ask.clojure.org/index.php/10377/bug-when-using-nested-sorted-maps</link>
<description>&lt;p&gt;After discussing it on Slack, the following definitely feels like a bug. At the very least, it throws weirdly in CLJS while it is perfectly (and intuitively) fine in Clojure JVM.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def tree
     (sorted-map 3
                 (sorted-map 1
                             {:a 'leaf-A})))
(def subtree
     (sorted-map 1
                 (sorted-map 100
                             {:b 'leaf-B})))
;; Fine, of course, but now...
(assoc tree
       3
       subtree)
;; Throws:   Error: Cannot compare :a to 100
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Andy Fingerhut pointed to a difference in implementation. Clojure compares by reference and CLJS by value, forcing a deep comparison. Even then, I find the error cryptic and argue that logically speaking, Clojure makes sense.&lt;/p&gt;
&lt;p&gt;Citing him, Clojure implementation:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/PersistentTreeMap.java#L132&quot;&gt;https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/PersistentTreeMap.java#L132&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;And CLJS implementation: &lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/clojure/clojurescript/blob/master/src/main/cljs/cljs/core.cljs#L8857&quot;&gt;https://github.com/clojure/clojurescript/blob/master/src/main/cljs/cljs/core.cljs#L8857&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Is there something we didn't see?&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/10377/bug-when-using-nested-sorted-maps</guid>
<pubDate>Fri, 26 Mar 2021 08:47:17 +0000</pubDate>
</item>
<item>
<title>Possible reflection bug with Abstract Base Class methods not being visible</title>
<link>https://ask.clojure.org/index.php/10029/possible-reflection-abstract-class-methods-being-visible</link>
<description>&lt;p&gt;repro.clj:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(defn create-application []
  (let [credential (com.microsoft.aad.msal4j.ClientCredentialFactory/createFromSecret &quot;sekrit&quot;)
        builder (com.microsoft.aad.msal4j.ConfidentialClientApplication/builder &quot;client id&quot; credential)
        authority &quot;some authority&quot;]
    (-&amp;gt;
      builder
      (.authority ^String authority)
      (.build))))

(create-application)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Run with:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -Sdeps '{:deps {com.microsoft.azure/msal4j {:mvn/version &quot;1.8.1&quot;}}}' repro.clj
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The source code for the concrete class is at &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/AzureAD/microsoft-authentication-library-for-java/blob/dev/src/main/java/com/microsoft/aad/msal4j/ConfidentialClientApplication.java&quot;&gt;https://github.com/AzureAD/microsoft-authentication-library-for-java/blob/dev/src/main/java/com/microsoft/aad/msal4j/ConfidentialClientApplication.java&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;And the base class is at &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/AzureAD/microsoft-authentication-library-for-java/blob/dev/src/main/java/com/microsoft/aad/msal4j/AbstractClientApplicationBase.java&quot;&gt;https://github.com/AzureAD/microsoft-authentication-library-for-java/blob/dev/src/main/java/com/microsoft/aad/msal4j/AbstractClientApplicationBase.java&lt;/a&gt; where the authority field is declared with a Lombok Accessor annotation...&lt;/p&gt;
</description>
<category>Clojure</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/10029/possible-reflection-abstract-class-methods-being-visible</guid>
<pubDate>Fri, 08 Jan 2021 09:00:02 +0000</pubDate>
</item>
<item>
<title>Using eval from cljs.js with webpack</title>
<link>https://ask.clojure.org/index.php/9995/using-eval-from-cljs-js-with-webpack</link>
<description>&lt;p&gt;In clojurescript 1.10.773 it is impossible to use &lt;code&gt;eval&lt;/code&gt; from cljs.js when I've bundled the project with webpack I think this is because &lt;code&gt;eval&lt;/code&gt; is calling &lt;code&gt;find-ns-obj&lt;/code&gt;, when doesn't work with the &lt;code&gt;:bundle&lt;/code&gt; &lt;code&gt;:target&lt;/code&gt;. That makes sense, but this error still occurs when an &lt;code&gt;:ns&lt;/code&gt; is passed in the options map.&lt;/p&gt;
&lt;p&gt;Using &lt;code&gt;eval&lt;/code&gt; from cljs.js used to work in clojurescript 1.10.741, even when &lt;code&gt;:target&lt;/code&gt; was set to &lt;code&gt;:bundle&lt;/code&gt;. It looks like this is because previous versions of clojurescript never set &lt;code&gt;*target*&lt;/code&gt; when it was set in the compiler options.&lt;/p&gt;
&lt;p&gt;The error I'm getting is:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;core.cljs:11642 Uncaught Error: find-ns-obj not supported for target bundle
    at Object.cljs$core$find_ns_obj [as find_ns_obj] (core.cljs:11642)
    at Function.cljs$core$IFn$_invoke$arity$1 (core.cljs:11660)
    at cljs$core$create_ns (core.cljs:11657)
    at Function.cljs$js$compile_str_STAR__$_compile_loop (js.cljs:918)
    at Function.cljs$core$IFn$_invoke$arity$3 (core.cljs:3918)
    at Function.cljs$core$IFn$_invoke$arity$2 (core.cljs:3913)
    at Function.cljs$core$IFn$_invoke$arity$2 (core.cljs:3948)
    at core.cljs:10831
    at Function.cljs$core$IFn$_invoke$arity$1 (core.cljs:10826)
    at Function.cljs$core$IFn$_invoke$arity$variadic (core.cljs:10831)
cljs$core$find_ns_obj @ core.cljs:11642
(anonymous) @ core.cljs:11660
cljs$core$create_ns @ core.cljs:11657
cljs$js$compile_str_STAR__$_compile_loop @ js.cljs:918
(anonymous) @ core.cljs:3918
(anonymous) @ core.cljs:3913
(anonymous) @ core.cljs:3948
(anonymous) @ core.cljs:10831
(anonymous) @ core.cljs:10826
(anonymous) @ core.cljs:10831
cljs$core$trampoline @ core.cljs:10817
cljs$js$compile_str_STAR_ @ js.cljs:910
(anonymous) @ js.cljs:1019
cljs$js$compile_str @ js.cljs:968
interactive_syntax$core$eval_str @ core.cljs:48
run @ core.cljs:351
callCallback @ react-dom.development.js:188
invokeGuardedCallbackDev @ react-dom.development.js:237
invokeGuardedCallback @ react-dom.development.js:292
invokeGuardedCallbackAndCatchFirstError @ react-dom.development.js:306
executeDispatch @ react-dom.development.js:389
executeDispatchesInOrder @ react-dom.development.js:414
executeDispatchesAndRelease @ react-dom.development.js:3278
executeDispatchesAndReleaseTopLevel @ react-dom.development.js:3287
forEachAccumulated @ react-dom.development.js:3259
runEventsInBatch @ react-dom.development.js:3304
runExtractedPluginEventsInBatch @ react-dom.development.js:3514
handleTopLevel @ react-dom.development.js:3558
batchedEventUpdates$1 @ react-dom.development.js:21871
batchedEventUpdates @ react-dom.development.js:795
dispatchEventForLegacyPluginEventSystem @ react-dom.development.js:3568
attemptToDispatchEvent @ react-dom.development.js:4267
dispatchEvent @ react-dom.development.js:4189
unstable_runWithPriority @ scheduler.development.js:653
runWithPriority$1 @ react-dom.development.js:11039
discreteUpdates$1 @ react-dom.development.js:21887
discreteUpdates @ react-dom.development.js:806
dispatchDiscreteEvent @ react-dom.development.js:4168
Show 8 more frames
react-dom.development.js:327 Uncaught Error: find-ns-obj not supported for target bundle
    at Object.cljs$core$find_ns_obj [as find_ns_obj] (core.cljs:11642)
    at Function.cljs$core$IFn$_invoke$arity$1 (core.cljs:11660)
    at cljs$core$create_ns (core.cljs:11657)
    at Function.cljs$js$compile_str_STAR__$_compile_loop (js.cljs:918)
    at Function.cljs$core$IFn$_invoke$arity$3 (core.cljs:3918)
    at Function.cljs$core$IFn$_invoke$arity$2 (core.cljs:3913)
    at Function.cljs$core$IFn$_invoke$arity$2 (core.cljs:3948)
    at core.cljs:10831
    at Function.cljs$core$IFn$_invoke$arity$1 (core.cljs:10826)
    at Function.cljs$core$IFn$_invoke$arity$variadic (core.cljs:10831)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Any use of &lt;code&gt;eval&lt;/code&gt;, or &lt;code&gt;eval-str&lt;/code&gt;, &lt;code&gt;compile-str&lt;/code&gt;, etc. gives it to me. Say:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(eval-str (empty-state) &quot;(+ 1 2)&quot; &quot;UNTITLED&quot; {:eval js-eval} println)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;And I get this error even if I provide my own &lt;code&gt;:ns&lt;/code&gt;.&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/9995/using-eval-from-cljs-js-with-webpack</guid>
<pubDate>Sun, 03 Jan 2021 02:57:09 +0000</pubDate>
</item>
<item>
<title>Function with meta equality fails</title>
<link>https://ask.clojure.org/index.php/9966/function-with-meta-equality-fails</link>
<description>&lt;p&gt;Bug report:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(defn f [] 1)
=&amp;gt; #'cljs.user/f
(= f (with-meta f {:a 1}))
=&amp;gt; false ;; should be true
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Per: &lt;a rel=&quot;nofollow&quot; href=&quot;https://clojure.org/reference/metadata&quot;&gt;https://clojure.org/reference/metadata&lt;/a&gt;&lt;br&gt;
&quot;metadata does not impact equality&quot;&lt;/p&gt;
</description>
<category>ClojureScript</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/9966/function-with-meta-equality-fails</guid>
<pubDate>Wed, 23 Dec 2020 16:08:44 +0000</pubDate>
</item>
<item>
<title>Suspected bug in `clojure.core/partition`</title>
<link>https://ask.clojure.org/index.php/9937/suspected-bug-in-clojure-core-partition</link>
<description>&lt;p&gt;2 problems:&lt;br&gt;
- The docstring of clojure.core/partition is not clear on what &quot;last partition&quot; means.&lt;br&gt;
- The behavior of partition is strange, IHMO it has a bug.&lt;/p&gt;
&lt;p&gt;Please take a look at this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(partition 3 1 [:a :b :c] (range 5))

; actual behavior
; =&amp;gt; ((0 1 2) (1 2 3) (2 3 4) (3 4 :a))

; expected behavior, option 1
; =&amp;gt; ((0 1 2) (1 2 3) (2 3 4))

; expected behavior, option 2
; =&amp;gt; ((0 1 2) (1 2 3) (2 3 4) (3 4 :a) (4 :a :b))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I would expect the &quot;last partition&quot; to be defined as:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;The last partition to contain elements from the input collection (not the padding collection) which are not present in any previous partition.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This is consistent with option 1 above.&lt;/p&gt;
</description>
<category>Sequences</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/9937/suspected-bug-in-clojure-core-partition</guid>
<pubDate>Thu, 10 Dec 2020 02:54:45 +0000</pubDate>
</item>
</channel>
</rss>