Cannot use Uuid::now_v7
# help
g
In my pet project https://github.com/hseeberger/ticklist I am using the uuid crate with feature v7. This also requires rustflags --cfg uuid_unstable, hence I have provided a .cargo/config.toml. Non-shuttle builds (cargo build) as well as local runs (cargo shuttle run) work perfectly, yet deploying (cargo shuttle deploy) crashes with the following:
Copy code
2023-05-20T13:52:58.545699474Z  INFO    Compiling ticklist v0.1.0 (/opt/shuttle/shuttle-builds/ticklist)
2023-05-20T13:52:58.757461205Z DEBUG error[E0599]: no function or associated item named `now_v7` found for struct `Uuid` in the current scope
  --> src/main.rs:99:21
   |
99 |         .bind(Uuid::now_v7())
   |                     ^^^^^^
   |                     |
   |                     function or associated item not found in `Uuid`
   |                     help: there is an associated function with a similar name: `new_v4`


2023-05-20T13:52:58.762462429Z DEBUG error[E0599]: no function or associated item named `now_v7` found for struct `Uuid` in the current scope
   --> src/main.rs:123:21
    |
123 |         .bind(Uuid::now_v7())
    |                     ^^^^^^
    |                     |
    |                     function or associated item not found in `Uuid`
    |                     help: there is an associated function with a similar name: `new_v4`


2023-05-20T13:52:58.769838490Z DEBUG error[E0599]: no function or associated item named `now_v7` found for struct `Uuid` in the current scope
   --> src/main.rs:148:21
    |
148 |         .bind(Uuid::now_v7())
    |                     ^^^^^^
    |                     |
    |                     function or associated item not found in `Uuid`
    |                     help: there is an associated function with a similar name: `new_v4`


2023-05-20T13:52:58.784627003Z DEBUG error: aborting due to 3 previous errors
I assume that the custom rustflags are not picked up.
g
"Hidden" files are not included when deploying. This would probably mean the
.cargo
dir is being ignored. 🤔
The function used to find files when deploying can be found in
make_archive
in cargo-shuttle. Perhaps a nice feature would be to add explicit files to include in
Shuttle.toml
(they can already be excluded with .gitignore / .ignore)
g
Thanks for the explanation, @gentle-ice-1561. While that feature might be useful anyway, I think that standard files and directories, like .cargo, must not be excluded. I'll create an issue and we can discuss it there.