aurae-runtime / aurae

Distributed systems runtime daemon written in Rust.
https://aurae.io
Apache License 2.0
1.83k stars 89 forks source link

fix(auraescript): removal of initializeAsyncOps and exposing Deno.core.ops for deno_runtime::MainWorker #474

Closed seanwatters closed 1 year ago

seanwatters commented 1 year ago

The initializeAsyncOps function has been deprecated and no longer available on latest deno_runtime/deno_core. Deno prefers usage of Deno.core.opAsync("op_name", ...args).

Additionally, deno_runtime::MainWorker does not initialize ops unless you use the force_op_registration method on ExtensionBuilder.

Updates Deno.core to Deno[Deno.internal].core for MainWorker as it "hides" host operations with an internal namespace.

Un-async-ifies as__aurae_config__try_default, as__aurae_config__from_options and as__aurae_config__parse_from_file which do not make use of the await keyword or any async paradigms.

seanwatters commented 1 year ago

@dmah42 this should be all good to go now. Am going to open another PR for the removal of aurae.print once this one is merged.

To test whether or not it's working I ran cargo run ../examples/cells.ts from the auraescript workspace and everything looked good.

seanwatters commented 1 year ago

here is the PR for removing aurae.print: https://github.com/aurae-runtime/aurae/pull/477