diff --git a/Cargo.lock b/Cargo.lock
index 3fa84a0562..bac8d32ff4 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -30,9 +30,9 @@ dependencies = [
[[package]]
name = "aho-corasick"
-version = "1.0.4"
+version = "1.0.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6748e8def348ed4d14996fa801f4122cd763fff530258cdc03f64b25f89d3a5a"
+checksum = "0c378d78423fdad8089616f827526ee33c19f2fddbd5de1629152c9593ba4783"
dependencies = [
"memchr",
]
@@ -238,23 +238,22 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
[[package]]
name = "clap"
-version = "4.4.1"
+version = "4.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7c8d502cbaec4595d2e7d5f61e318f05417bd2b66fdc3809498f0d3fdf0bea27"
+checksum = "6a13b88d2c62ff462f88e4a121f17a82c1af05693a2f192b5c38d14de73c19f6"
dependencies = [
"clap_builder",
]
[[package]]
name = "clap_builder"
-version = "4.4.1"
+version = "4.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5891c7bc0edb3e1c2204fc5e94009affabeb1821c9e5fdc3959536c5c0bb984d"
+checksum = "2bb9faaa7c2ef94b2743a21f5a29e6f0010dff4caa69ac8e9d6cf8b6fa74da08"
dependencies = [
"anstream",
"anstyle",
"clap_lex",
- "once_cell",
"strsim",
]
@@ -329,9 +328,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5"
[[package]]
name = "errno"
-version = "0.3.2"
+version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6b30f669a7961ef1631673d2766cc92f52d64f7ef354d4fe0ddfd30ed52f0f4f"
+checksum = "136526188508e25c6fef639d7927dfb3e0e3084488bf202267829cf7fc23dbdd"
dependencies = [
"errno-dragonfly",
"libc",
@@ -784,9 +783,9 @@ dependencies = [
[[package]]
name = "memchr"
-version = "2.5.0"
+version = "2.6.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
+checksum = "5486aed0026218e61b8a01d5fbd5a0a134649abb71a0e53b7bc088529dced86e"
[[package]]
name = "mfmt"
@@ -960,7 +959,7 @@ dependencies = [
[[package]]
name = "pen-ffi"
-version = "0.10.17"
+version = "0.10.21"
dependencies = [
"async-stream",
"futures",
@@ -1111,9 +1110,9 @@ checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76"
[[package]]
name = "rustix"
-version = "0.38.9"
+version = "0.38.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9bfe0f2582b4931a45d1fa608f8a8722e8b3c7ac54dd6d5f3b3212791fedef49"
+checksum = "c0c3dde1fc030af041adc40e79c0e7fbcf431dd24870053d187d7c66e4b87453"
dependencies = [
"bitflags 2.4.0",
"errno",
diff --git a/cmd/test/Cargo.lock b/cmd/test/Cargo.lock
index e7a4a6b786..7d55883b91 100644
--- a/cmd/test/Cargo.lock
+++ b/cmd/test/Cargo.lock
@@ -130,15 +130,15 @@ dependencies = [
[[package]]
name = "memchr"
-version = "2.5.0"
+version = "2.6.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
+checksum = "5486aed0026218e61b8a01d5fbd5a0a134649abb71a0e53b7bc088529dced86e"
[[package]]
name = "pen-ffi"
-version = "0.10.17"
+version = "0.10.21"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ba6fe5047daeb8413fbce2f5e5d91653c036e9a15f18deb69f3f0e94a99a3ec1"
+checksum = "7687a9093121736522e3865a73077bb2c766b62f5edd64e98858f56132b5b00c"
dependencies = [
"async-stream",
"futures",
diff --git a/lib/ffi/Cargo.toml b/lib/ffi/Cargo.toml
index 783fb22fc2..6e4ab3127c 100644
--- a/lib/ffi/Cargo.toml
+++ b/lib/ffi/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "pen-ffi"
description = "FFI library for Pen programming language"
-version = "0.10.17"
+version = "0.10.21"
publish = true
edition = "2021"
license = "MIT"
diff --git a/lib/ffi/src/runtime.rs b/lib/ffi/src/runtime.rs
index f5d6f2751c..033c38c022 100644
--- a/lib/ffi/src/runtime.rs
+++ b/lib/ffi/src/runtime.rs
@@ -5,11 +5,10 @@ use error::RuntimeError;
use std::sync::RwLock;
use tokio::runtime::Handle;
-#[no_mangle]
-static _PEN_FFI_RUNTIME_HANDLE: RwLock