Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upload module doesn't preserve file attributes on single file #124

Open
retrogradeorbit opened this issue Jun 22, 2021 · 1 comment
Open
Labels
bug Something isn't working

Comments

@retrogradeorbit
Copy link
Member

First copied file without preserving attributes:

     (upload {:src "/home/crispin/bin/spire"
              :dest "/usr/local/bin/spire"})

That worked. Then added :preserve true

     (upload {:src "/home/crispin/bin/spire"
              :dest "/usr/local/bin/spire"
              :preserve true})

And got:

provisioning/email.clj:68 (upload {:src "/home/crispin/bin/spire", :preserve true, :dest "/usr/local/bin/spire"})
Exception in thread "main" clojure.lang.ExceptionInfo: Assert failed: attribute tree must be passed a directory
(.isDirectory file) [at provisioning/email.clj, line 13, column 1] {:type :sci/error, :line 13, :column 1, :message "Assert failed: attribute tree must be passed a directory\n(.isDirectory file) [at provisioning/email.clj, line 13, column 1]"}
	at sci.impl.utils$rethrow_with_location_of_node.invokeStatic(utils.cljc:72)
	at sci.impl.interpreter$eval_call.invokeStatic(interpreter.cljc:573)
	at sci.impl.interpreter$interpret.invokeStatic(interpreter.cljc:613)
	at sci.impl.interpreter$eval_form.invokeStatic(interpreter.cljc:645)
	at sci.impl.interpreter$eval_string_STAR_.invokeStatic(interpreter.cljc:658)
	at sci.core$eval_string_STAR_.invokeStatic(core.cljc:189)
	at spire.eval$evaluate.invokeStatic(eval.clj:87)
	at spire.core$_main.invokeStatic(core.clj:80)
	at spire.core$_main.doInvoke(core.clj:57)
	at clojure.lang.RestFn.applyTo(RestFn.java:137)
	at spire.core.main(Unknown Source)
Caused by: java.lang.AssertionError: Assert failed: attribute tree must be passed a directory
(.isDirectory file)
	at spire.module.attrs$create_attribute_list.invokeStatic(attrs.clj:72)
	at spire.module.attrs$set_attrs_preserve.invokeStatic(attrs.clj:102)
	at spire.module.upload$upload_STAR_.invokeStatic(upload.clj:303)
	at spire.module.upload$upload_STAR_.doInvoke(upload.clj:100)

@retrogradeorbit retrogradeorbit added the bug Something isn't working label Jun 22, 2021
@retrogradeorbit
Copy link
Member Author

also happens on initial copy with single file and :preserve true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant