From 1550eb18a61b6b863cd5b46c3326592f881ac06a Mon Sep 17 00:00:00 2001 From: Jaco Date: Mon, 20 Dec 2021 07:14:44 +0100 Subject: [PATCH] tsconfig path linting (#4358) * tsconfig path linting * yarn.lock * Update @polkadot/dev --- package.json | 2 +- packages/api-augment/package.json | 3 ++- packages/api-contract/package.json | 2 ++ packages/api-contract/tsconfig.json | 4 +++- packages/api-derive/package.json | 6 +++++- packages/api-derive/tsconfig.spec.json | 5 +++-- packages/api/src/detectPackage.ts | 4 +--- packages/rpc-augment/package.json | 3 ++- packages/rpc-provider/package.json | 8 +++----- packages/rpc-provider/tsconfig.json | 3 ++- packages/typegen/package.json | 1 + packages/typegen/tsconfig.json | 2 ++ yarn.lock | 19 ++++++++++++++----- 13 files changed, 41 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index 162261e816..db3861979b 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,7 @@ "@babel/core": "^7.16.5", "@babel/register": "^7.16.5", "@babel/runtime": "^7.16.5", - "@polkadot/dev": "^0.64.6", + "@polkadot/dev": "^0.64.7", "@polkadot/ts": "^0.4.20", "@polkadot/typegen": "workspace:packages/typegen", "@types/jest": "^27.0.3", diff --git a/packages/api-augment/package.json b/packages/api-augment/package.json index ebcba405e0..aac85c6e12 100644 --- a/packages/api-augment/package.json +++ b/packages/api-augment/package.json @@ -28,6 +28,7 @@ "@polkadot/rpc-augment": "6.12.2-22", "@polkadot/types": "6.12.2-22", "@polkadot/types-augment": "6.12.2-22", - "@polkadot/types-codec": "6.12.2-22" + "@polkadot/types-codec": "6.12.2-22", + "@polkadot/util": "^8.2.2" } } diff --git a/packages/api-contract/package.json b/packages/api-contract/package.json index 7442f1bd33..a1743fd55a 100644 --- a/packages/api-contract/package.json +++ b/packages/api-contract/package.json @@ -26,7 +26,9 @@ "@babel/runtime": "^7.16.5", "@polkadot/api": "6.12.2-22", "@polkadot/types": "6.12.2-22", + "@polkadot/types-create": "6.12.2-22", "@polkadot/util": "^8.2.2", + "@polkadot/util-crypto": "^8.2.2", "rxjs": "^7.4.0" } } diff --git a/packages/api-contract/tsconfig.json b/packages/api-contract/tsconfig.json index d45a3a0864..9e00b3f0c0 100644 --- a/packages/api-contract/tsconfig.json +++ b/packages/api-contract/tsconfig.json @@ -15,6 +15,8 @@ ], "references": [ { "path": "../api" }, - { "path": "../types" } + { "path": "../types" }, + { "path": "../types-create" }, + { "path": "../types-support" } ] } diff --git a/packages/api-derive/package.json b/packages/api-derive/package.json index 44819ae498..e92d1ab1d7 100644 --- a/packages/api-derive/package.json +++ b/packages/api-derive/package.json @@ -24,10 +24,14 @@ "main": "index.js", "dependencies": { "@babel/runtime": "^7.16.5", + "@polkadot/api": "6.12.2-22", "@polkadot/api-base": "6.12.2-22", "@polkadot/rpc-core": "6.12.2-22", "@polkadot/types": "6.12.2-22", - "@polkadot/types-codec": "6.12.2-22" + "@polkadot/types-codec": "6.12.2-22", + "@polkadot/util": "^8.2.2", + "@polkadot/util-crypto": "^8.2.2", + "rxjs": "^7.4.0" }, "devDependencies": { "@polkadot/api": "6.12.2-22", diff --git a/packages/api-derive/tsconfig.spec.json b/packages/api-derive/tsconfig.spec.json index 5731caa933..0675acdfce 100644 --- a/packages/api-derive/tsconfig.spec.json +++ b/packages/api-derive/tsconfig.spec.json @@ -8,7 +8,7 @@ "noEmit": true }, "include": [ - "**/test/*", + "**/test/*.ts", "**/checkTypes.manual.ts", "**/*.spec.ts" ], @@ -20,6 +20,7 @@ { "path": "../rpc-augment" }, { "path": "../types" }, { "path": "../types-augment" }, - { "path": "../types-codec" } + { "path": "../types-codec" }, + { "path": "../types-support" }, ] } diff --git a/packages/api/src/detectPackage.ts b/packages/api/src/detectPackage.ts index 3b8fa1bfb9..089990e1c6 100644 --- a/packages/api/src/detectPackage.ts +++ b/packages/api/src/detectPackage.ts @@ -5,11 +5,9 @@ import { packageInfo as deriveInfo } from '@polkadot/api-derive/packageInfo'; import { packageInfo as coreInfo } from '@polkadot/rpc-core/packageInfo'; import { packageInfo as providerInfo } from '@polkadot/rpc-provider/packageInfo'; import { packageInfo as typesInfo } from '@polkadot/types/packageInfo'; -import { packageInfo as codecInfo } from '@polkadot/types-codec/packageInfo'; -import { packageInfo as createInfo } from '@polkadot/types-create/packageInfo'; import { packageInfo as knownInfo } from '@polkadot/types-known/packageInfo'; import { detectPackage } from '@polkadot/util'; import { packageInfo } from './packageInfo'; -detectPackage(packageInfo, typeof __dirname !== 'undefined' && __dirname, [deriveInfo, coreInfo, providerInfo, typesInfo, codecInfo, createInfo, knownInfo]); +detectPackage(packageInfo, typeof __dirname !== 'undefined' && __dirname, [deriveInfo, coreInfo, providerInfo, typesInfo, knownInfo]); diff --git a/packages/rpc-augment/package.json b/packages/rpc-augment/package.json index 356a5bc3e7..ea0b9be6d8 100644 --- a/packages/rpc-augment/package.json +++ b/packages/rpc-augment/package.json @@ -25,6 +25,7 @@ "dependencies": { "@babel/runtime": "^7.16.5", "@polkadot/rpc-core": "6.12.2-22", - "@polkadot/types": "6.12.2-22" + "@polkadot/types": "6.12.2-22", + "@polkadot/util": "^8.2.2" } } diff --git a/packages/rpc-provider/package.json b/packages/rpc-provider/package.json index 5ed65becb8..6ab3419058 100644 --- a/packages/rpc-provider/package.json +++ b/packages/rpc-provider/package.json @@ -24,17 +24,15 @@ "main": "index.js", "dependencies": { "@babel/runtime": "^7.16.5", + "@polkadot/keyring": "^8.2.2", "@polkadot/types": "6.12.2-22", + "@polkadot/types-support": "6.12.2-22", "@polkadot/util": "^8.2.2", "@polkadot/util-crypto": "^8.2.2", "@polkadot/x-fetch": "^8.2.2", "@polkadot/x-global": "^8.2.2", "@polkadot/x-ws": "^8.2.2", - "eventemitter3": "^4.0.7" - }, - "devDependencies": { - "@polkadot/keyring": "^8.2.2", - "@polkadot/types": "6.12.2-22", + "eventemitter3": "^4.0.7", "mock-socket": "^9.0.8", "nock": "^13.2.1" } diff --git a/packages/rpc-provider/tsconfig.json b/packages/rpc-provider/tsconfig.json index 810996ebe4..c7e1c4487f 100644 --- a/packages/rpc-provider/tsconfig.json +++ b/packages/rpc-provider/tsconfig.json @@ -10,6 +10,7 @@ "**/*.spec.ts" ], "references": [ - { "path": "../types" } + { "path": "../types" }, + { "path": "../types-support" } ] } diff --git a/packages/typegen/package.json b/packages/typegen/package.json index 81ef34b390..7a8bbc604f 100644 --- a/packages/typegen/package.json +++ b/packages/typegen/package.json @@ -42,6 +42,7 @@ "@polkadot/types-create": "6.12.2-22", "@polkadot/types-support": "6.12.2-22", "@polkadot/util": "^8.2.2", + "@polkadot/x-ws": "^8.2.2", "handlebars": "^4.7.7", "websocket": "^1.0.34", "yargs": "^17.3.0" diff --git a/packages/typegen/tsconfig.json b/packages/typegen/tsconfig.json index c573bc1231..5fa7b5bcf7 100644 --- a/packages/typegen/tsconfig.json +++ b/packages/typegen/tsconfig.json @@ -10,8 +10,10 @@ { "path": "../api-augment" }, { "path": "../rpc-augment" }, { "path": "../rpc-provider" }, + { "path": "../types" }, { "path": "../types-augment" }, { "path": "../types-codec" }, + { "path": "../types-create" }, { "path": "../types-support" } ] } diff --git a/yarn.lock b/yarn.lock index 9c72fa41d5..6ef916f6fc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1877,6 +1877,7 @@ __metadata: "@polkadot/types": 6.12.2-22 "@polkadot/types-augment": 6.12.2-22 "@polkadot/types-codec": 6.12.2-22 + "@polkadot/util": ^8.2.2 languageName: unknown linkType: soft @@ -1899,7 +1900,9 @@ __metadata: "@babel/runtime": ^7.16.5 "@polkadot/api": 6.12.2-22 "@polkadot/types": 6.12.2-22 + "@polkadot/types-create": 6.12.2-22 "@polkadot/util": ^8.2.2 + "@polkadot/util-crypto": ^8.2.2 rxjs: ^7.4.0 languageName: unknown linkType: soft @@ -1916,6 +1919,9 @@ __metadata: "@polkadot/rpc-core": 6.12.2-22 "@polkadot/types": 6.12.2-22 "@polkadot/types-codec": 6.12.2-22 + "@polkadot/util": ^8.2.2 + "@polkadot/util-crypto": ^8.2.2 + rxjs: ^7.4.0 languageName: unknown linkType: soft @@ -1941,9 +1947,9 @@ __metadata: languageName: unknown linkType: soft -"@polkadot/dev@npm:^0.64.6": - version: 0.64.6 - resolution: "@polkadot/dev@npm:0.64.6" +"@polkadot/dev@npm:^0.64.7": + version: 0.64.7 + resolution: "@polkadot/dev@npm:0.64.7" dependencies: "@babel/cli": ^7.16.0 "@babel/core": ^7.16.5 @@ -2028,7 +2034,7 @@ __metadata: polkadot-exec-rollup: scripts/polkadot-exec-rollup.mjs polkadot-exec-tsc: scripts/polkadot-exec-tsc.mjs polkadot-exec-webpack: scripts/polkadot-exec-webpack.mjs - checksum: 9a4f05074fc99ddeb7843f8a14c1b14a8041e23d35590664032e4c3972f6ca6bc1352893698d8be7efacaf06fef09d3fce6b7f8f12612c89c0fdf6ced8f45908 + checksum: d863aa9cbe4386c2cb9a9535051154ce378eb705f19f1a364e7c78012cb7796dee3ea4057265cebb60c68e238e95aacdf8fb51bab307b0964f8727ebf3e5ed1d languageName: node linkType: hard @@ -2062,6 +2068,7 @@ __metadata: "@babel/runtime": ^7.16.5 "@polkadot/rpc-core": 6.12.2-22 "@polkadot/types": 6.12.2-22 + "@polkadot/util": ^8.2.2 languageName: unknown linkType: soft @@ -2086,6 +2093,7 @@ __metadata: "@babel/runtime": ^7.16.5 "@polkadot/keyring": ^8.2.2 "@polkadot/types": 6.12.2-22 + "@polkadot/types-support": 6.12.2-22 "@polkadot/util": ^8.2.2 "@polkadot/util-crypto": ^8.2.2 "@polkadot/x-fetch": ^8.2.2 @@ -2122,6 +2130,7 @@ __metadata: "@polkadot/types-create": 6.12.2-22 "@polkadot/types-support": 6.12.2-22 "@polkadot/util": ^8.2.2 + "@polkadot/x-ws": ^8.2.2 "@types/websocket": ^1.0.4 "@types/yargs": ^17.0.7 handlebars: ^4.7.7 @@ -8968,7 +8977,7 @@ resolve@^2.0.0-next.3: "@babel/core": ^7.16.5 "@babel/register": ^7.16.5 "@babel/runtime": ^7.16.5 - "@polkadot/dev": ^0.64.6 + "@polkadot/dev": ^0.64.7 "@polkadot/ts": ^0.4.20 "@polkadot/typegen": "workspace:packages/typegen" "@types/jest": ^27.0.3