change to no longer parallel for edges (#6705)

Signed-off-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
Jess Frazelle
2025-05-05 18:06:20 -07:00
committed by GitHub
parent 8f72920764
commit 1ed6bb8a7c
12 changed files with 23 additions and 67 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 133 KiB

After

Width:  |  Height:  |  Size: 132 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 116 KiB

After

Width:  |  Height:  |  Size: 116 KiB

View File

@ -29,5 +29,5 @@
} }
} }
], ],
"kcl_version": "0.2.63" "kcl_version": "0.2.66"
} }

1
package-lock.json generated
View File

@ -2139,7 +2139,6 @@
}, },
"node_modules/@clack/prompts/node_modules/is-unicode-supported": { "node_modules/@clack/prompts/node_modules/is-unicode-supported": {
"version": "1.3.0", "version": "1.3.0",
"extraneous": true,
"inBundle": true, "inBundle": true,
"license": "MIT", "license": "MIT",
"engines": { "engines": {

View File

@ -337,18 +337,6 @@ pub(crate) async fn do_post_extrude<'a>(
let next_adjacent_edge_uuid = exec_state.next_uuid(); let next_adjacent_edge_uuid = exec_state.next_uuid();
let get_all_edge_faces_opposite_uuid = exec_state.next_uuid(); let get_all_edge_faces_opposite_uuid = exec_state.next_uuid();
let get_all_edge_faces_next_uuid = exec_state.next_uuid(); let get_all_edge_faces_next_uuid = exec_state.next_uuid();
#[cfg(any(not(test), not(feature = "artifact-graph"), not(target_arch = "wasm32")))]
#[allow(unused_variables)]
let single_threaded = false;
// When running in vitest, we need to run this in a single thread.
// Because their workers are complete shit.
#[cfg(target_arch = "wasm32")]
let single_threaded = crate::wasm::vitest::running_in_vitest();
// If we are running in a test, for the arifact graph to be deterministic and not fail
// after say a fillet runs concurrently, we need to make sure that the
// async tasks are done before we return.
#[cfg(all(test, feature = "artifact-graph", not(target_arch = "wasm32")))]
let single_threaded = true;
// Get faces for original edge // Get faces for original edge
// Since this one is batched we can just run it. // Since this one is batched we can just run it.
@ -361,35 +349,6 @@ pub(crate) async fn do_post_extrude<'a>(
) )
.await?; .await?;
if !single_threaded {
args.ctx
.engine
.async_tasks()
.spawn(get_bg_edge_info_opposite(
args_cloned.clone(),
curve_id,
sketch.id,
face_id,
opposite_edge_uuid,
get_all_edge_faces_opposite_uuid,
single_threaded,
))
.await;
args.ctx
.engine
.async_tasks()
.spawn(get_bg_edge_info_next(
args_cloned,
curve_id,
sketch.id,
face_id,
next_adjacent_edge_uuid,
get_all_edge_faces_next_uuid,
single_threaded,
))
.await;
} else {
get_bg_edge_info_opposite( get_bg_edge_info_opposite(
args_cloned.clone(), args_cloned.clone(),
curve_id, curve_id,
@ -397,7 +356,7 @@ pub(crate) async fn do_post_extrude<'a>(
face_id, face_id,
opposite_edge_uuid, opposite_edge_uuid,
get_all_edge_faces_opposite_uuid, get_all_edge_faces_opposite_uuid,
single_threaded, true,
) )
.await?; .await?;
@ -408,11 +367,10 @@ pub(crate) async fn do_post_extrude<'a>(
face_id, face_id,
next_adjacent_edge_uuid, next_adjacent_edge_uuid,
get_all_edge_faces_next_uuid, get_all_edge_faces_next_uuid,
single_threaded, true,
) )
.await?; .await?;
} }
}
let Faces { let Faces {
sides: face_id_map, sides: face_id_map,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 65 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

After

Width:  |  Height:  |  Size: 68 KiB

View File

@ -608,7 +608,7 @@ flowchart LR
83 --- 246 83 --- 246
83 --- 289 83 --- 289
90 --- 159 90 --- 159
90 x--> 192 90 x--> 193
90 --- 226 90 --- 226
90 --- 271 90 --- 271
104 --- 151 104 --- 151
@ -910,7 +910,7 @@ flowchart LR
211 <--x 191 211 <--x 191
212 <--x 191 212 <--x 191
213 <--x 191 213 <--x 191
226 <--x 193 226 <--x 192
239 <--x 195 239 <--x 195
240 <--x 195 240 <--x 195
241 <--x 195 241 <--x 195

Binary file not shown.

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 KiB

After

Width:  |  Height:  |  Size: 57 KiB

View File

@ -709,7 +709,6 @@ flowchart LR
115 --- 179 115 --- 179
115 x--> 228 115 x--> 228
115 --- 256 115 --- 256
115 x--> 307
115 --- 308 115 --- 308
164 <--x 116 164 <--x 116
116 --- 184 116 --- 184

Binary file not shown.

Before

Width:  |  Height:  |  Size: 85 KiB

After

Width:  |  Height:  |  Size: 85 KiB