Files
nym/wasm/client/src/error.rs
T
Mark Sinclair 626d013547 Switch from yarn to pnpm (#6779)
* switch from yarn to pnpm

* Remove full-nym-wasm (#6796)

* Remove nym-browser-extension (#6798)

* Remove nym-browser-extension

* remove unused from makefile

* Remove Node tester (#6800)

* Remove dom-utils (#6801)

* gh-actions: remove pnpm version

* nuke dist and pkg

* add missing dependency

* set node version to 24 and pnpm version to 11

* upgrade lock file from pnpm version 9 to 11

* pnpm add approved builds

* yarn -> pnpm

* upgrade jest version

* yarn -> pnpm

* Remove unused cfg; clippy!

* pnpm: when dev mode is on, unfreeze the lock file

* pnpm approve more scripts

* pnpm syntax error

* add `pnpm i`

* disable eslint temporarily while switching to biome in later PR

---------

Co-authored-by: Mark Sinclair <mmsinclair@users.noreply.github.com>
Co-authored-by: mfahampshire <maxhampshire@pm.me>
2026-05-22 20:29:51 +01:00

41 lines
1.0 KiB
Rust

// Copyright 2023 - Nym Technologies SA <contact@nymtech.net>
// SPDX-License-Identifier: Apache-2.0
use nym_wasm_client_core::error::WasmCoreError;
use nym_wasm_client_core::topology::WasmTopologyError;
use nym_wasm_client_core::ClientCoreError;
use nym_wasm_utils::wasm_error;
use thiserror::Error;
#[derive(Debug, Error)]
pub enum WasmClientError {
#[error(transparent)]
CoreError {
#[from]
source: WasmCoreError,
},
#[error("failed to parse mix config options: {source}")]
MalformedConfigOptions {
#[from]
source: serde_wasm_bindgen::Error,
},
#[error("provided topology was malformed: {source}")]
InvalidTopology {
#[from]
source: WasmTopologyError,
},
}
// I dislike this so much - there must be a better way.
impl From<ClientCoreError> for WasmClientError {
fn from(value: ClientCoreError) -> Self {
WasmClientError::CoreError {
source: WasmCoreError::BaseClientError { source: value },
}
}
}
wasm_error!(WasmClientError);