diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml
index fe74ff0dd..89b809f93 100644
--- a/.github/workflows/pipeline.yml
+++ b/.github/workflows/pipeline.yml
@@ -25,7 +25,7 @@ concurrency:
cancel-in-progress: true
jobs:
build-image:
- runs-on: neon-evm-1
+ runs-on: ["self-hosted", "k8s-prod"]
outputs:
evm_tag: ${{ steps.tags.outputs.evm_tag }}
evm_sha_tag: ${{ steps.tags.outputs.evm_sha_tag }}
@@ -33,9 +33,13 @@ jobs:
is_evm_release: ${{ steps.tags.outputs.is_evm_release }}
neon_test_tag: ${{ steps.tags.outputs.neon_test_tag }}
steps:
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v3
+ - uses: actions/setup-python@v5
- uses: actions/checkout@v4
with:
fetch-depth: 0
+ - run: pip install -r ./.github/workflows/requirements.txt
- name: Specify image tags
run: |
python3 ./.github/workflows/deploy.py specify_image_tags \
@@ -60,13 +64,17 @@ jobs:
--evm_sha_tag=${{ steps.tags.outputs.evm_sha_tag }} \
--evm_tag=${{ steps.tags.outputs.evm_tag }}
run-evm-tests:
- runs-on: test-runner
+ runs-on: ["self-hosted", "k8s-prod"]
needs:
- build-image
steps:
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v3
+ - uses: actions/setup-python@v5
- uses: actions/checkout@v4
with:
fetch-depth: 0
+ - run: pip install -r ./.github/workflows/requirements.txt
- name: Run tests
run: |
python3 ./.github/workflows/deploy.py run_tests \
@@ -78,13 +86,17 @@ jobs:
if: "failure()"
uses: "andymckay/cancel-action@0.4"
trigger-proxy-tests:
- runs-on: trigger-runner
+ runs-on: ["self-hosted", "k8s-prod"]
needs:
- build-image
steps:
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v3
+ - uses: actions/setup-python@v5
- uses: actions/checkout@v4
with:
fetch-depth: 0
+ - run: pip install -r ./.github/workflows/requirements.txt
- name: Trigger proxy build
run: |
python3 ./.github/workflows/deploy.py trigger_proxy_action \
@@ -100,15 +112,19 @@ jobs:
if: "failure()"
uses: "andymckay/cancel-action@0.4"
finalize-image:
- runs-on: neon-evm-1
+ runs-on: ["self-hosted", "k8s-prod"]
needs:
- build-image
- trigger-proxy-tests
- run-evm-tests
steps:
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v3
+ - uses: actions/setup-python@v5
- uses: actions/checkout@v4
with:
fetch-depth: 0
+ - run: pip install -r ./.github/workflows/requirements.txt
- name: Finalize image
run: |
python3 ./.github/workflows/deploy.py finalize_image \
diff --git a/evm_loader/Cargo.lock b/evm_loader/Cargo.lock
index 0a0544808..29124faad 100644
--- a/evm_loader/Cargo.lock
+++ b/evm_loader/Cargo.lock
@@ -3609,6 +3609,7 @@ dependencies = [
"enum_dispatch",
"ethnum",
"evm-loader",
+ "futures",
"goblin 0.8.2",
"hex",
"hex-literal",
diff --git a/evm_loader/lib-interface/src/lib.rs b/evm_loader/lib-interface/src/lib.rs
index 0a1781d21..89c07401d 100644
--- a/evm_loader/lib-interface/src/lib.rs
+++ b/evm_loader/lib-interface/src/lib.rs
@@ -17,7 +17,7 @@ use abi_stable::{
#[repr(C)]
#[derive(StableAbi)]
-#[sabi(kind(Prefix(prefix_ref = NeonEVMLib_Ref)))]
+#[sabi(kind(Prefix(prefix_ref = NeonEVMLibRef)))]
#[sabi(missing_field(panic))]
pub struct NeonEVMLib {
pub hash: extern "C" fn() -> RString,
@@ -28,8 +28,8 @@ pub struct NeonEVMLib {
}
#[allow(clippy::use_self)]
-impl RootModule for NeonEVMLib_Ref {
- abi_stable::declare_root_module_statics! {NeonEVMLib_Ref}
+impl RootModule for NeonEVMLibRef {
+ abi_stable::declare_root_module_statics! {NeonEVMLibRef}
const BASE_NAME: &'static str = "neon-lib-interface";
const NAME: &'static str = "neon-lib-interface";
@@ -46,14 +46,14 @@ pub enum NeonEVMLibLoadError {
pub fn load_libraries
(
directory: P,
-) -> Result, NeonEVMLibLoadError>
+) -> Result, NeonEVMLibLoadError>
where
P: AsRef,
{
let paths = std::fs::read_dir(directory)?;
let mut result = HashMap::new();
for path in paths {
- let lib = NeonEVMLib_Ref::load_from_file(&path?.path())?;
+ let lib = NeonEVMLibRef::load_from_file(&path?.path())?;
let hash = lib.hash()();
result.insert(hash.into_string(), lib);
diff --git a/evm_loader/lib/Cargo.toml b/evm_loader/lib/Cargo.toml
index 7866135ed..175c06b23 100644
--- a/evm_loader/lib/Cargo.toml
+++ b/evm_loader/lib/Cargo.toml
@@ -52,6 +52,7 @@ clap = "2.34.0"
lazy_static = "1.5.0"
elsa = "1.10.0"
arrayref = "0.3.8"
+futures = "0.3.30"
[dev-dependencies]
hex-literal = "0.4.1"
diff --git a/evm_loader/lib/src/account_storage.rs b/evm_loader/lib/src/account_storage.rs
index 0a4fda17d..46fa908a8 100644
--- a/evm_loader/lib/src/account_storage.rs
+++ b/evm_loader/lib/src/account_storage.rs
@@ -918,11 +918,6 @@ impl<'a, T: Rpc> EmulatorAccountStorage<'_, T> {
let new_lamports = new_acc.lamports;
let new_size = new_acc.get_length();
- if new_acc.is_busy() && new_lamports < self.rent.minimum_balance(new_acc.get_length()) {
- info!("Account {pubkey} is not rent exempt");
- return Err(ProgramError::AccountNotRentExempt.into());
- }
-
let old_lamports = lamports_after_upgrade.unwrap_or(original_lamports);
old_lamports_sum += old_lamports;
new_lamports_sum += new_lamports;
diff --git a/evm_loader/lib/src/account_storage_tests.rs b/evm_loader/lib/src/account_storage_tests.rs
index d5f68dc50..5445f3e15 100644
--- a/evm_loader/lib/src/account_storage_tests.rs
+++ b/evm_loader/lib/src/account_storage_tests.rs
@@ -3,6 +3,7 @@ use crate::rpc;
use crate::tracing::AccountOverride;
use evm_loader::types::vector::VectorVecExt;
use hex_literal::hex;
+use solana_account_decoder::UiDataSliceConfig;
use std::collections::HashMap;
use std::str::FromStr;
@@ -19,6 +20,8 @@ mod mock_rpc_client {
use solana_sdk::pubkey::Pubkey;
use std::collections::HashMap;
+ use solana_account_decoder::UiDataSliceConfig;
+
pub struct MockRpcClient {
accounts: HashMap,
}
@@ -33,7 +36,31 @@ mod mock_rpc_client {
#[async_trait(?Send)]
impl Rpc for MockRpcClient {
- async fn get_account(&self, key: &Pubkey) -> ClientResult