Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
275 commits
Select commit Hold shift + click to select a range
d139b34
Merge branch 'feat/next' into TOOL-356-add-smart-contracts-controller
danielailie Nov 14, 2024
4751fce
Fix integration tests
danielailie Nov 15, 2024
3881372
Fix integration tests
danielailie Nov 15, 2024
60cc1ed
Add token Management controller
danielailie Nov 15, 2024
c62e53e
Update input name
danielailie Nov 15, 2024
0002e96
Update input naming
danielailie Nov 15, 2024
c0a046e
Merge pull request #535 from multiversx/TOOL-356-add-smart-contracts-…
danielailie Nov 18, 2024
1d206ec
Update types
danielailie Nov 18, 2024
096a825
Merge branch 'feat/next' into TOOL-360-add-token-management-controller
danielailie Nov 18, 2024
a026090
Add transfers controller
danielailie Nov 18, 2024
73ac82f
Run build on all PRs
danielailie Nov 18, 2024
cf1d478
Update input namings
danielailie Nov 18, 2024
4ab1934
Fix test
danielailie Nov 18, 2024
1643a52
Fix tests
danielailie Nov 18, 2024
50a09e1
Fix integration tests
danielailie Nov 18, 2024
266fdb3
Update naming to match factory
danielailie Nov 18, 2024
4852ab7
Merge branch 'TOOL-360-add-token-management-controller' into TOOL-365…
danielailie Nov 18, 2024
49d3204
Merge pull request #536 from multiversx/TOOL-360-add-token-management…
danielailie Nov 18, 2024
a344eae
Update name for input
danielailie Nov 18, 2024
0bdc506
Merge pull request #537 from multiversx/TOOL-365-add-transfers-contro…
danielailie Nov 18, 2024
5860316
Add entrypoints
danielailie Nov 18, 2024
8882e4c
Code review follow up
danielailie Nov 19, 2024
dd67b79
Fix test for relayed controller
danielailie Nov 19, 2024
f377ac6
Merge pull request #538 from multiversx/TOOL-366-add-entrypoints
danielailie Nov 19, 2024
aa68ee4
Remove transation outcome and fix changes
danielailie Nov 19, 2024
563b046
Sync transactionEvent to specs
danielailie Nov 20, 2024
53ecc8c
Remove deprecated files
danielailie Nov 20, 2024
4df5337
Fix test
danielailie Nov 20, 2024
8b16458
Add logging
danielailie Nov 20, 2024
3c8a02e
More logging
danielailie Nov 21, 2024
74213b1
More logging
danielailie Nov 21, 2024
2b68d3a
Fix tests and remove console logs
danielailie Nov 21, 2024
5fb3f56
Fix smart contract test
danielailie Nov 21, 2024
16ce836
Fix tests
danielailie Nov 21, 2024
90e2959
decrease integration waiting time
danielailie Nov 21, 2024
afbccc8
Fix tests
danielailie Nov 21, 2024
1923352
Fix additional data field
danielailie Nov 21, 2024
981b6c6
Update mapping for sc results
danielailie Nov 22, 2024
d6cdcfe
Fix api Mapping
danielailie Nov 22, 2024
2d08f19
Code review follow up
danielailie Nov 25, 2024
03ab27b
Fix tests
danielailie Nov 25, 2024
8d90e98
FIx tests
danielailie Nov 25, 2024
9a7ed4c
Fix test encoding
danielailie Nov 25, 2024
e948755
Merge pull request #539 from multiversx/TOOL-368-remove-transaction-o…
danielailie Nov 25, 2024
c8000be
Remove result parser and smart contract querties
danielailie Nov 27, 2024
befd1c0
Update integration tests
danielailie Nov 27, 2024
590831f
FIx compiling issue on integration tests
danielailie Nov 27, 2024
5ce1497
Fix imports
danielailie Nov 27, 2024
6d5fd21
Fix Method call
danielailie Nov 27, 2024
ce4e180
Fix smartContractResults mapping
danielailie Nov 27, 2024
9f1b195
fix integration tests
danielailie Dec 5, 2024
e8726f6
Remove tests that dont use factory as they are duplicated
danielailie Dec 5, 2024
915973c
Fix tests
danielailie Dec 5, 2024
fa2b75a
Fix integration tests
danielailie Dec 9, 2024
17177ac
Pass INetworkProvider where needed
danielailie Dec 9, 2024
e8aa3e2
Remove deprecated code
danielailie Dec 9, 2024
d74dc94
Fix interaction tests
danielailie Dec 9, 2024
cff7892
code review follow up
danielailie Dec 9, 2024
29c10e3
Update to type SmartContractQueryInput
danielailie Dec 9, 2024
29f87b8
Merge pull request #540 from multiversx/TOOL-375-remove-results-parser
danielailie Dec 9, 2024
cbe8b53
Fix integration tests
danielailie Dec 9, 2024
893d13a
Update providers tests
danielailie Dec 10, 2024
5069158
Fix providers tests
danielailie Dec 10, 2024
3192410
Update providers tests
danielailie Dec 10, 2024
89f37b2
Merge pull request #541 from multiversx/TOOL-367-clean-up-deprecated-…
danielailie Dec 10, 2024
9916699
Remove ITransaction interface and update Transaction to follow specs
danielailie Dec 10, 2024
992e0ed
Fixed Relayed tests
danielailie Dec 10, 2024
b7ab17f
Fix compile issues on integration tests
danielailie Dec 10, 2024
ca9e3cb
Fix devnet tests
danielailie Dec 10, 2024
b99bfaa
Fixed relayed transactions tests
danielailie Dec 11, 2024
ebac363
Fix transactions tests
danielailie Dec 11, 2024
83ac284
Update transaction mapping
danielailie Dec 11, 2024
7585eb9
Update bech32 to new method toBech32
danielailie Dec 11, 2024
6345f37
Code review follow up
danielailie Dec 11, 2024
372cd24
Merge pull request #542 from multiversx/TOOL-390-update-transaction-t…
danielailie Dec 12, 2024
2553c87
Remove Transaction converter
danielailie Dec 12, 2024
9b42978
Remove IAddress Interface and update to use Address
danielailie Dec 12, 2024
87aef7f
Merge pull request #544 from multiversx/TOOL-397-remove-transaction-c…
danielailie Dec 12, 2024
7d1b260
Merge branch 'main' into Feat/next
danielailie Dec 12, 2024
6689b5c
Fix compile error
danielailie Dec 12, 2024
6ad935f
Merge pull request #546 from multiversx/TOOL-399-remove-i-address-int…
danielailie Dec 12, 2024
7a8c292
Merge pull request #547 from multiversx/MergeMainIntoFeat
danielailie Dec 12, 2024
418d023
Remove unused interfaces (INonce, IGasLimit, IGasPrice, ITransactionO…
danielailie Dec 12, 2024
500104d
Merge pull request #548 from multiversx/TOOL-398-remove-unused-interf…
danielailie Dec 16, 2024
2ce19d5
Remove ITokenTransfer and ITransactionPayload
danielailie Dec 16, 2024
df2420f
Merge pull request #550 from multiversx/TOOL-404-remove-i-token-trans…
danielailie Dec 16, 2024
eaab21a
Update token transfer to follow specs
danielailie Dec 17, 2024
6a28a88
Update Address to follow specs
danielailie Dec 17, 2024
f20e9d4
Fix integration tests
danielailie Dec 17, 2024
bacfc56
Update Integration tests
danielailie Dec 17, 2024
0f0102c
Drop legacy comment
danielailie Dec 17, 2024
f297d23
Remove gas estimator related code
danielailie Dec 17, 2024
b8f4eae
Merge pull request #551 from multiversx/TOOL-405-update-to-use-new-me…
danielailie Dec 17, 2024
ede0df6
Code review follow up
danielailie Dec 18, 2024
23fd5cf
Fix compiling
danielailie Dec 18, 2024
7fa413a
Remove unneeded check
danielailie Dec 18, 2024
483084f
Merge pull request #552 from multiversx/TOOL-407-update-address-to-fo…
danielailie Dec 18, 2024
d482a67
Merge pull request #553 from multiversx/TOOL-408-remove-i-gas-estimat…
danielailie Dec 18, 2024
be16a79
Update code metadata to follow specs
danielailie Dec 18, 2024
61af994
Merge pull request #554 from multiversx/TOOL-409-update-code-metadata…
danielailie Dec 18, 2024
3645a29
Update TransactionOnNetwork to follow specs
danielailie Dec 19, 2024
cd90c4e
Update isCompleted
danielailie Jan 14, 2025
8501e03
remove comment
danielailie Jan 14, 2025
7df8980
Add isCompleted on TranactionStatus and mark as deprecated isExecuted
danielailie Jan 14, 2025
00144af
Add isCompleted and IsSuccessfull falg on transaction status
danielailie Jan 14, 2025
a3ba1c8
Revert IsCompleted and IsSuccessfull methods
danielailie Jan 14, 2025
279eb8d
Remove commented code
danielailie Jan 14, 2025
ab2cad2
Merge pull request #555 from multiversx/TOOL-410-update-transaction-o…
danielailie Jan 15, 2025
b319e26
update network providers to follow specs
danielailie Jan 15, 2025
93db149
Remove unused methods
danielailie Jan 15, 2025
339e723
Remove methods that are not in specs
danielailie Jan 15, 2025
761069e
Add proxy provider tests
danielailie Jan 15, 2025
86aed28
Add proxy provider tests
danielailie Jan 16, 2025
135012d
Add api provider tests
danielailie Jan 16, 2025
a9448f0
Fix failing tests
danielailie Jan 16, 2025
8855cb4
Fix integration test and skip proxy test that returns timeout
danielailie Jan 20, 2025
e3c1738
Update network config to follow specs
danielailie Jan 20, 2025
abe8456
Update Network status
danielailie Jan 20, 2025
5453522
Fix getTokenAccount
danielailie Jan 20, 2025
04d412d
Add logging
danielailie Jan 20, 2025
80d367e
Remove only for tests
danielailie Jan 20, 2025
88c9056
Fix proxy account mapping
danielailie Jan 20, 2025
23ae906
Update to const where posible
danielailie Jan 20, 2025
505262b
Fix proxy test
danielailie Jan 20, 2025
9e14ee4
Add transaction status method
danielailie Jan 20, 2025
5e94b19
remove getBlockArguments and add back transactionStatus
danielailie Jan 20, 2025
a1d1834
Add wrapper over JsonBigInt
danielailie Jan 20, 2025
2500ca9
Remove only
danielailie Jan 20, 2025
8438aa9
Update naming to keep naming convention
danielailie Jan 20, 2025
378e636
Fix tests
danielailie Jan 20, 2025
7e5f1aa
Fix integration tests
danielailie Jan 21, 2025
93600bb
Code review follow up
danielailie Jan 21, 2025
d2847bc
Fix compiling errors
danielailie Jan 21, 2025
bf102a7
add back transaction Status tests
danielailie Jan 21, 2025
628d09b
Merge pull request #557 from multiversx/TOOL-411-synchronize-network-…
danielailie Jan 21, 2025
4ff4408
Add account awaiter
danielailie Jan 21, 2025
8e222fd
Fix file name
danielailie Jan 21, 2025
e0a4889
Add readonly to properties
danielailie Jan 21, 2025
640f269
Merge pull request #559 from multiversx/TOOL-429-add-account-awaiter
danielailie Jan 21, 2025
740ab32
Add missing functions for controller
danielailie Jan 22, 2025
67388e3
Add modify royalties test
danielailie Jan 23, 2025
6d437dd
Add parser tests
danielailie Jan 23, 2025
ea1cba5
Add implementation for missing methods on delegation factory
danielailie Jan 23, 2025
dd4a99a
Revert condition for parser
danielailie Jan 23, 2025
91e4750
Add new line
danielailie Jan 23, 2025
3b88b84
Merge pull request #560 from multiversx/TOOL-431-add-missing-function…
danielailie Jan 23, 2025
ec8ab6c
Merge pull request #561 from multiversx/TOOL-437-implement-missing-fu…
danielailie Jan 23, 2025
0f520a6
Add missing entrypoint functions
danielailie Jan 23, 2025
217392b
Add missing account function
danielailie Jan 28, 2025
7777d39
Add pem entry tests
danielailie Jan 28, 2025
f6929f1
Add keypair tests
danielailie Jan 28, 2025
0bfabf3
Code review follow up
danielailie Jan 29, 2025
8025400
Remove testDecoder as is not needed
danielailie Jan 29, 2025
5eeedd8
Remove testTransaction and TestMessage and update tests
danielailie Jan 29, 2025
0419a0c
Merge pull request #564 from multiversx/TOOL-440-add-account-missing-…
danielailie Jan 29, 2025
efc0fd9
Remove dummy query
danielailie Jan 29, 2025
0c69ddc
Merge pull request #565 from multiversx/TOOL-445-remove-test-transact…
danielailie Jan 29, 2025
5f45564
Remove TransactionHash and hash and update to use TransactionComputer…
danielailie Jan 29, 2025
2af7f14
Fix tests
danielailie Jan 29, 2025
4555bb0
Merge pull request #566 from multiversx/TOOL-448-remove-transaction-h…
danielailie Jan 29, 2025
5fc14af
Mark all legacy method as deprecated and update code to use the new a…
danielailie Jan 29, 2025
caa7bc3
Update code to use new methods and not the deprecated one
danielailie Jan 29, 2025
21f3f0b
Remove interfaces on network
danielailie Jan 29, 2025
5cc582f
Add core folder
danielailie Jan 29, 2025
3e3117c
Code review follow up
danielailie Jan 29, 2025
64d3b40
Add new line and update comments
danielailie Jan 29, 2025
66c042d
Merge pull request #567 from multiversx/TOOL-373-mark-as-deprecated-a…
danielailie Jan 29, 2025
bca5c05
Add back index.ts to root folder
danielailie Jan 29, 2025
aa4953e
Remove INetworkConfig
danielailie Jan 29, 2025
bd5ebb4
Add back INetworkConfig
danielailie Jan 29, 2025
649d358
Merge pull request #568 from multiversx/TOOL-450-remove-interface-on-…
danielailie Jan 29, 2025
bec53c8
Merge branch 'feat/next' into TOOL-449-add-core-folder
danielailie Jan 29, 2025
fb0e570
Update index files
danielailie Jan 29, 2025
7fc05d2
Move globals
danielailie Jan 29, 2025
a93a5be
Merge pull request #569 from multiversx/TOOL-449-add-core-folder
danielailie Jan 29, 2025
dddc3b3
Merge branch 'main' into MergeMainToFeatNext
danielailie Jan 30, 2025
ce865e8
Add relayer fields
danielailie Jan 30, 2025
5c60b1e
Merge pull request #570 from multiversx/MergeMainToFeatNext
danielailie Jan 30, 2025
94d246c
Update tests to use account.signTransaction
danielailie Jan 30, 2025
ff2520e
Fix tests
danielailie Jan 30, 2025
206d6ca
Fix integration tests
danielailie Jan 30, 2025
fe68e65
Fix integration tests
danielailie Feb 3, 2025
4fa62b5
Fix integration tests
danielailie Feb 3, 2025
16999cb
Fix unit test
danielailie Feb 3, 2025
f69cd4b
Fix smart contract result integration test
danielailie Feb 3, 2025
aa0dce0
Merge pull request #571 from multiversx/TOOL-451-use-account-sign-tra…
danielailie Feb 3, 2025
7a98194
Add verifyMessage and verifyTransaction on account
danielailie Feb 3, 2025
3b36dec
Merge branch 'feat/next' into TOOL-460-add-verify-message-and-verify-…
danielailie Feb 3, 2025
4f315d6
Update methods to follow specs
danielailie Feb 3, 2025
69438d1
Merge pull request #572 from multiversx/TOOL-460-add-verify-message-a…
danielailie Feb 4, 2025
5a7411a
Add relayer and guardian on controllers functions
danielailie Feb 24, 2025
cbf14be
Apply formatters
danielailie Feb 24, 2025
a9c5847
Increase timeout
danielailie Feb 24, 2025
077e990
Update controllers input parameters
danielailie Feb 25, 2025
b79a405
Clean up transaction watcher
danielailie Feb 25, 2025
7eb2cb9
Fix contract flow test
danielailie Feb 25, 2025
cfa32ee
Change wallet for contract deploy
danielailie Feb 25, 2025
3c1f03d
Fix tests
danielailie Feb 25, 2025
592928c
Fix accunt controller
danielailie Feb 25, 2025
7324c6d
Bump version
danielailie Feb 25, 2025
6f5de9b
Add relayer and guardian to controllers
danielailie Feb 25, 2025
cc5fb78
Remove relayed v1 and v2
danielailie Feb 26, 2025
e797199
Commit missing files
danielailie Feb 26, 2025
7926d6b
Merge pull request #577 from multiversx/TOOL-497-remove-relayed-v-1-a…
danielailie Feb 26, 2025
81d4df2
Export missing files
danielailie Mar 3, 2025
6f06d7a
Update to use new methods and not deprecated ones
danielailie Mar 3, 2025
32d9ae9
Export Guardian
danielailie Mar 3, 2025
43c5164
Export error obj
danielailie Mar 3, 2025
7099806
code review follow up
danielailie Mar 3, 2025
b618210
Improve errors
danielailie Mar 3, 2025
a63907a
Merge pull request #578 from multiversx/TOOL-500-export-input-resources
danielailie Mar 4, 2025
8035c57
Token management fixes
danielailie Mar 5, 2025
d066900
Fix devnet tests
danielailie Mar 5, 2025
b5714cd
Update gas limit
danielailie Mar 5, 2025
1ec984a
Merge pull request #579 from multiversx/TOOL-499-small-fixes-for-toke…
danielailie Mar 5, 2025
a61b57a
Deprecate Smart contract and code as not needed anymore
danielailie Mar 5, 2025
1222058
Add alias to AbiRegistry
danielailie Mar 5, 2025
271ceca
Merge pull request #580 from multiversx/TOOL-501-mark-smart-contract-…
danielailie Mar 5, 2025
c9e5dcf
Merge branch 'feat/next' into TOOL-374-create-abi-registry-alias-to-b…
danielailie Mar 5, 2025
20981b8
Remove unused comment
danielailie Mar 5, 2025
6e9bc35
Create-abi-registry-alias-to-be-abi
danielailie Mar 5, 2025
da2ffe8
Add extra gas in case we have relayer and guardian
danielailie Mar 5, 2025
f6c74b6
Add extra gas in case we have relayer and guardian
danielailie Mar 6, 2025
01d6d16
Merge branch 'main' into Merge-main-in-next
danielailie Mar 6, 2025
0c1b351
Add missing test
danielailie Mar 6, 2025
799b930
Merge main in next
danielailie Mar 6, 2025
f430605
Add missing methods on token management factory and controller
danielailie Mar 6, 2025
c71472d
Fix naming
danielailie Mar 6, 2025
a0e9af4
Bump version
danielailie Mar 6, 2025
055ab0a
Revert input resource rename
danielailie Mar 6, 2025
a2bf580
Remove unset for nft creation role
danielailie Mar 6, 2025
d5b0321
Update to use signTransaction on controllers
danielailie Mar 6, 2025
585e493
Add missing methods on token management factory and controller
danielailie Mar 6, 2025
45f912d
Merge branch 'feat/next' into TOOL-506-update-to-use-sign-transaction
danielailie Mar 6, 2025
7cdbf11
Merge pull request #585 from multiversx/TOOL-506-update-to-use-sign-t…
danielailie Mar 6, 2025
98e0e02
Add gasPrice and gasLimit to controllers
danielailie Mar 12, 2025
0881204
Add gas options also on account controller
danielailie Mar 12, 2025
5e291a7
Add gasPrice and gasLimit to controllers
danielailie Mar 12, 2025
fc58806
Update codemetadata
danielailie Mar 13, 2025
dfe9e89
Add descriptions on account and address
danielailie Mar 13, 2025
2c7cb05
Remove unnecesary conversion
danielailie Mar 13, 2025
9aa2204
Code review follow up
danielailie Mar 13, 2025
524ad09
Add methods description and update code metadata
danielailie Mar 13, 2025
dcb127d
Add description and delete unnecesary code
danielailie Mar 13, 2025
8983e6a
Bumb version
danielailie Mar 13, 2025
b252b96
Code review follow up
danielailie Mar 13, 2025
10e0cb8
Merge branch 'feat/next' into TOOL-512-Cleanup-update-descriptions
danielailie Mar 13, 2025
d4b93c4
Merge pull request #588 from multiversx/TOOL-512-Cleanup-update-descr…
danielailie Mar 13, 2025
bd2de73
bump version
danielailie Mar 18, 2025
85a83a4
Bumo version
danielailie Mar 18, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ name: Build and Test

on:
pull_request:
branches: [ main, development, feat/*, release/* ]
workflow_dispatch:

jobs:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-localnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
mkdir -p ~/localnet && cd ~/localnet
mxpy localnet setup --configfile=${GITHUB_WORKSPACE}/localnet.toml
nohup mxpy localnet start --configfile=${GITHUB_WORKSPACE}/localnet.toml > localnet.log 2>&1 & echo $! > localnet.pid
sleep 120 # Allow time for the testnet to fully start
sleep 10 # Allow time for the testnet to fully start

# Step 6: Install Node.js and dependencies
- name: Set up Node.js environment
Expand Down
29 changes: 15 additions & 14 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@multiversx/sdk-core",
"version": "13.17.2",
"version": "14.0.0",
"description": "MultiversX SDK for JavaScript and TypeScript",
"author": "MultiversX",
"homepage": "https://multiversx.com",
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ARGUMENTS_SEPARATOR } from "../constants";
import { ARGUMENTS_SEPARATOR } from "../core/constants";
import { BinaryCodec } from "./codec";
import { Type, TypedValue, U32Type, U32Value } from "./typesystem";
import { OptionalType, OptionalValue } from "./typesystem/algebraic";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ErrInvalidArgument } from "../errors";
import { ErrInvalidArgument } from "../core/errors";
import { EndpointParameterDefinition, Type } from "./typesystem";

export class ArgumentErrorContext {
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions src/smartcontracts/code.ts → src/abi/code.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
const createHasher = require("blake2b");

Check warning on line 1 in src/abi/code.ts

View workflow job for this annotation

GitHub Actions / build (16.x)

Require statement not part of import statement
const CODE_HASH_LENGTH = 32;

/**
* * @deprecated Use the bytecode directly
* Bytecode of a Smart Contract, as an abstraction.
*/
export class Code {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Address } from "../../address";
import { Address } from "../../core/address";
import { AddressValue } from "../typesystem";

export class AddressBinaryCodec {
Expand Down Expand Up @@ -29,13 +29,13 @@ export class AddressBinaryCodec {
* Encodes an AddressValue to a buffer.
*/
encodeNested(primitive: AddressValue): Buffer {
return primitive.valueOf().pubkey();
return primitive.valueOf().getPublicKey();
}

/**
* Encodes an AddressValue to a buffer.
*/
encodeTopLevel(primitive: AddressValue): Buffer {
return primitive.valueOf().pubkey();
return primitive.valueOf().getPublicKey();
}
}
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import BigNumber from "bignumber.js";
import { assert } from "chai";
import { Address } from "../../address";
import * as errors from "../../errors";
import { Address } from "../../core/address";
import * as errors from "../../core/errors";
import {
AddressType,
AddressValue,
Expand All @@ -13,10 +13,16 @@ import {
BigUIntValue,
BooleanType,
BooleanValue,
BytesType,
BytesValue,
EnumType,
EnumValue,
EnumVariantDefinition,
ExplicitEnumType,
ExplicitEnumValue,
ExplicitEnumVariantDefinition,
Field,
FieldDefinition,
I16Type,
I16Value,
I32Type,
Expand Down Expand Up @@ -45,9 +51,6 @@ import {
U8Type,
U8Value,
} from "../typesystem";
import { BytesType, BytesValue } from "../typesystem/bytes";
import { ExplicitEnumType, ExplicitEnumValue, ExplicitEnumVariantDefinition } from "../typesystem/explicit-enum";
import { FieldDefinition } from "../typesystem/fields";
import { BinaryCodec, BinaryCodecConstraints } from "./binary";
import { isMsbOne } from "./utils";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as errors from "../../errors";
import { guardTrue } from "../../utils";
import * as errors from "../../core/errors";
import { guardTrue } from "../../core/utils";
import {
ArrayVec,
ArrayVecType,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as errors from "../../errors";
import * as errors from "../../core/errors";
import { BooleanValue } from "../typesystem";

/**
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
import { CodeMetadata, CodeMetadataLength } from "../codeMetadata";
import { CodeMetadata, CodeMetadataLength } from "../../core/codeMetadata";
import { CodeMetadataValue } from "../typesystem/codeMetadata";

export class CodeMetadataCodec {
decodeNested(buffer: Buffer): [CodeMetadataValue, number] {
const codeMetadata = CodeMetadata.fromBuffer(buffer.slice(0, CodeMetadataLength));
const codeMetadata = CodeMetadata.newFromBytes(buffer.slice(0, CodeMetadataLength));
return [new CodeMetadataValue(codeMetadata), CodeMetadataLength];
}

decodeTopLevel(buffer: Buffer): CodeMetadataValue {
const codeMetadata = CodeMetadata.fromBuffer(buffer);
const codeMetadata = CodeMetadata.newFromBytes(buffer);
return new CodeMetadataValue(codeMetadata);
}

encodeNested(codeMetadata: CodeMetadataValue): Buffer {
return codeMetadata.valueOf().toBuffer();
return Buffer.from(codeMetadata.valueOf().toBytes());
}

encodeTopLevel(codeMetadata: CodeMetadataValue): Buffer {
return codeMetadata.valueOf().toBuffer();
return Buffer.from(codeMetadata.valueOf().toBytes());
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as errors from "../../errors";
import * as errors from "../../core/errors";
import { OptionValue, Type } from "../typesystem";
import { BinaryCodec } from "./binary";

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import BigNumber from "bignumber.js";
import { numberToPaddedHex } from "../../utils.codec";
import { numberToPaddedHex } from "../../core/utils.codec";

/**
* Returns whether the most significant bit of a given byte (within a buffer) is 1.
Expand Down
2 changes: 1 addition & 1 deletion src/smartcontracts/function.ts → src/abi/function.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as errors from "../errors";
import * as errors from "../core/errors";

/**
* A function of a Smart Contract, as an abstraction.
Expand Down
5 changes: 1 addition & 4 deletions src/smartcontracts/index.ts → src/abi/index.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
export * from "./argSerializer";
export * from "./argumentErrorContext";
export * from "./code";
export * from "./codec";
export * from "./codeMetadata";
export * from "./function";
export * from "./interaction";
export * from "./interactionChecker";
export * from "./interface";
export * from "./nativeSerializer";
export * from "./query";
export * from "./resultsParser";
export * from "./returnCode";
export * from "./smartContract";
export * from "./transactionPayloadBuilders";
export * from "./typesystem";
Loading
Loading