Skip to content

Commit 24fa2dd

Browse files
committed
fix: trezor wallet connection
2 parents 5c19ade + 67a0c2f commit 24fa2dd

File tree

36 files changed

+1625
-1841
lines changed

36 files changed

+1625
-1841
lines changed

.github/workflows/stable.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77

88
jobs:
99
publish:
10-
if: true
10+
if: false # temporary disabled
1111
runs-on: ubuntu-latest
1212

1313
permissions: write-all

package.json

Lines changed: 31 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -67,48 +67,49 @@
6767
"devDependencies": {
6868
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",
6969
"@babel/plugin-proposal-optional-chaining": "^7.20.7",
70-
"@babel/preset-env": "^7.26.9",
71-
"@commitlint/cli": "^19.7.1",
72-
"@commitlint/config-conventional": "^19.7.1",
70+
"@babel/plugin-transform-modules-commonjs": "^7.21.2",
71+
"@babel/preset-env": "^7.19.0",
72+
"@commitlint/cli": "^13.1.0",
73+
"@commitlint/config-conventional": "^13.1.0",
7374
"@types/jest": "^29.5.14",
74-
"@types/node": "^22.13.9",
75-
"@typescript-eslint/eslint-plugin": "^8.26.0",
76-
"@typescript-eslint/parser": "^8.26.0",
77-
"babel-jest": "^29.7.0",
78-
"commitizen": "^4.3.1",
75+
"@types/node": "^22.10.1",
76+
"@typescript-eslint/eslint-plugin": "^6.0.0",
77+
"@typescript-eslint/parser": "^6.0.0",
78+
"babel-jest": "^29.4.3",
79+
"commitizen": "^4.2.4",
7980
"cross-env": "^7.0.3",
8081
"cz-conventional-changelog": "^3.3.0",
81-
"dotenv": "^16.4.7",
82-
"eslint": "^9.21.0",
83-
"eslint-config-airbnb": "^19.0.4",
84-
"eslint-config-airbnb-base": "^15.0.0",
85-
"eslint-config-prettier": "^10.0.2",
86-
"eslint-import-resolver-typescript": "^3.8.3",
87-
"eslint-plugin-import": "^2.31.0",
88-
"eslint-plugin-jest": "^28.11.0",
89-
"eslint-plugin-markdown": "^5.1.0",
90-
"eslint-plugin-prettier": "^5.2.3",
91-
"husky": "^9.1.7",
82+
"dotenv": "^16.0.3",
83+
"eslint": "^7.32.0",
84+
"eslint-config-airbnb": "^18.2.1",
85+
"eslint-config-airbnb-base": "^14.2.1",
86+
"eslint-config-prettier": "^8.3.0",
87+
"eslint-import-resolver-typescript": "^2.5.0",
88+
"eslint-plugin-import": "^2.24.2",
89+
"eslint-plugin-jest": "^27.2.1",
90+
"eslint-plugin-markdown": "^2.2.1",
91+
"eslint-plugin-prettier": "^4.0.0",
92+
"husky": "^7.0.2",
9293
"jest": "^29.7.0",
93-
"jest-junit": "^16.0.0",
94+
"jest-junit": "^15.0.0",
9495
"jest-resolve": "^29.7.0",
95-
"lerna": "8.2.1",
96-
"lint-staged": "^15.4.3",
97-
"live-server": "^1.2.2",
98-
"markdownlint-cli": "^0.44.0",
96+
"lerna": "8.1.9",
97+
"lint-staged": "^11.1.2",
98+
"live-server": "^1.2.1",
99+
"markdownlint-cli": "^0.28.1",
99100
"patch-package": "^8.0.0",
100-
"prettier": "^3.5.3",
101-
"serve": "^14.2.4",
101+
"prettier": "^2.4.1",
102+
"serve": "^12.0.1",
102103
"shx": "^0.3.4",
103-
"ts-jest": "^29.2.6",
104+
"ts-jest": "^29.2.5",
104105
"ts-node": "^10.9.2",
105106
"ts-node-dev": "2.0.0",
106-
"tsc-alias": "^1.8.11",
107+
"tsc-alias": "^1.7.0",
107108
"tsc-esm-fix": "^3.1.2",
108109
"tsconfig-paths": "^4.2.0",
109-
"typedoc": "^0.27.9",
110+
"typedoc": "^0.25.11",
110111
"typedoc-monorepo-link-types": "^0.0.4",
111-
"typescript": "^5.8.2"
112+
"typescript": "^5.7.2"
112113
},
113114
"resolutions": {
114115
"@solana/web3.js": "1.98.0",

packages/exceptions/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@injectivelabs/exceptions",
33
"description": "List of exceptions that can be reused throughout Injective's projects.",
4-
"version": "1.14.43-beta.1",
4+
"version": "1.14.43-beta.2",
55
"sideEffects": false,
66
"license": "Apache-2.0",
77
"type": "module",

packages/exceptions/src/exceptions/messages.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ const cosmosErrorMap = {
8080
[ChainCosmosErrorCode.ErrMempoolIsFull]: 'The mempool is full',
8181
[ChainCosmosErrorCode.ErrTxTooLarge]: 'The transaction is too large',
8282
[ChainCosmosErrorCode.ErrKeyNotFound]:
83-
'Account does not exist on chain. To create an account, send some tokens to it',
83+
'Address is not yet active on the chain as it has a $0 balance. To activate it, please send a small amount of funds. Once funded, the network will recognize the address, allowing you to proceed.',
8484
[ChainCosmosErrorCode.ErrWrongPassword]: 'invalid account password',
8585
[ChainCosmosErrorCode.ErrorInvalidSigner]:
8686
'tx intended signer does not match the given signer',
@@ -764,7 +764,7 @@ export const chainErrorMessagesMap: Record<
764764

765765
'key not found': {
766766
message:
767-
'Account does not exist on chain. To create an account, send some tokens to it',
767+
'Address is not yet active on the chain as it has a $0 balance. To activate it, please send a small amount of funds. Once funded, the network will recognize the address, allowing you to proceed.',
768768
code: ChainCosmosErrorCode.ErrKeyNotFound,
769769
module: TransactionChainErrorModule.CosmosSdk,
770770
},
@@ -2051,7 +2051,8 @@ export const chainErrorMessagesMap: Record<
20512051
},
20522052

20532053
'failed to fetch account num/seq': {
2054-
message: 'Account does not exist on chain. Create it by send funds.',
2054+
message:
2055+
'Address is not yet active on the chain as it has a $0 balance. To activate it, please send a small amount of funds. Once funded, the network will recognize the address, allowing you to proceed.',
20552056
code: ChainCosmosErrorCode.ErrKeyNotFound,
20562057
module: TransactionChainErrorModule.CosmosSdk,
20572058
},

packages/sdk-ts/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@injectivelabs/sdk-ts",
33
"description": "SDK in TypeScript for building Injective applications in a browser, node, and react native environment.",
4-
"version": "1.14.44-beta.2",
4+
"version": "1.14.44-beta.3",
55
"sideEffects": false,
66
"license": "Apache-2.0",
77
"author": {
@@ -124,7 +124,7 @@
124124
"@ethersproject/bytes": "^5.8.0",
125125
"@injectivelabs/abacus-proto-ts": "1.14.0",
126126
"@injectivelabs/core-proto-ts": "1.14.2",
127-
"@injectivelabs/exceptions": "^1.14.43-beta.1",
127+
"@injectivelabs/exceptions": "^1.14.43-beta.2",
128128
"@injectivelabs/grpc-web": "^0.0.1",
129129
"@injectivelabs/grpc-web-node-http-transport": "^0.0.2",
130130
"@injectivelabs/grpc-web-react-native-transport": "^0.0.2",
@@ -133,7 +133,7 @@
133133
"@injectivelabs/networks": "^1.14.43-beta.1",
134134
"@injectivelabs/olp-proto-ts": "1.13.4",
135135
"@injectivelabs/ts-types": "^1.14.43-beta.0",
136-
"@injectivelabs/utils": "^1.14.43-beta.2",
136+
"@injectivelabs/utils": "^1.14.43-beta.3",
137137
"@metamask/eth-sig-util": "^4.0.0",
138138
"@noble/curves": "^1.8.1",
139139
"@noble/hashes": "^1.7.1",

packages/sdk-ts/src/client/indexer/grpc/IndexerGrpcReferralApi.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ export class IndexerGrpcReferralApi extends BaseGrpcConsumer {
8484
}
8585
}
8686

87-
async fetchReferrerByCode(address: string) {
87+
async fetchReferrerByCode(code: string) {
8888
const request = InjectiveReferralRpc.GetReferrerByCodeRequest.create()
89-
request.referralCode = address
89+
request.referralCode = code
9090

9191
try {
9292
const response =

packages/sdk-ts/src/client/indexer/transformers/IndexerGrpcReferralTransformer.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export class IndexerGrpcReferralTransformer {
2424

2525
static referrerByCodeResponseToReferrerByCode(
2626
response: InjectiveReferralRpc.GetReferrerByCodeResponse,
27-
): boolean {
28-
return !response?.referrerAddress
27+
): string {
28+
return response?.referrerAddress || ''
2929
}
3030
}

packages/sdk-ts/src/core/modules/wasm/msgs/MsgStoreCode.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ describe('MsgStoreCode', () => {
2828
)
2929
})
3030

31-
// TODO - Onchain issue, fix that first
32-
it.skip('EIP712 v2', async () => {
31+
it('EIP712 v2', async () => {
3332
const eip712TypedData = getEip712TypedDataV2(eip712Args)
3433

3534
const txResponse = await new IndexerGrpcWeb3GwApi(

packages/sdk-ts/src/core/modules/wasm/msgs/MsgStoreCode.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,6 @@ export default class MsgStoreCode extends MsgBase<
8080
const amino = this.toAmino()
8181
const { value } = amino
8282

83-
8483
return {
8584
'@type': '/cosmwasm.wasm.v1.MsgStoreCode',
8685
...value,
@@ -102,14 +101,16 @@ export default class MsgStoreCode extends MsgBase<
102101
...web3gw,
103102
instantiate_permission: web3gw.instantiate_permission
104103
? {
105-
...web3gw.instantiate_permission,
106-
permission: CosmwasmWasmV1Types.accessTypeFromJSON(
104+
addresses: web3gw.instantiate_permission.addresses || [],
105+
permission: CosmwasmWasmV1Types.accessTypeToJSON(
107106
web3gw.instantiate_permission.permission,
108107
),
109108
}
110109
: undefined,
111110
}
112111

112+
console.log(messageAdjusted)
113+
113114
return messageAdjusted
114115
}
115116

packages/utils/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@injectivelabs/utils",
33
"description": "List of utils and helper functions that can be reused throughout Injective's projects.",
4-
"version": "1.14.43-beta.2",
4+
"version": "1.14.43-beta.3",
55
"sideEffects": false,
66
"type": "module",
77
"author": {
@@ -77,7 +77,7 @@
7777
},
7878
"dependencies": {
7979
"@bangjelkoski/store2": "^2.14.3",
80-
"@injectivelabs/exceptions": "^1.14.43-beta.1",
80+
"@injectivelabs/exceptions": "^1.14.43-beta.2",
8181
"@injectivelabs/networks": "^1.14.43-beta.1",
8282
"@injectivelabs/ts-types": "^1.14.43-beta.0",
8383
"axios": "^1.8.1",

0 commit comments

Comments
 (0)