Compare commits

..

No commits in common. "90c8a7c3028bd6836dea5655221277a25d457653" and "4165cab701823f82016dd1efa950a579e7d8b9d3" have entirely different histories.

3 changed files with 16 additions and 25 deletions

View file

@ -5,12 +5,6 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [0.6.2.0]
### Changed
- Performance enhancement for transaction creation
## [0.6.1.1] ## [0.6.1.1]
### Added ### Added

View file

@ -136,13 +136,9 @@ createTransaction ::
-> Bool -- ^ True to build, False to estimate fee -> Bool -- ^ True to build, False to estimate fee
-> Either TxError HexString -> Either TxError HexString
createTransaction sapAnchor orchAnchor tSpend sSpend oSpend outgoing sParams oParams znet bh build = createTransaction sapAnchor orchAnchor tSpend sSpend oSpend outgoing sParams oParams znet bh build =
processResult $! txResult if BS.length (hexBytes txResult) > 1
where then Right txResult
processResult :: HexString -> Either TxError HexString else case head (BS.unpack $ hexBytes txResult) of
processResult input =
if BS.length (hexBytes input) > 1
then Right input
else case head (BS.unpack $ hexBytes input) of
0 -> Left InsufficientFunds 0 -> Left InsufficientFunds
1 -> Left ChangeRequired 1 -> Left ChangeRequired
2 -> Left Fee 2 -> Left Fee
@ -155,6 +151,7 @@ createTransaction sapAnchor orchAnchor tSpend sSpend oSpend outgoing sParams oPa
9 -> Left SaplingBuilderNotAvailable 9 -> Left SaplingBuilderNotAvailable
10 -> Left OrchardBuilderNotAvailable 10 -> Left OrchardBuilderNotAvailable
_ -> Left ZHError _ -> Left ZHError
where
txResult = txResult =
withPureBorshVarBuffer $ withPureBorshVarBuffer $
rustWrapperCreateTx rustWrapperCreateTx

View file

@ -5,7 +5,7 @@ cabal-version: 3.0
-- see: https://github.com/sol/hpack -- see: https://github.com/sol/hpack
name: zcash-haskell name: zcash-haskell
version: 0.6.2.0 version: 0.6.1.1
synopsis: Utilities to interact with the Zcash blockchain synopsis: Utilities to interact with the Zcash blockchain
description: Please see the README on the repo at <https://git.vergara.tech/Vergara_Tech/zcash-haskell#readme> description: Please see the README on the repo at <https://git.vergara.tech/Vergara_Tech/zcash-haskell#readme>
category: Blockchain category: Blockchain