You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using paperclip 0.6.1 with the actix_files feature and actix_files version 0.5, the Mountable trait from paperclip is not implemented for actix_files::Files, making it unusable. I think it should be implemented when the actix-files feature is enabled, but unfortunately it is not.
Here's the relevant compiler error:
error[E0277]: the trait bound `Files: Mountable` is not satisfied
--> src/main.rs:75:22
|
75 | .service(Files::new("", "./")
| ______________-------_^
| | |
| | required by a bound introduced by this call
76 | | .prefer_utf8(true)
77 | | .show_files_listing()))
| |_____________________________________^ the trait `Mountable` is not implemented for `Files`
Looks like actix-files "support" was added on #277
What do you actually want us to do for the Files, what would/should show up on the OpenApi?
(If you just want to use it you can add it before the wrap_api call and it will go straight to actix)
That would be the most appropriate solution I think. Otherwhise you'd have to go through the Files folder to discover all files there, which seems like unnecessary. The use case for me is serving the frontend with the same webserver as the API.
So it should not show up at all in the spec, so your proposed solution seems correct. Should this be included in the docs potentialyl?
Hi there,
When using paperclip
0.6.1
with theactix_files
feature andactix_files
version0.5
, theMountable
trait frompaperclip
is not implemented foractix_files::Files
, making it unusable. I think it should be implemented when theactix-files
feature is enabled, but unfortunately it is not.Here's the relevant compiler error:
Relevant parts of
Cargo.toml
:Thanks.
The text was updated successfully, but these errors were encountered: