@polymeshassociation/polymesh-sdk 15.0.0-beta.5 โ 15.0.0
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/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,140 @@
|
|
|
1
|
-
# [15.0.0
|
|
1
|
+
# [15.0.0](https://github.com/PolymathNetwork/polymesh-sdk/compare/v14.1.2...v15.0.0) (2022-08-10)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* ๐ Add missing validations in `controllerTransfer` proc ([efb07c8](https://github.com/PolymathNetwork/polymesh-sdk/commit/efb07c8b650cb416ce69b46433510cdf3cee3797))
|
|
7
|
+
* ๐ Correct the `amount`, `withheldTax` returned by `DividendDistribution.getPaymentHistory` ([f6ab2c5](https://github.com/PolymathNetwork/polymesh-sdk/commit/f6ab2c57bbc0e46664990e5bd1450f0c48c5b767))
|
|
8
|
+
* ๐ disregard pallets without calls ([af684ae](https://github.com/PolymathNetwork/polymesh-sdk/commit/af684ae30c58687c38924fc5e00bfa0115e504fb))
|
|
9
|
+
* ๐ Fix asset.settlement.canTransfer method ([6f32e4d](https://github.com/PolymathNetwork/polymesh-sdk/commit/6f32e4d72b19795a8bf73f9c5943f4bcb5e7a6d6))
|
|
10
|
+
* ๐ Handle NoData claimType in conversion util ([1f9bbfa](https://github.com/PolymathNetwork/polymesh-sdk/commit/1f9bbfa3bbc049092c8913bc05a71e2bbaa3dc9a))
|
|
11
|
+
* ๐ ignore portfolio locked balances with zero amount ([be57838](https://github.com/PolymathNetwork/polymesh-sdk/commit/be57838b616b4035a6e8de757cd38ff2768bfe6f))
|
|
12
|
+
* ๐ Pin polkadot dependencies ([d79f561](https://github.com/PolymathNetwork/polymesh-sdk/commit/d79f561124846c3681d2bf01ec5639b4c738600a))
|
|
13
|
+
* ๐ Remove polymeshApi Proxy in Context ([fdd14a8](https://github.com/PolymathNetwork/polymesh-sdk/commit/fdd14a86945c6cde66c6cb7a81ac46766366c055))
|
|
14
|
+
* ๐ Settlement not being modifable before end block ([#762](https://github.com/PolymathNetwork/polymesh-sdk/issues/762)) ([517a2a7](https://github.com/PolymathNetwork/polymesh-sdk/commit/517a2a712c9e0da8d365e74efe7585806653e7b3))
|
|
15
|
+
* ๐ Undo postProcess augment-rpc ([c758e08](https://github.com/PolymathNetwork/polymesh-sdk/commit/c758e08191db2d9c66c47536df544127ac06d011))
|
|
16
|
+
* ๐ Update polkadot api to fix pagination issue ([6c032e6](https://github.com/PolymathNetwork/polymesh-sdk/commit/6c032e667d969f11c59ef33128a206e100e05c1a))
|
|
17
|
+
* ๐ use proper type for document URIs ([615782a](https://github.com/PolymathNetwork/polymesh-sdk/commit/615782a471e9cafcb832af42231b80c16d8279a3))
|
|
18
|
+
* ๐ Validate primary key on `modifySignerPermissions` ([0676035](https://github.com/PolymathNetwork/polymesh-sdk/commit/06760350625d2fccdd67e5fedc4d521d58b247d3))
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Code Refactoring
|
|
22
|
+
|
|
23
|
+
* ๐ก GetReturnType to GetTransferRestrictionReturnType ([cff18a5](https://github.com/PolymathNetwork/polymesh-sdk/commit/cff18a5d6b4b2aa3a7271eb560b002370089f4ae))
|
|
24
|
+
* ๐ก Rename `toJson` to `toHuman` in all entities ([cb684fb](https://github.com/PolymathNetwork/polymesh-sdk/commit/cb684fb7e868e5ae351a93ce0fec8860e5a33352))
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
* Da 179/upgrade 5.0.0 (#742) ([2450467](https://github.com/PolymathNetwork/polymesh-sdk/commit/245046707f68ffae4a3c97aad0c2fb74babc6a7d)), closes [#742](https://github.com/PolymathNetwork/polymesh-sdk/issues/742)
|
|
2
28
|
|
|
3
29
|
|
|
4
30
|
### Features
|
|
5
31
|
|
|
32
|
+
* ๐ธ (WIP) Add support for 5.0.0 rc-1 ([7a4e503](https://github.com/PolymathNetwork/polymesh-sdk/commit/7a4e50346ea855cdf462c0585ab5c7b6f15deea2))
|
|
33
|
+
* ๐ธ (WIP) Add support for 5.0.0 rc-1 ([a7d7a8b](https://github.com/PolymathNetwork/polymesh-sdk/commit/a7d7a8b97339d339d4a33d8b17b602142bd828c4))
|
|
6
34
|
* ๐ธ Add enableStat to transferRestriction namespace ([#782](https://github.com/PolymathNetwork/polymesh-sdk/issues/782)) ([c862841](https://github.com/PolymathNetwork/polymesh-sdk/commit/c862841b0bec896e3a040085890d7a5cbd365c19))
|
|
35
|
+
* ๐ธ add getSecondaryPermissions method ([86e86fd](https://github.com/PolymathNetwork/polymesh-sdk/commit/86e86fddb0a3c5b73b6c08d26e43b927dbe612cf))
|
|
36
|
+
* ๐ธ Add guard to Asset.investorCount if stat is not enabled ([3cfcc58](https://github.com/PolymathNetwork/polymesh-sdk/commit/3cfcc58085c3856093e44138accec0c070b76677))
|
|
37
|
+
* ๐ธ Add method to get all assets on chain (with pagination) ([77f1579](https://github.com/PolymathNetwork/polymesh-sdk/commit/77f1579286f4f85e7f4e8d973c7142e047d53926))
|
|
38
|
+
* ๐ธ add pagination for getSecondaryAccounts ([7d37e02](https://github.com/PolymathNetwork/polymesh-sdk/commit/7d37e026511af9481dd6131f0f45fc127327e38a))
|
|
39
|
+
* ๐ธ Add support for FIGI asset identifiers ([6fa8cf1](https://github.com/PolymathNetwork/polymesh-sdk/commit/6fa8cf139ac79ea26809a2fe6663764aff7581ca))
|
|
40
|
+
* ๐ธ Always return `TickerReservation` from `assets.getTickerReservation` ([4b59621](https://github.com/PolymathNetwork/polymesh-sdk/commit/4b59621ee74144d5fa9a9a5147e476710be3fee3))
|
|
41
|
+
* ๐ธ bump supported chain version to 5.0.2 ([a73ced2](https://github.com/PolymathNetwork/polymesh-sdk/commit/a73ced246ee34ef9d8180c9785bde5676c8572cc))
|
|
42
|
+
* ๐ธ Bump supported version range to 5.0.x ([44ec9f5](https://github.com/PolymathNetwork/polymesh-sdk/commit/44ec9f57429f7ab4c2eee52a66c2728181486dad))
|
|
43
|
+
* ๐ธ DA-311 Add support for middleware v2 with claims POC ([3b75f49](https://github.com/PolymathNetwork/polymesh-sdk/commit/3b75f49444d80645f0e1757f052f2786682b82fa))
|
|
44
|
+
* ๐ธ DA-315 Migrate middleware queries to subquery native ([389e84d](https://github.com/PolymathNetwork/polymesh-sdk/commit/389e84d8ff9f859a040aea47567603a45d9fbbb2))
|
|
45
|
+
* ๐ธ expose transaction index within block ([e6c6983](https://github.com/PolymathNetwork/polymesh-sdk/commit/e6c6983433487c3935b4b28f5204c44a95268fb5))
|
|
46
|
+
* ๐ธ log a warning for minor and patch version mismatch ([30dd691](https://github.com/PolymathNetwork/polymesh-sdk/commit/30dd69163aa75df81614f1feea8f45803f1a59d6))
|
|
47
|
+
* ๐ธ Migrate external agents queries to subquery native ([1f6a5c7](https://github.com/PolymathNetwork/polymesh-sdk/commit/1f6a5c72c3a271276242763ecee99b4d904c93c6))
|
|
48
|
+
* ๐ธ Migrate settlements query to subquery native ([e3ac5c2](https://github.com/PolymathNetwork/polymesh-sdk/commit/e3ac5c2ca7fe135195f47e3bac178c0ce1782bae))
|
|
49
|
+
* ๐ธ move getSecondaryAccountPermissions into internal tool ([d547463](https://github.com/PolymathNetwork/polymesh-sdk/commit/d5474634564142f99683af8b85dcc28d45173d0e))
|
|
50
|
+
* ๐ธ Multiple tags support while getting protocol fees ([e0f8897](https://github.com/PolymathNetwork/polymesh-sdk/commit/e0f889701737a7b3dceab5371c91074cf8c09a6f))
|
|
51
|
+
* ๐ธ Pin transtive polkadot dependencies ([463ce32](https://github.com/PolymathNetwork/polymesh-sdk/commit/463ce3254c59f5741bcbea10eb9657894a208f71))
|
|
52
|
+
* ๐ธ Proper calculation of investor count with PUIS enabled ([1924cdd](https://github.com/PolymathNetwork/polymesh-sdk/commit/1924cddeae75165583ef9948dac36afcacd9a35e))
|
|
53
|
+
* ๐ธ Publish to polymesh association npm ([#777](https://github.com/PolymathNetwork/polymesh-sdk/issues/777)) ([38ee807](https://github.com/PolymathNetwork/polymesh-sdk/commit/38ee8078e5ec6c3a825431c6338e2c3d1fd08974))
|
|
54
|
+
* ๐ธ Refactor code to use new trasnfer restrictions api ([37b146a](https://github.com/PolymathNetwork/polymesh-sdk/commit/37b146a2d2d4f37dc2070a24db652f782e5bf9a2))
|
|
55
|
+
* ๐ธ Return gasFees, protocolFees in `getTransactionByHash` ([032222c](https://github.com/PolymathNetwork/polymesh-sdk/commit/032222c6aeb28b8dd62f73de4eb34fecf4318a69))
|
|
56
|
+
* ๐ธ Round post-tax dividend amounts ([dfb9625](https://github.com/PolymathNetwork/polymesh-sdk/commit/dfb962504c874396362205d470cbf7fb2d91ce18))
|
|
57
|
+
* ๐ธ Support 5.0.0-rc-1 ([33b77e4](https://github.com/PolymathNetwork/polymesh-sdk/commit/33b77e4af822f2a9e03eded85042bd4643c2e142))
|
|
58
|
+
* ๐ธ Support callback for getSecondaryAccounts ([1a9c6fe](https://github.com/PolymathNetwork/polymesh-sdk/commit/1a9c6fed13472b3c95f4426c7d93258ee1dfd798))
|
|
59
|
+
* ๐ธ support passing existing group permissions ([ff3e8ae](https://github.com/PolymathNetwork/polymesh-sdk/commit/ff3e8aecdb9ce7f953d0474721cd3b99bf4eb7aa))
|
|
60
|
+
* ๐ธ support passing null (full) permissions on `inviteAgent ([8001b7b](https://github.com/PolymathNetwork/polymesh-sdk/commit/8001b7b6d7570eb9fe1cdc6a0c21decd82fbdb82))
|
|
61
|
+
* ๐ธ throw an error when fetching an asset identity ([8949e13](https://github.com/PolymathNetwork/polymesh-sdk/commit/8949e13ad2969b8db6659a01f10f8bd66dcb44cc))
|
|
62
|
+
* ๐ธ Update granular permissions results for new types ([fe2b072](https://github.com/PolymathNetwork/polymesh-sdk/commit/fe2b072545f8d89be7cb6edae1557be4939b586e))
|
|
63
|
+
* ๐ธ Upgrade polkadot SDK along with 5.0.0 chain types ([2e9ee2c](https://github.com/PolymathNetwork/polymesh-sdk/commit/2e9ee2ca40421ba95b97d92f37d013dc5e2de553))
|
|
64
|
+
* ๐ธ upgrade polkadot.js to 8.9.1 ([ba358ad](https://github.com/PolymathNetwork/polymesh-sdk/commit/ba358ada87ac3f7a1d04b2273d416e39bc895dfa))
|
|
65
|
+
* ๐ธ use `createGroupAndAddAuth` when appropriate ([ed0d022](https://github.com/PolymathNetwork/polymesh-sdk/commit/ed0d022e46e28336831336671dee5a433fc421dd))
|
|
66
|
+
* ๐ธ Use batching fully for add restriction ([5bd29d5](https://github.com/PolymathNetwork/polymesh-sdk/commit/5bd29d51161d4ee5b281fae4ddd124ee4976783d))
|
|
67
|
+
* ๐ธ use batching when modifying CA defaults ([296949b](https://github.com/PolymathNetwork/polymesh-sdk/commit/296949bd4187b9949d3f5fa01b0bbe34bfced0ca))
|
|
68
|
+
* ๐ธ use composite extrinsic to create and change group ([8c0a9f0](https://github.com/PolymathNetwork/polymesh-sdk/commit/8c0a9f02c291622a2ece31f2ba35689e57bbdf01))
|
|
69
|
+
* ๐ธ use composite extrinsic to create CA and distribution ([29fb0ad](https://github.com/PolymathNetwork/polymesh-sdk/commit/29fb0ad65d5a1f2ca4db28ee6951d4b5b4ca372a))
|
|
70
|
+
* ๐ธ Use names prefixed with PolymeshPrimitives and Pallet ([7874b57](https://github.com/PolymathNetwork/polymesh-sdk/commit/7874b57fde6b054e25e376e846e0e61b135b2bc0))
|
|
71
|
+
* ๐ธ Use proper batching for setTransferRestriction ([f895ec8](https://github.com/PolymathNetwork/polymesh-sdk/commit/f895ec85c68f41b0449a3117cf103122ee44f949))
|
|
72
|
+
* ๐ธ validate chain spec version when connecting ([af76f93](https://github.com/PolymathNetwork/polymesh-sdk/commit/af76f93796c577a9c8ef72b9a7fc55c0c99d65e8))
|
|
73
|
+
* ๐ธ WIP Update transfer restrictions to create stats ([32d7d94](https://github.com/PolymathNetwork/polymesh-sdk/commit/32d7d94e939c5d1f0194d62addd9ed01ceb15e45))
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
### BREAKING CHANGES
|
|
77
|
+
|
|
78
|
+
* ๐งจ getSecondaryAccounts is now paginated
|
|
79
|
+
* ๐งจ Type `GetReturnType<T>` is now renamed to
|
|
80
|
+
`GetTransferRestrictionReturnType<T>`
|
|
81
|
+
* ๐งจ no longer throw an error when adding an external agent with explicit
|
|
82
|
+
permissions if there is already an existing permission group with those
|
|
83
|
+
permissions
|
|
84
|
+
* ๐งจ `accountManagement.modifyPermissions` and `accountManagement.revokePermissions`
|
|
85
|
+
now throw an error if the signing Account is not the primary Account of the Identity
|
|
86
|
+
whose secondary Accounts' permissions are modified/revoked
|
|
87
|
+
* ๐งจ Asset.investorCount throws if stat is not enabled
|
|
88
|
+
|
|
89
|
+
* fix: ๐ Remove polymeshApi Proxy in Context
|
|
90
|
+
|
|
91
|
+
polkadot.js began using a private accesor (e.g. #registry) internally.
|
|
92
|
+
This causes an error to be thrown when called by a proxied instance.
|
|
93
|
+
Context Proxy was used to guard against having no signer which is taken
|
|
94
|
+
care of by the singning manager, so this shouldn't cause any behavior to
|
|
95
|
+
change
|
|
96
|
+
|
|
97
|
+
* feat: ๐ธ Bump supported version range to 5.0.x
|
|
98
|
+
|
|
99
|
+
* chore: ๐ค use stored metadata to generate country code enum
|
|
100
|
+
|
|
101
|
+
* chore: ๐ค remove country code generation from definitions script
|
|
102
|
+
|
|
103
|
+
* feat: ๐ธ expose transaction index within block
|
|
104
|
+
|
|
105
|
+
Also fix compilation errors that arise in sandbox
|
|
106
|
+
|
|
107
|
+
* fix: ๐ disregard pallets without calls
|
|
108
|
+
|
|
109
|
+
* fix: ๐ use proper type for document URIs
|
|
110
|
+
|
|
111
|
+
Also fixed documentHash conversion util tests
|
|
112
|
+
|
|
113
|
+
* feat: ๐ธ validate chain spec version when connecting
|
|
114
|
+
* ๐งจ throw an error instead of a warning when the chain versions aren't
|
|
115
|
+
within the expected ranges
|
|
116
|
+
|
|
117
|
+
* refactor: ๐ก Eliminate RPC specific conversion functions
|
|
118
|
+
|
|
119
|
+
Modify the schema object to make its types compatible with the rest of
|
|
120
|
+
the api. This elminates snake case conversion functions to DRY the code
|
|
121
|
+
base
|
|
122
|
+
|
|
123
|
+
Update types to use PolymeshPrimitivesIdentityId instead of IdentityId
|
|
124
|
+
|
|
125
|
+
* feat: ๐ธ log a warning for minor and patch version mismatch
|
|
126
|
+
|
|
127
|
+
Co-authored-by: Jeremias Diaz <monitz87@gmail.com>
|
|
128
|
+
Co-authored-by: Victor Vicente <VictorVicente@users.noreply.github.com>
|
|
129
|
+
* ๐งจ `network.getProtocolFees` now supports passing multiple `TxTags`.
|
|
130
|
+
Also, the return type has been changed from `Promise<BigNumber>`
|
|
131
|
+
to `Promise<ProtocolFees[]>` specifying protocol fees for each tag argument.
|
|
132
|
+
* ๐งจ throw an error instead of a warning when the chain versions aren't
|
|
133
|
+
within the expected ranges
|
|
134
|
+
* ๐งจ Asset.investorCount throws if stat is not enabled
|
|
135
|
+
* ๐งจ Return type of `network.getTransactionByHash` is changed from
|
|
136
|
+
`Promise<ExtrinsicData | null>` to `Promise<ExtrinsicDataWithFees | null>`
|
|
137
|
+
* ๐งจ `toJson` method within all entities has been renamed to `toHuman`
|
|
138
|
+
* ๐งจ `assets.isTickerAvailable` has been removed.
|
|
139
|
+
To check ticker availability, directly get the `TickerReservation` instance
|
|
140
|
+
and use `details.status` to check the availability
|
|
Binary file
|
package/package.json
CHANGED
package/utils/constants.d.ts
CHANGED
|
@@ -46,11 +46,11 @@ export declare const ROOT_TYPES: Record<string, TransactionArgumentType.Did | Tr
|
|
|
46
46
|
/**
|
|
47
47
|
* The Polymesh RPC node version range that is compatible with this version of the SDK
|
|
48
48
|
*/
|
|
49
|
-
export declare const SUPPORTED_NODE_VERSION_RANGE = "5.0.
|
|
49
|
+
export declare const SUPPORTED_NODE_VERSION_RANGE = "5.0.2";
|
|
50
50
|
/**
|
|
51
51
|
* The Polymesh chain spec version range that is compatible with this version of the SDK
|
|
52
52
|
*/
|
|
53
|
-
export declare const SUPPORTED_SPEC_VERSION_RANGE = "5.0.
|
|
53
|
+
export declare const SUPPORTED_SPEC_VERSION_RANGE = "5.0.2";
|
|
54
54
|
export declare const SYSTEM_VERSION_RPC_CALL: {
|
|
55
55
|
jsonrpc: string;
|
|
56
56
|
method: string;
|
package/utils/constants.js
CHANGED
|
@@ -92,11 +92,11 @@ exports.ROOT_TYPES = rootTypes;
|
|
|
92
92
|
/**
|
|
93
93
|
* The Polymesh RPC node version range that is compatible with this version of the SDK
|
|
94
94
|
*/
|
|
95
|
-
exports.SUPPORTED_NODE_VERSION_RANGE = '5.0.
|
|
95
|
+
exports.SUPPORTED_NODE_VERSION_RANGE = '5.0.2';
|
|
96
96
|
/**
|
|
97
97
|
* The Polymesh chain spec version range that is compatible with this version of the SDK
|
|
98
98
|
*/
|
|
99
|
-
exports.SUPPORTED_SPEC_VERSION_RANGE = '5.0.
|
|
99
|
+
exports.SUPPORTED_SPEC_VERSION_RANGE = '5.0.2';
|
|
100
100
|
exports.SYSTEM_VERSION_RPC_CALL = {
|
|
101
101
|
jsonrpc: '2.0',
|
|
102
102
|
method: 'system_version',
|
|
Binary file
|