cryogen-project / cryogen-core

Cryogen's core
Eclipse Public License 1.0
69 stars 62 forks source link

An exception in compile-assets-timed should fail the build #134

Open holyjak opened 4 years ago

holyjak commented 4 years ago

compile-assets-timed shouldn't just catch + log exceptions, it should rethrow them so lein run would fail. As it is now, if the build fails, my build script cannot know it and will deploy the incomplete site, breaking my blog.

Do you agree?

holyjak commented 4 years ago

I see the exception thrown is kind of ugly so I understand the original motivation to hide it. A possible solution would be to modify the generated cryogen.core/-main to catch it and simply (System/exit 1). Or we could add yet one param to compile-assets-timed such as :swallow-errors defaulting to true....

(Having the exception proved very useful in troubleshooting issues, especially the stack trace.)

lacarmen commented 4 years ago

Agreed 😄