@dashevo/wasm-dpp 4.0.0-beta.2 → 4.0.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/wasm/wasm_dpp.d.ts +639 -613
- package/dist/wasm/wasm_dpp.js +30 -18
- package/dist/wasm/wasm_dpp_bg.js +1 -1
- package/lib/wasm/wasm_dpp.d.ts +639 -613
- package/package.json +2 -2
- package/src/errors/consensus/consensus_error.rs +7 -1
- package/src/state_transition/state_transition_factory.rs +4 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dashevo/wasm-dpp",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.4",
|
|
4
4
|
"description": "The JavaScript implementation of the Dash Platform Protocol",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"@babel/core": "^7.26.10",
|
|
45
45
|
"@babel/preset-env": "^7.26.9",
|
|
46
46
|
"@dashevo/dashcore-lib": "~0.22.0",
|
|
47
|
-
"@dashevo/dpns-contract": "4.0.0-beta.
|
|
47
|
+
"@dashevo/dpns-contract": "4.0.0-beta.4",
|
|
48
48
|
"@types/bs58": "^4.0.1",
|
|
49
49
|
"@types/node": "^20.10.0",
|
|
50
50
|
"@yarnpkg/pnpify": "^4.0.0-rc.42",
|
|
@@ -95,7 +95,7 @@ use dpp::consensus::state::shielded::insufficient_shielded_fee_error::Insufficie
|
|
|
95
95
|
use dpp::consensus::state::shielded::invalid_anchor_error::InvalidAnchorError;
|
|
96
96
|
use dpp::consensus::state::shielded::invalid_shielded_proof_error::InvalidShieldedProofError;
|
|
97
97
|
use dpp::consensus::state::shielded::nullifier_already_spent_error::NullifierAlreadySpentError;
|
|
98
|
-
use dpp::consensus::basic::state_transition::{StateTransitionNotActiveError, TransitionOverMaxInputsError, TransitionOverMaxOutputsError, InputWitnessCountMismatchError, TransitionNoInputsError, TransitionNoOutputsError, FeeStrategyEmptyError, FeeStrategyDuplicateError, FeeStrategyIndexOutOfBoundsError, FeeStrategyTooManyStepsError, InputBelowMinimumError, OutputBelowMinimumError, InputOutputBalanceMismatchError, OutputsNotGreaterThanInputsError, WithdrawalBalanceMismatchError, InsufficientFundingAmountError, InputsNotLessThanOutputsError, OutputAddressAlsoInputError, InvalidRemainderOutputCountError, WithdrawalBelowMinAmountError, ShieldedNoActionsError, ShieldedTooManyActionsError, ShieldedEmptyProofError, ShieldedZeroAnchorError, ShieldedInvalidValueBalanceError, ShieldedEncryptedNoteSizeMismatchError};
|
|
98
|
+
use dpp::consensus::basic::state_transition::{StateTransitionNotActiveError, TransitionOverMaxInputsError, TransitionOverMaxOutputsError, InputWitnessCountMismatchError, TransitionNoInputsError, TransitionNoOutputsError, FeeStrategyEmptyError, FeeStrategyDuplicateError, FeeStrategyIndexOutOfBoundsError, FeeStrategyTooManyStepsError, InputBelowMinimumError, OutputBelowMinimumError, InputOutputBalanceMismatchError, OutputsNotGreaterThanInputsError, WithdrawalBalanceMismatchError, InsufficientFundingAmountError, InputsNotLessThanOutputsError, OutputAddressAlsoInputError, InvalidRemainderOutputCountError, WithdrawalBelowMinAmountError, ShieldedNoActionsError, ShieldedTooManyActionsError, ShieldedEmptyProofError, ShieldedZeroAnchorError, ShieldedInvalidValueBalanceError, ShieldedEncryptedNoteSizeMismatchError, ShieldedImplicitFeeCapExceededError, ShieldedInvalidDenominationError};
|
|
99
99
|
use dpp::consensus::state::voting::masternode_incorrect_voter_identity_id_error::MasternodeIncorrectVoterIdentityIdError;
|
|
100
100
|
use dpp::consensus::state::voting::masternode_incorrect_voting_address_error::MasternodeIncorrectVotingAddressError;
|
|
101
101
|
use dpp::consensus::state::voting::masternode_not_found_error::MasternodeNotFoundError;
|
|
@@ -964,6 +964,12 @@ fn from_basic_error(basic_error: &BasicError) -> JsValue {
|
|
|
964
964
|
BasicError::ShieldedEncryptedNoteSizeMismatchError(e) => {
|
|
965
965
|
generic_consensus_error!(ShieldedEncryptedNoteSizeMismatchError, e).into()
|
|
966
966
|
}
|
|
967
|
+
BasicError::ShieldedImplicitFeeCapExceededError(e) => {
|
|
968
|
+
generic_consensus_error!(ShieldedImplicitFeeCapExceededError, e).into()
|
|
969
|
+
}
|
|
970
|
+
BasicError::ShieldedInvalidDenominationError(e) => {
|
|
971
|
+
generic_consensus_error!(ShieldedInvalidDenominationError, e).into()
|
|
972
|
+
}
|
|
967
973
|
}
|
|
968
974
|
}
|
|
969
975
|
|
|
@@ -83,9 +83,10 @@ impl StateTransitionFactoryWasm {
|
|
|
83
83
|
| StateTransition::ShieldedTransfer(_)
|
|
84
84
|
| StateTransition::Unshield(_)
|
|
85
85
|
| StateTransition::ShieldFromAssetLock(_)
|
|
86
|
-
| StateTransition::ShieldedWithdrawal(_)
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
| StateTransition::ShieldedWithdrawal(_)
|
|
87
|
+
| StateTransition::IdentityCreateFromShieldedPool(_) => Err(JsValue::from_str(
|
|
88
|
+
"shielded transitions are not yet supported in wasm-dpp StateTransitionFactory",
|
|
89
|
+
)),
|
|
89
90
|
},
|
|
90
91
|
Err(dpp::ProtocolError::StateTransitionError(e)) => match e {
|
|
91
92
|
StateTransitionError::InvalidStateTransitionError {
|