I don\'t know how to implement this piece of Python code in Clojure
for i in range(3): try: ...... except e: if i == 2: raise
(cond (every? nil? (for [x (range (inc retry)) :while (not @tmp-doc)] ...do sth) ) ;all failed :else ;at least one success