pytrainer: unpin python 3.10
[NixPkgs.git] / pkgs / by-name / ve / veloren / fix-on-rust-stable.patch
blobea7354119e570157101d57398635e0377a898f0a
1 commit 0829b00ec1a14c8248e1aadca22b132a1b21c40f
2 Author: rnhmjoj <rnhmjoj@inventati.org>
3 Date: Mon Aug 5 00:34:55 2024 +0200
5 update toolchain to `2024-05-14`
7 Backport of 6ec900cf to v0.16.0
9 diff --git a/.cargo/config b/.cargo/config.toml
10 similarity index 100%
11 rename from .cargo/config
12 rename to .cargo/config.toml
13 diff --git a/Cargo.lock b/Cargo.lock
14 index d0f84803..6f90da69 100644
15 --- a/Cargo.lock
16 +++ b/Cargo.lock
17 @@ -45,17 +45,6 @@ version = "0.4.8"
18 source = "registry+https://github.com/rust-lang/crates.io-index"
19 checksum = "0453232ace82dee0dd0b4c87a59bd90f7b53b314f3e0f61fe2ee7c8a16482289"
21 -[[package]]
22 -name = "ahash"
23 -version = "0.7.8"
24 -source = "registry+https://github.com/rust-lang/crates.io-index"
25 -checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9"
26 -dependencies = [
27 - "getrandom 0.2.12",
28 - "once_cell",
29 - "version_check",
32 [[package]]
33 name = "ahash"
34 version = "0.8.11"
35 @@ -4538,16 +4527,6 @@ dependencies = [
36 "ttf-parser",
39 -[[package]]
40 -name = "packed_simd"
41 -version = "0.3.9"
42 -source = "registry+https://github.com/rust-lang/crates.io-index"
43 -checksum = "1f9f08af0c877571712e2e3e686ad79efad9657dbf0f7c3c8ba943ff6c38932d"
44 -dependencies = [
45 - "cfg-if 1.0.0",
46 - "num-traits",
49 [[package]]
50 name = "parking"
51 version = "2.2.0"
52 @@ -5870,8 +5849,9 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"
54 [[package]]
55 name = "shred"
56 -version = "0.15.0"
57 -source = "git+https://github.com/amethyst/shred.git?rev=5d52c6fc390dd04c12158633e77591f6523d1f85#5d52c6fc390dd04c12158633e77591f6523d1f85"
58 +version = "0.16.1"
59 +source = "registry+https://github.com/rust-lang/crates.io-index"
60 +checksum = "656294f5bdcf6d33f0cf89e88a72b58595e3fca0e77e4a4b9e9026179757fb1e"
61 dependencies = [
62 "ahash 0.8.11",
63 "arrayvec",
64 @@ -5884,8 +5864,9 @@ dependencies = [
66 [[package]]
67 name = "shred-derive"
68 -version = "0.6.3"
69 -source = "git+https://github.com/amethyst/shred.git?rev=5d52c6fc390dd04c12158633e77591f6523d1f85#5d52c6fc390dd04c12158633e77591f6523d1f85"
70 +version = "0.7.0"
71 +source = "registry+https://github.com/rust-lang/crates.io-index"
72 +checksum = "69760b786f8b40361c10663eb63c81fa7d828008527d26aa7595b99c53ab3a8d"
73 dependencies = [
74 "proc-macro2 1.0.79",
75 "quote 1.0.35",
76 @@ -6019,10 +6000,9 @@ dependencies = [
77 [[package]]
78 name = "specs"
79 version = "0.20.0"
80 -source = "registry+https://github.com/rust-lang/crates.io-index"
81 -checksum = "a60eabdfd5a80e458c3e7bcc9f1076d6ce3cc8ddb71d69691f00fc0de735a635"
82 +source = "git+https://github.com/amethyst/specs.git?rev=4e2da1df29ee840baa9b936593c45592b7c9ae27#4e2da1df29ee840baa9b936593c45592b7c9ae27"
83 dependencies = [
84 - "ahash 0.7.8",
85 + "ahash 0.8.11",
86 "crossbeam-queue",
87 "hibitset",
88 "log",
89 @@ -6904,9 +6884,9 @@ dependencies = [
91 [[package]]
92 name = "vek"
93 -version = "0.16.1"
94 +version = "0.17.0"
95 source = "registry+https://github.com/rust-lang/crates.io-index"
96 -checksum = "c85158043f3bc1fac596d59a77e07948da340b9951b451ed4cb4a8c480aa2157"
97 +checksum = "cb40015035f83ba23d647e647f8be060d0f6f99b7c7687989fbca3e3d65e7234"
98 dependencies = [
99 "approx 0.5.1",
100 "num-integer",
101 @@ -6936,7 +6916,7 @@ dependencies = [
102 "specs",
103 "tokio",
104 "tracing",
105 - "vek 0.16.1",
106 + "vek 0.17.0",
107 "veloren-client-i18n",
108 "veloren-common",
109 "veloren-common-base",
110 @@ -7007,7 +6987,7 @@ dependencies = [
111 "tracing",
112 "tracing-subscriber",
113 "uuid",
114 - "vek 0.16.1",
115 + "vek 0.17.0",
116 "veloren-common-assets",
117 "veloren-common-base",
118 "veloren-common-i18n",
119 @@ -7092,7 +7072,7 @@ dependencies = [
120 "specs",
121 "sum_type",
122 "tracing",
123 - "vek 0.16.1",
124 + "vek 0.17.0",
125 "veloren-common",
128 @@ -7116,7 +7096,7 @@ dependencies = [
129 "timer-queue",
130 "toml 0.8.12",
131 "tracing",
132 - "vek 0.16.1",
133 + "vek 0.17.0",
134 "veloren-common",
135 "veloren-common-assets",
136 "veloren-common-base",
137 @@ -7136,7 +7116,7 @@ dependencies = [
138 "rayon",
139 "specs",
140 "tracing",
141 - "vek 0.16.1",
142 + "vek 0.17.0",
143 "veloren-common",
144 "veloren-common-base",
145 "veloren-common-ecs",
146 @@ -7208,7 +7188,7 @@ dependencies = [
147 "serde",
148 "slotmap",
149 "tracing",
150 - "vek 0.16.1",
151 + "vek 0.17.0",
152 "veloren-common",
153 "veloren-world",
155 @@ -7251,7 +7231,7 @@ dependencies = [
156 "strum 0.24.1",
157 "tokio",
158 "tracing",
159 - "vek 0.16.1",
160 + "vek 0.17.0",
161 "veloren-common",
162 "veloren-common-base",
163 "veloren-common-ecs",
164 @@ -7272,7 +7252,7 @@ dependencies = [
165 "lazy_static",
166 "rand 0.8.5",
167 "specs",
168 - "vek 0.16.1",
169 + "vek 0.17.0",
170 "veloren-common",
171 "veloren-common-dynlib",
172 "veloren-rtsim",
173 @@ -7368,7 +7348,7 @@ dependencies = [
174 "tokio",
175 "tracing",
176 "treeculler",
177 - "vek 0.16.1",
178 + "vek 0.17.0",
179 "veloren-client",
180 "veloren-client-i18n",
181 "veloren-common",
182 @@ -7396,7 +7376,7 @@ version = "0.10.0"
183 dependencies = [
184 "bytemuck",
185 "lazy_static",
186 - "vek 0.16.1",
187 + "vek 0.17.0",
188 "veloren-common",
189 "veloren-common-dynlib",
191 @@ -7452,7 +7432,6 @@ dependencies = [
192 "num 0.4.1",
193 "num-traits",
194 "ordered-float 3.9.2",
195 - "packed_simd",
196 "rand 0.8.5",
197 "rand_chacha 0.3.1",
198 "rayon",
199 @@ -7465,7 +7444,7 @@ dependencies = [
200 "svg_fmt",
201 "tracing",
202 "tracing-subscriber",
203 - "vek 0.16.1",
204 + "vek 0.17.0",
205 "veloren-common",
206 "veloren-common-base",
207 "veloren-common-dynlib",
208 diff --git a/Cargo.toml b/Cargo.toml
209 index c8d02902..02521745 100644
210 --- a/Cargo.toml
211 +++ b/Cargo.toml
212 @@ -1,5 +1,3 @@
213 -cargo-features = ["named-profiles", "profile-overrides"]
215 [workspace]
216 resolver = "2"
217 members = [
218 @@ -141,7 +139,7 @@ crossbeam-channel = { version = "0.5"}
219 ordered-float = { version = "3", default-features = true }
220 num = { version = "0.4" }
221 num-traits = { version = "0.2" }
222 -vek = { version = "0.16.1", features = ["serde"] }
223 +vek = { version = "0.17.0", features = ["serde"] }
224 itertools = { version = "0.10" }
226 serde = { version = "1.0.118", features = ["derive"] }
227 @@ -158,7 +156,7 @@ sha2 = "0.10"
228 hex = "0.4.3"
230 [patch.crates-io]
231 -shred = { git = "https://github.com/amethyst/shred.git", rev = "5d52c6fc390dd04c12158633e77591f6523d1f85" }
232 +specs = { git = "https://github.com/amethyst/specs.git", rev = "4e2da1df29ee840baa9b936593c45592b7c9ae27" }
233 # This is needed because of:
234 # * an issue with spirv & naga in wgpu 0.18 (I assume this is fixed upstream but not in 0.18)
235 # * an issue with uint in uniforms for gl. (potentially fixed in 0.19?)
236 diff --git a/client/i18n/src/error.rs b/client/i18n/src/error.rs
237 index 99f47bad..37eaa097 100644
238 --- a/client/i18n/src/error.rs
239 +++ b/client/i18n/src/error.rs
240 @@ -45,6 +45,7 @@ pub enum ResourceErr {
241 #[allow(dead_code)] // false-positive
242 err: String,
244 + #[allow(dead_code)] // false-positive
245 BundleError(String),
248 diff --git a/rtsim/src/lib.rs b/rtsim/src/lib.rs
249 index 11477390..ef62db65 100644
250 --- a/rtsim/src/lib.rs
251 +++ b/rtsim/src/lib.rs
252 @@ -7,7 +7,8 @@
253 binary_heap_drain_sorted,
254 fn_traits,
255 unboxed_closures,
256 - tuple_trait
257 + tuple_trait,
258 + trait_upcasting
261 pub mod ai;
262 diff --git a/rust-toolchain b/rust-toolchain
263 index f1273305..e426a2f8 100644
264 --- a/rust-toolchain
265 +++ b/rust-toolchain
266 @@ -1 +1 @@
267 -nightly-2024-01-17
268 +nightly-2024-05-14
269 diff --git a/server/agent/src/lib.rs b/server/agent/src/lib.rs
270 index 420bd5ff..4a927c74 100644
271 --- a/server/agent/src/lib.rs
272 +++ b/server/agent/src/lib.rs
273 @@ -1,4 +1,4 @@
274 -#![feature(exclusive_range_pattern, let_chains)]
275 +#![feature(let_chains)]
276 #![allow(
277 clippy::needless_pass_by_ref_mut //until we find a better way for specs
279 diff --git a/server/src/persistence/models.rs b/server/src/persistence/models.rs
280 index df148742..70baed42 100644
281 --- a/server/src/persistence/models.rs
282 +++ b/server/src/persistence/models.rs
283 @@ -1,5 +1,6 @@
284 pub struct Character {
285 pub character_id: i64,
286 + #[allow(dead_code)]
287 pub player_uuid: String,
288 pub alias: String,
289 pub waypoint: Option<String>,
290 @@ -16,6 +17,7 @@ pub struct Item {
293 pub struct Body {
294 + #[allow(dead_code)]
295 pub body_id: i64,
296 pub variant: String,
297 pub body_data: String,
298 @@ -38,6 +40,7 @@ pub struct Pet {
301 pub struct AbilitySets {
302 + #[allow(dead_code)]
303 pub entity_id: i64,
304 pub ability_sets: String,
306 diff --git a/voxygen/src/credits.rs b/voxygen/src/credits.rs
307 index 2de54687..be49ac97 100644
308 --- a/voxygen/src/credits.rs
309 +++ b/voxygen/src/credits.rs
310 @@ -7,6 +7,7 @@ use std::path::PathBuf;
312 // See best practices for attribution: https://wiki.creativecommons.org/wiki/Best_practices_for_attribution
314 +#[allow(dead_code)]
315 #[derive(Clone, Deserialize)]
316 pub struct Art {
317 /// Name of the art.
318 diff --git a/voxygen/src/hud/mod.rs b/voxygen/src/hud/mod.rs
319 index e62250ca..6be79389 100755
320 --- a/voxygen/src/hud/mod.rs
321 +++ b/voxygen/src/hud/mod.rs
322 @@ -1,3 +1,4 @@
323 +#![allow(non_local_definitions)] // because of WidgetCommon derive
324 mod animation;
325 mod bag;
326 mod buffs;
327 diff --git a/voxygen/src/render/renderer/rain_occlusion_map.rs b/voxygen/src/render/renderer/rain_occlusion_map.rs
328 index bdc44f98..68026806 100644
329 --- a/voxygen/src/render/renderer/rain_occlusion_map.rs
330 +++ b/voxygen/src/render/renderer/rain_occlusion_map.rs
331 @@ -11,7 +11,6 @@ pub struct RainOcclusionMapRenderer {
333 pub terrain_pipeline: rain_occlusion::RainOcclusionPipeline,
334 pub figure_pipeline: rain_occlusion::RainOcclusionFigurePipeline,
335 - pub layout: rain_occlusion::RainOcclusionLayout,
338 pub enum RainOcclusionMap {
339 @@ -31,13 +30,10 @@ impl RainOcclusionMap {
340 if let (Some(terrain_pipeline), Some(figure_pipeline), Some(depth)) =
341 (directed, figure, view)
343 - let layout = rain_occlusion::RainOcclusionLayout::new(device);
345 Self::Enabled(RainOcclusionMapRenderer {
346 depth,
347 terrain_pipeline,
348 figure_pipeline,
349 - layout,
351 } else {
352 Self::Disabled(Self::create_dummy_tex(device, queue))
353 diff --git a/voxygen/src/render/renderer/shadow_map.rs b/voxygen/src/render/renderer/shadow_map.rs
354 index 7b5ab16e..b15a2da3 100644
355 --- a/voxygen/src/render/renderer/shadow_map.rs
356 +++ b/voxygen/src/render/renderer/shadow_map.rs
357 @@ -12,7 +12,6 @@ pub struct ShadowMapRenderer {
358 pub terrain_directed_pipeline: shadow::ShadowPipeline,
359 pub figure_directed_pipeline: shadow::ShadowFigurePipeline,
360 pub debug_directed_pipeline: shadow::ShadowDebugPipeline,
361 - pub layout: shadow::ShadowLayout,
364 pub enum ShadowMap {
365 @@ -43,8 +42,6 @@ impl ShadowMap {
367 let (point_depth, directed_depth) = shadow_views;
369 - let layout = shadow::ShadowLayout::new(device);
371 Self::Enabled(ShadowMapRenderer {
372 directed_depth,
373 point_depth,
374 @@ -53,8 +50,6 @@ impl ShadowMap {
375 terrain_directed_pipeline,
376 figure_directed_pipeline,
377 debug_directed_pipeline,
379 - layout,
381 } else {
382 let (dummy_point, dummy_directed) = Self::create_dummy_shadow_tex(device, queue);
383 diff --git a/voxygen/src/ui/widgets/mod.rs b/voxygen/src/ui/widgets/mod.rs
384 index e7ce5ee8..622e7e9e 100644
385 --- a/voxygen/src/ui/widgets/mod.rs
386 +++ b/voxygen/src/ui/widgets/mod.rs
387 @@ -1,3 +1,4 @@
388 +#![allow(non_local_definitions)] // because of WidgetCommon derive
389 pub mod ghost_image;
390 pub mod image_frame;
391 pub mod image_slider;
392 diff --git a/world/Cargo.toml b/world/Cargo.toml
393 index 92bd288f..6ff2e79e 100644
394 --- a/world/Cargo.toml
395 +++ b/world/Cargo.toml
396 @@ -7,11 +7,11 @@ edition = "2021"
397 [features]
398 use-dyn-lib = ["common-dynlib"]
399 be-dyn-lib = []
400 -simd = ["vek/platform_intrinsics", "packed_simd"]
401 +simd = ["vek/platform_intrinsics"]
402 bin_compression = ["lz-fear", "deflate", "flate2", "image/jpeg", "num-traits", "fallible-iterator", "rstar", "cli"]
403 cli = ["clap", "signal-hook", "indicatif"]
405 -default = ["simd"]
406 +default = []
408 [dependencies]
409 common = { package = "veloren-common", path = "../common" }
410 @@ -36,7 +36,6 @@ tracing = { workspace = true }
411 rand = { workspace = true }
412 rand_chacha = { workspace = true }
413 arr_macro = "0.2.1"
414 -packed_simd = { version = "0.3.9", optional = true }
415 rayon = { workspace = true }
416 serde = { workspace = true }
417 ron = { workspace = true }
418 diff --git a/world/src/site2/gen.rs b/world/src/site2/gen.rs
419 index 59c57766..0800ccee 100644
420 --- a/world/src/site2/gen.rs
421 +++ b/world/src/site2/gen.rs
422 @@ -1415,18 +1415,6 @@ impl<'a, const N: usize> PrimitiveTransform for [PrimitiveRef<'a>; N] {
426 -pub trait PrimitiveGroupFill<const N: usize> {
427 - fn fill_many(self, fills: [Fill; N]);
430 -impl<const N: usize> PrimitiveGroupFill<N> for [PrimitiveRef<'_>; N] {
431 - fn fill_many(self, fills: [Fill; N]) {
432 - for i in 0..N {
433 - self[i].fill(fills[i].clone());
438 pub trait Structure {
439 #[cfg(feature = "use-dyn-lib")]
440 const UPDATE_FN: &'static [u8];