From 6ab27e0854a60a6f669925d8f9b5971f73478445 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Fri, 11 Nov 2022 17:22:34 +0100 Subject: [PATCH] bumped sea-orm --- Cargo.lock | 152 ++++++++------------------- warpgate-admin/Cargo.toml | 2 +- warpgate-admin/src/api/pagination.rs | 2 +- warpgate-common/Cargo.toml | 2 +- warpgate-core/Cargo.toml | 2 +- warpgate-db-entities/Cargo.toml | 2 +- warpgate-db-migrations/Cargo.toml | 4 +- warpgate-protocol-ssh/Cargo.toml | 2 +- warpgate/Cargo.toml | 2 +- 9 files changed, 52 insertions(+), 118 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d6a8390..90a580b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -128,16 +128,6 @@ version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" -[[package]] -name = "async-attributes" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3203e79f4dd9bdda415ed03cf14dae5a2bf775c683a00f94e9cd1faf0f596e5" -dependencies = [ - "quote", - "syn", -] - [[package]] name = "async-channel" version = "1.6.1" @@ -177,7 +167,6 @@ dependencies = [ "futures-lite", "num_cpus", "once_cell", - "tokio", ] [[package]] @@ -223,7 +212,6 @@ version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "52580991739c5cdb36cde8b2a516371c0a3b70dda36d916cc08b82372916808c" dependencies = [ - "async-attributes", "async-channel", "async-global-executor", "async-io", @@ -1081,10 +1069,10 @@ dependencies = [ ] [[package]] -name = "dotenv" -version = "0.15.0" +name = "dotenvy" +version = "0.15.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c90badedccf4105eca100756a0b1289e191f6fcbdadd3cee1d2f614f97da8f" +checksum = "03d8c417d7a8cb362e0c37e5d815f5eb7c37f79ff93707329d5a194e42e54ca0" [[package]] name = "ed25519" @@ -1136,12 +1124,6 @@ version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "77f3309417938f28bf8228fcff79a4a37103981e3e186d2ccd19c74b38f4eb71" -[[package]] -name = "fallible-iterator" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7" - [[package]] name = "fastrand" version = "1.7.0" @@ -2839,39 +2821,6 @@ dependencies = [ "universal-hash", ] -[[package]] -name = "postgres-protocol" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "878c6cbf956e03af9aa8204b407b9cbf47c072164800aa918c516cd4b056c50c" -dependencies = [ - "base64 0.13.0", - "byteorder", - "bytes 1.2.1", - "fallible-iterator", - "hmac", - "md-5", - "memchr", - "rand 0.8.5", - "sha2 0.10.2", - "stringprep", -] - -[[package]] -name = "postgres-types" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebd6e8b7189a73169290e89bd24c771071f1012d8fe6f738f5226531f0b03d89" -dependencies = [ - "bytes 1.2.1", - "chrono", - "fallible-iterator", - "postgres-protocol", - "serde", - "serde_json", - "uuid", -] - [[package]] name = "ppv-lite86" version = "0.2.16" @@ -3454,9 +3403,9 @@ checksum = "2fde85c94a50dc789df8ca7b39f6b8b1eaa6cd320cc729e9ce1e1e1104292719" [[package]] name = "sea-orm" -version = "0.9.2" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "089dcca5d2c8393f5f21c7f7b0d84062839c3264ba62dcc0043eb207862e13a1" +checksum = "75f0afff0dd7581c8cc88b35fdd42d207f379ce5cfc5a88e65b5aa95e0ec3d3f" dependencies = [ "async-stream", "async-trait", @@ -3468,37 +3417,23 @@ dependencies = [ "ouroboros", "sea-orm-macros", "sea-query", + "sea-query-binder", "sea-strum", "serde", "serde_json", "sqlx", + "thiserror", + "time 0.3.15", "tracing", "url", "uuid", ] -[[package]] -name = "sea-orm-cli" -version = "0.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cefd2d8878bd7e8b7313f036725fa3d08585d101fb1bf3adca7fc13f553f906" -dependencies = [ - "async-std", - "chrono", - "clap", - "dotenv", - "regex", - "sea-schema", - "tracing", - "tracing-subscriber", - "url", -] - [[package]] name = "sea-orm-macros" -version = "0.9.2" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d9708f945febe8625ccb0334654b97d1a1a0bffa0473d86e6108ad13f79bd5" +checksum = "2d1c53d3ed30403f210ef8a67da9d929a4d07a91b6478ae3ab827d2d91b88a84" dependencies = [ "bae", "heck 0.3.3", @@ -3509,15 +3444,12 @@ dependencies = [ [[package]] name = "sea-orm-migration" -version = "0.9.2" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70a28587780fbae5c414a62bf0b32405f9da2e000d94f426abf214b2b2e68631" +checksum = "86fe6e594b078712e1e797b951b9b56e55d3cfa04aac8ea76eb4bed7c94c5910" dependencies = [ "async-trait", - "clap", - "dotenv", "sea-orm", - "sea-orm-cli", "sea-schema", "tracing", "tracing-subscriber", @@ -3525,18 +3457,29 @@ dependencies = [ [[package]] name = "sea-query" -version = "0.26.3" +version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6a1de9d0334895f7eb51bd1603c3c9f6737413f905a134001f1e198f43bfd70" +checksum = "3497a83851c4be4d1fdc8cbc7215105b828a2a944abb64dd2e0ba233f2ce187f" dependencies = [ "chrono", - "postgres-types", "sea-query-derive", - "sea-query-driver", "serde_json", "uuid", ] +[[package]] +name = "sea-query-binder" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c2585b89c985cfacfe0ec9fc9e7bb055b776c1a2581c4e3c6185af2b8bf8865" +dependencies = [ + "chrono", + "sea-query", + "serde_json", + "sqlx", + "uuid", +] + [[package]] name = "sea-query-derive" version = "0.2.0" @@ -3550,22 +3493,11 @@ dependencies = [ "thiserror", ] -[[package]] -name = "sea-query-driver" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbda46eb3484cae1efb7bc68bca50f553a5b42c076cf4cbfae05b27f707549d4" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - [[package]] name = "sea-schema" -version = "0.9.3" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94d070aba647637b533bd669a8e430bdc8f7d5249c9b53402da34347563bbfca" +checksum = "0a2e6fd7fb2c4adc28f1b8fb29944fa5e6a77968df57f32b7146c9ae10fb2f2b" dependencies = [ "futures", "sea-query", @@ -3853,9 +3785,9 @@ dependencies = [ [[package]] name = "sqlformat" -version = "0.1.8" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4b7922be017ee70900be125523f38bdd644f4f06a1b16e8fa5a8ee8c34bffd4" +checksum = "f87e292b4291f154971a43c3774364e2cbcaec599d3f5bf6fa9d122885dbc38a" dependencies = [ "itertools", "nom", @@ -3864,9 +3796,9 @@ dependencies = [ [[package]] name = "sqlx" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f82cbe94f41641d6c410ded25bbf5097c240cefdf8e3b06d04198d0a96af6a4" +checksum = "9249290c05928352f71c077cc44a464d880c63f26f7534728cca008e135c0428" dependencies = [ "sqlx-core", "sqlx-macros", @@ -3874,9 +3806,9 @@ dependencies = [ [[package]] name = "sqlx-core" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b69bf218860335ddda60d6ce85ee39f6cf6e5630e300e19757d1de15886a093" +checksum = "dcbc16ddba161afc99e14d1713a453747a2b07fc097d2009f4c300ec99286105" dependencies = [ "ahash", "atoi", @@ -3889,6 +3821,7 @@ dependencies = [ "crossbeam-queue", "digest 0.10.5", "dirs", + "dotenvy", "either", "event-listener", "flume", @@ -3917,7 +3850,7 @@ dependencies = [ "rsa", "serde", "serde_json", - "sha-1", + "sha1", "sha2 0.10.2", "smallvec", "sqlformat", @@ -3932,11 +3865,11 @@ dependencies = [ [[package]] name = "sqlx-macros" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f40c63177cf23d356b159b60acd27c54af7423f1736988502e36bae9a712118f" +checksum = "b850fa514dc11f2ee85be9d055c512aa866746adfacd1cb42d867d68e6a5b0d9" dependencies = [ - "dotenv", + "dotenvy", "either", "heck 0.4.0", "once_cell", @@ -3952,9 +3885,9 @@ dependencies = [ [[package]] name = "sqlx-rt" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "874e93a365a598dc3dadb197565952cb143ae4aa716f7bcc933a8d836f6bf89f" +checksum = "24c5b2d25fa654cc5f841750b8e1cdedbe21189bf9a9382ee90bfa9dd3562396" dependencies = [ "native-tls", "once_cell", @@ -4135,6 +4068,7 @@ dependencies = [ "itoa", "libc", "num_threads", + "serde", "time-macros", ] diff --git a/warpgate-admin/Cargo.toml b/warpgate-admin/Cargo.toml index 2a1cd9b..2cf8f30 100644 --- a/warpgate-admin/Cargo.toml +++ b/warpgate-admin/Cargo.toml @@ -26,7 +26,7 @@ poem-openapi = { version = "^2.0.10", features = [ ] } russh-keys = { version = "0.22.0", features = ["openssl"] } rust-embed = "6.3" -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "runtime-tokio-native-tls", "macros", ], default-features = false } diff --git a/warpgate-admin/src/api/pagination.rs b/warpgate-admin/src/api/pagination.rs index d758051..34e1b3d 100644 --- a/warpgate-admin/src/api/pagination.rs +++ b/warpgate-admin/src/api/pagination.rs @@ -30,7 +30,7 @@ impl PaginatedResponse { let offset = params.offset.unwrap_or(0); let limit = params.limit.unwrap_or(100); - let paginator = query.clone().paginate(db, limit as usize); + let paginator = query.clone().paginate(db, limit); let total = paginator .num_items() diff --git a/warpgate-common/Cargo.toml b/warpgate-common/Cargo.toml index 7fd1db0..070b48e 100644 --- a/warpgate-common/Cargo.toml +++ b/warpgate-common/Cargo.toml @@ -26,7 +26,7 @@ poem-openapi = { version = "^2.0.10", features = [ rand = "0.8" rand_chacha = "0.3" rand_core = { version = "0.6", features = ["std"] } -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "runtime-tokio-native-tls", "macros", ], default-features = false } diff --git a/warpgate-core/Cargo.toml b/warpgate-core/Cargo.toml index deea338..843695d 100644 --- a/warpgate-core/Cargo.toml +++ b/warpgate-core/Cargo.toml @@ -30,7 +30,7 @@ poem-openapi = { version = "^2.0.10", features = [ rand = "0.8" rand_chacha = "0.3" rand_core = { version = "0.6", features = ["std"] } -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "runtime-tokio-native-tls", "macros", ], default-features = false } diff --git a/warpgate-db-entities/Cargo.toml b/warpgate-db-entities/Cargo.toml index f43b2c4..00cbc61 100644 --- a/warpgate-db-entities/Cargo.toml +++ b/warpgate-db-entities/Cargo.toml @@ -7,7 +7,7 @@ version = "0.6.4" [dependencies] chrono = { version = "0.4", features = ["serde"] } poem-openapi = { version = "^2.0.10", features = ["chrono", "uuid"] } -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "macros", "with-chrono", "with-uuid", diff --git a/warpgate-db-migrations/Cargo.toml b/warpgate-db-migrations/Cargo.toml index 0a7a8f8..c2a2544 100644 --- a/warpgate-db-migrations/Cargo.toml +++ b/warpgate-db-migrations/Cargo.toml @@ -10,13 +10,13 @@ version = "0.6.4" [dependencies] async-std = "^1.11" chrono = "0.4" -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "runtime-tokio-native-tls", "macros", "with-chrono", "with-uuid", "with-json", ], default-features = false } -sea-orm-migration = { version = "^0.9", default-features = false } +sea-orm-migration = { version = "0.10.2", default-features = false } uuid = { version = "1.0", features = ["v4", "serde"] } serde_json = "1.0" diff --git a/warpgate-protocol-ssh/Cargo.toml b/warpgate-protocol-ssh/Cargo.toml index c28b8e0..a7606ac 100644 --- a/warpgate-protocol-ssh/Cargo.toml +++ b/warpgate-protocol-ssh/Cargo.toml @@ -14,7 +14,7 @@ dialoguer = "0.10" futures = "0.3" russh = { version = "0.35.0-beta.1", features = ["vendored-openssl"] } russh-keys = { version = "0.22.0", features = ["vendored-openssl"] } -sea-orm = { version = "^0.9", features = [ +sea-orm = { version = "0.10.2", features = [ "runtime-tokio-native-tls", ], default-features = false } thiserror = "1.0" diff --git a/warpgate/Cargo.toml b/warpgate/Cargo.toml index e7d8c3b..1be064b 100644 --- a/warpgate/Cargo.toml +++ b/warpgate/Cargo.toml @@ -22,7 +22,7 @@ notify = "^5.0.0" rcgen = { version = "0.10", features = ["zeroize"] } serde_json = "1.0" serde_yaml = "0.8.23" -sea-orm = { version = "^0.9", default-features = false } +sea-orm = { version = "0.10.2", default-features = false } time = "0.3" tokio = { version = "1.20", features = ["tracing", "signal", "macros"] } tracing = "0.1"