Skip to content

Commit

Permalink
Bump kittycad
Browse files Browse the repository at this point in the history
  • Loading branch information
adamchalmers committed Aug 23, 2024
1 parent 22a9f44 commit 4246103
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 10 deletions.
7 changes: 4 additions & 3 deletions src/wasm-lib/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/wasm-lib/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ members = [
]

[workspace.dependencies]
kittycad = { version = "0.3.14", default-features = false, features = ["js", "requests"] }
http = "0.2.12"
kittycad = { version = "0.3.16", default-features = false, features = ["js", "requests"] }
kittycad-modeling-session = "0.1.4"

[[test]]
Expand Down
1 change: 1 addition & 0 deletions src/wasm-lib/kcl/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ form_urlencoded = "1.2.1"
futures = { version = "0.3.30" }
git_rev = "0.1.0"
gltf-json = "1.4.1"
http = { workspace = true }
image = { version = "0.25.1", default-features = false, features = ["png"] }
kittycad = { workspace = true, features = ["clap"] }
lazy_static = "1.5.0"
Expand Down
11 changes: 6 additions & 5 deletions src/wasm-lib/kcl/src/executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1664,8 +1664,8 @@ impl From<crate::settings::types::ModelingSettings> for ExecutorSettings {
impl ExecutorContext {
/// Create a new default executor context.
#[cfg(not(target_arch = "wasm32"))]
pub async fn new(client: &kittycad::Client, settings: ExecutorSettings) -> Result<Self> {
let ws = client
pub async fn new(client: &kittycad::Client, settings: ExecutorSettings) -> Result<(Self, http::HeaderMap)> {
let (ws, headers) = client
.modeling()
.commands_ws(
None,
Expand Down Expand Up @@ -1697,13 +1697,14 @@ impl ExecutorContext {
)
.await?;

Ok(Self {
let slf = Self {
engine,
fs: Arc::new(FileManager::new()),
stdlib: Arc::new(StdLib::new()),
settings,
is_mock: false,
})
};
Ok((slf, headers))
}

/// For executing unit tests.
Expand Down Expand Up @@ -1736,7 +1737,7 @@ impl ExecutorContext {
client.set_base_url(addr);
}

let ctx = ExecutorContext::new(
let (ctx, _headers) = ExecutorContext::new(
&client,
ExecutorSettings {
units,
Expand Down
1 change: 1 addition & 0 deletions src/wasm-lib/kcl/src/std/shell.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ async fn inner_shell(
args.batch_modeling_cmd(
uuid::Uuid::new_v4(),
ModelingCmd::Solid3DShellFace {
hollow: false,
face_ids,
object_id: extrude_group.id,
shell_thickness: data.thickness,
Expand Down
2 changes: 1 addition & 1 deletion src/wasm-lib/kcl/src/test_server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ async fn new_context(units: UnitLength) -> anyhow::Result<ExecutorContext> {
client.set_base_url(addr);
}

let ctx = ExecutorContext::new(
let (ctx, _headers) = ExecutorContext::new(
&client,
ExecutorSettings {
units,
Expand Down

0 comments on commit 4246103

Please sign in to comment.