slagyr / speclj

pronounced "speckle": a TDD/BDD framework for Clojure.
MIT License
458 stars 58 forks source link

directory name with space in it #167

Open slagyr opened 3 years ago

slagyr commented 3 years ago

lein spec -a

Changes to the core.clj file do not get reloaded and specs do not rerun. Removing the space in the directory name fixes the problem.

bowling katas.zip

brandoncorrea commented 2 years ago

This looks like an issue with fresh.core line 42, ns-to-file, which is returning URL Encoded file paths.

(file (.getFile url))

One solution would be adding a URLDecoder. This would fix the encoded space and any other URL Encoding issues in directories, but would require a dependency on java.net.

(:import 
    ; ...
    [java.net URLDecoder])
; ...
(file (URLDecoder/decode (.getFile url) "UTF-8"))
slagyr commented 2 years ago

Thanks @brandoncorrea. The fresh library should be deprecated since clojure.tools.namespace.dir exists now. The correct fix would be to swap out the use of fresh.