       (when-not (= 128 (:exit (ex-data e)))
         (println "Ignoring error:" (pr-str e)))
       nil)))
+(defn robust-read-proj-blob
+  [gitdir blob-sha]
+  ;; Hack to work around crazy project.clj files
+  (binding [slurp (patch-fn slurp "{}")
+            load-file (patch-fn load-file {})]
+    (let [tmp-file (File/createTempFile ".project-" ".clj")]
+      (try
+        (spit tmp-file
+              (:out (git {:gitdir gitdir} "cat-file" "-p" (str blob-sha))))
+        (project/read (str tmp-file))
+        (catch Exception e
+          ;; It was really just a best effort anyway. Silently ignore.
+          nil)
+        (finally
+         (.delete tmp-file))))))
 
 (defn origin-branches
   [gitdir]

                     (r-commit-parent childer nparent)
                     (ancestoro nparent parenter))])))

(comment
  (def xdb1 (pldb/db [r-tree :a :b :c :d]))
  (pldb/with-db xdb1 (l/run* [a] (r-tree a :b :c :d)))

  (time
   (let [fname "core.clj"]
     (doall
      (pldb/with-db db3
        (l/run 10 [c-sha tree-path obj-sha]
               (l/fresh [tree-sha ctime p-sha p-ctime p-tree-sha p-obj-sha]
                        (r-commit c-sha ctime tree-sha)
