FuelLabs/fuel-core · error · anyhow::Error

The VM instance was not found

Error message

The VM instance was not found

What it means

Error "The VM instance was not found" thrown in FuelLabs/fuel-core.

Source

Thrown at crates/fuel-core/src/schema/dap.rs:224

            MemoryInstance::new(),
            vm_database,
            interpreter_params,
        );
        vm.transact(ready_tx).map_err(|e| anyhow::anyhow!(e))?;
        self.vm.insert(id.clone(), vm).ok_or_else(|| {
            io::Error::new(io::ErrorKind::NotFound, "The VM instance was not found")
        })?;
        Ok(())
    }

    pub fn exec(&mut self, id: &ID, op: Instruction) -> anyhow::Result<()> {
        self.vm
            .get_mut(id)
            .map(|vm| vm.instruction::<_, false>(op))
            .transpose()
            .map_err(|e| anyhow::anyhow!(e))?
            .map(|_| ())
            .ok_or_else(|| anyhow::anyhow!("The VM instance was not found"))
    }

    fn vm_database(storage: &Database<OnChain>) -> anyhow::Result<FrozenDatabase> {
        let view = storage.latest_view()?;
        let block = view
            .get_current_block()?
            .ok_or(not_found!("Block for VMDatabase"))?;

        let application_header = block.header().as_empty_application_header();

        let vm_database = VmStorage::new(
            view.into_transaction(),
            block.header().consensus(),
            &application_header,
            // TODO: Use a real coinbase address
            Default::default(),
        );

View on GitHub (pinned to b9d4d170da)

When it happens

Trigger: Thrown at crates/fuel-core/src/schema/dap.rs:224 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of FuelLabs/fuel-core@b9d4d170da (2026-08-16). Data as JSON: /api/errors/0b34d4e910c87cd9. Report an issue: GitHub.