Skip to content

Chris/schy 250 improve wasm integrations#99

Merged
cbrady merged 9 commits intomainfrom
chris/schy-250-improve-wasm-integrations
Apr 1, 2026
Merged

Chris/schy 250 improve wasm integrations#99
cbrady merged 9 commits intomainfrom
chris/schy-250-improve-wasm-integrations

Conversation

@cbrady
Copy link
Copy Markdown
Contributor

@cbrady cbrady commented Mar 26, 2026

No description provided.

@cbrady cbrady self-assigned this Mar 26, 2026
@cbrady cbrady requested a review from a team as a code owner March 26, 2026 15:30
@cbrady cbrady force-pushed the chris/schy-250-improve-wasm-integrations branch from 3f2a3ac to 80d3faf Compare March 26, 2026 22:23
Copy link
Copy Markdown
Contributor

@bpapillon bpapillon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to update package.json to include wasm files right?

Side note - I updated our E2E tests so that we could smoke test for issues like this, I can use this case to test whether this testing mode actually catches the intended problem

@cbrady cbrady force-pushed the chris/schy-250-improve-wasm-integrations branch from ea28ac1 to cb8b880 Compare March 31, 2026 16:56
@cbrady cbrady requested a review from bpapillon March 31, 2026 17:05
this.wasmInstance = new wasm.RulesEngineJS();
this.initialized = true;
} catch (error) {
throw new Error(`Failed to initialize WASM rules engine: ${error}`);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I run tests against this a built sdk and datastream enabled, I always hit this catch case and fall back to non-datastream rule evaluation. I think it may be because the path here does not match where the file is placed in dist/:

^schematic-node (chris/schy-250-improve-wasm-integrations)$ ls -al dist/*.wasm
-rw-r--r--  1 bpapillon  staff  324035 Mar  2 14:25 dist/rulesengine_bg.wasm
^schematic-node (chris/schy-250-improve-wasm-integrations)$ ls -al dist/wasm/
total 0
drwxr-xr-x   2 bpapillon  staff    64 Mar 31 08:20 .
drwxr-xr-x  37 bpapillon  staff  1184 Mar 31 08:20 ..

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i tnink this is because you need to download the wasm files before you build ./script/download-wasm.sh now that we don't have the file checked in. maybe we should add a validation that the files are there when we build.

@cbrady cbrady requested a review from bpapillon March 31, 2026 19:37
@cbrady cbrady force-pushed the chris/schy-250-improve-wasm-integrations branch from f55ddae to 5840470 Compare March 31, 2026 23:31
@cbrady cbrady merged commit 16154dd into main Apr 1, 2026
5 checks passed
@cbrady cbrady deleted the chris/schy-250-improve-wasm-integrations branch April 1, 2026 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants