Skip to content

Commit

Permalink
feat: error management (#802)
Browse files Browse the repository at this point in the history
* Error types

* Update DIP provider runtime APIs types

* Update packages version
  • Loading branch information
ntn-x2 authored Oct 31, 2023
1 parent e4c83a5 commit 2ab27f4
Show file tree
Hide file tree
Showing 16 changed files with 41 additions and 15 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,6 @@
"typedoc": "^0.23.0",
"typescript": "^4.8.3"
},
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"packageManager": "[email protected]"
}
2 changes: 1 addition & 1 deletion packages/asset-did/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/asset-did",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/augment-api/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/augment-api",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"types": "./lib/index.d.ts",
"type": "module",
Expand Down
2 changes: 1 addition & 1 deletion packages/chain-helpers/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/chain-helpers",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/config",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"type": "commonjs",
"main": "./lib/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/core",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/did/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/did",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/messaging/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/messaging",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/sdk-js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/sdk-js",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/testing/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@kiltprotocol/testing",
"private": true,
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/type-definitions/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/type-definitions",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/type-definitions/src/runtime/dipProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const calls: DefinitionsCall = {
type: 'DipProofRequest',
},
],
type: 'Result<CompleteMerkleProof, ()>',
type: 'Result<CompleteMerkleProof, RuntimeApiDipProofError>',
},
},
version: 1,
Expand Down
26 changes: 26 additions & 0 deletions packages/type-definitions/src/types_11000.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,30 @@ export const types11000: RegistryTypes = {
Web3NameMerkleValue: 'BlockNumber',
LinkedAccountMerkleKey: 'PalletDidLookupLinkableAccountLinkableAccountId',
LinkedAccountMerkleValue: 'Null',
RuntimeApiDipProofError: {
_enum: {
IdentityNotFound: null,
IdentityProviderError: 'CombineError',
MerkleProofError: 'DidMerkleProofError',
},
},
CombineError: {
_enum: {
A: 'DidIdentityProviderError',
B: 'DidIdentityProviderError',
C: 'DidIdentityProviderError',
},
},
DidIdentityProviderError: {
_enum: ['DidNotFound', 'Internal'],
},
DidMerkleProofError: {
_enum: [
'DidNotFound',
'KeyNotFound',
'LinkedAccountNotFound',
'Web3NameNotFound',
'Internal',
],
},
}
2 changes: 1 addition & 1 deletion packages/types/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/types",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/utils",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/vc-export/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kiltprotocol/vc-export",
"version": "0.33.2-dip-0",
"version": "0.33.2-dip-1",
"description": "",
"main": "./lib/cjs/index.js",
"module": "./lib/esm/index.js",
Expand Down

0 comments on commit 2ab27f4

Please sign in to comment.