Skip to content

Commit 08377cc

Browse files
06180.618
andauthored
chore: upgrade webpack-dev-server to v5 (#13663)
* chore: upgrade webpack-dev-server to v5 * chore: pin follow-redirects@^1.15.6 * Revert "chore: upgrade webpack-dev-server to v5" This reverts commit 35904ac. * fix: lint and threshold * fix: fix lint error --------- Co-authored-by: 0.618 <o.6180339@gmail.com>
1 parent 395f717 commit 08377cc

8 files changed

Lines changed: 11 additions & 18 deletions

File tree

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"link-dev": "mkdir -p .bin/ && cd packages/amplify-cli && ln -s \"$(pwd)/bin/amplify\" ../../.bin/amplify-dev && cd ../../",
2929
"link-win": "node ./scripts/link-bin.js packages/amplify-cli/bin/amplify amplify-dev",
3030
"lint-check-package-json": "yarn eslint --no-eslintrc --config .eslint.package.json.js '**/package.json'",
31-
"lint-check": "yarn eslint . --ext .js,.jsx,.ts,.tsx --max-warnings=755",
31+
"lint-check": "yarn eslint . --ext .js,.jsx,.ts,.tsx --max-warnings=750",
3232
"lint-fix-package-json": "yarn lint-check-package-json --fix",
3333
"lint-fix": "git diff --name-only --cached --diff-filter d | grep -E '\\.(js|jsx|ts|tsx)$' | xargs eslint --fix --quiet",
3434
"mergewords": "yarn ts-node ./scripts/handle-dict-conflicts.ts",
@@ -174,6 +174,7 @@
174174
"tough-cookie": "^4.1.3",
175175
"semver": "^7.5.4",
176176
"word-wrap": "^1.2.4",
177+
"follow-redirects": "^1.15.6",
177178
"amplify-codegen": "4.7.3",
178179
"@aws-amplify/appsync-modelgen-plugin": "2.8.1"
179180
}

packages/amplify-appsync-simulator/src/server/subscription/websocket-server/server.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import * as WebSocket from 'ws';
55
import { Server as WebSocketServer, ServerOptions } from 'ws';
66
import {
77
GQLMessageConnectionAck,
8-
GQLMessageConnectionInit,
98
GQLMessageSubscriptionStart,
109
GQLMessageSubscriptionStop,
1110
isSubscriptionConnectionInitMessage,

packages/amplify-category-notifications/src/channel-in-app-msg.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,7 @@ import {
2323
} from './plugin-client-api-analytics';
2424
import { IChannelAPIResponse, ChannelAction, ChannelConfigDeploymentType } from './channel-types';
2525

26-
import {
27-
buildPinpointChannelResponseSuccess,
28-
getPinpointAppStatusFromMeta,
29-
IPinpointAppStatus,
30-
IPinpointDeploymentStatus,
31-
} from './pinpoint-helper';
26+
import { buildPinpointChannelResponseSuccess, getPinpointAppStatusFromMeta, IPinpointDeploymentStatus } from './pinpoint-helper';
3227
import { ChannelType, getChannelViewName, isChannelEnabledNotificationsBackendConfig } from './notifications-backend-cfg-channel-api';
3328
import { getNotificationsAppMeta } from './notifications-amplify-meta-api';
3429
import { getNotificationsAppConfig } from './notifications-backend-cfg-api';

packages/amplify-go-function-runtime-provider/src/runtime.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,6 @@ export const buildResource = async ({ buildType, srcRoot, lastBuildTimeStamp }:
7373
const outDir = path.join(srcRoot, buildDir);
7474

7575
const isWindows = process.platform.startsWith('win');
76-
const executableName = isWindows && buildType === BuildType.DEV ? MAIN_BINARY_WIN : MAIN_BINARY;
77-
const executablePath = path.join(outDir, executableName);
7876

7977
if (!lastBuildTimeStamp || isBuildStale(srcRoot, lastBuildTimeStamp, outDir)) {
8078
const srcDir = path.join(srcRoot, SRC);

packages/amplify-provider-awscloudformation/src/display-helpful-urls.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ export const showSMSSandboxWarning = async (context): Promise<void> => {
271271

272272
const showGraphQLTransformerMigrationMessage = (): void => {
273273
const hasGraphqlApi = !!Object.entries(stateManager.getMeta().api || {})
274-
.filter(([__, apiResource]) => (apiResource as $TSAny).service === 'AppSync')
274+
.filter(([, apiResource]) => (apiResource as $TSAny).service === 'AppSync')
275275
.map(([name]) => name).length;
276276
const suppressMessage = FeatureFlags.getBoolean('graphqltransformer.suppressSchemaMigrationPrompt');
277277
const usingV2 = FeatureFlags.getNumber('graphqltransformer.transformerVersion') === 2;
@@ -293,7 +293,7 @@ export const showGraphQLTransformerVersion = async (context): Promise<void> => {
293293
const meta = stateManager.getMeta();
294294
const apiObject = (meta && meta.api) || {};
295295
const hasGraphqlApi = !!Object.entries(apiObject)
296-
.filter(([__, apiResource]) => (apiResource as $TSAny).service === 'AppSync')
296+
.filter(([, apiResource]) => (apiResource as $TSAny).service === 'AppSync')
297297
.map(([name]) => name).length;
298298

299299
if (!hasGraphqlApi) {

packages/amplify-provider-awscloudformation/src/graphql-resource-manager/amplify-graphql-resource-manager.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,5 +481,5 @@ export class GraphQLResourceManager {
481481
};
482482

483483
private getTableNameFromTemplate = (template: Template): string | undefined =>
484-
Object.entries(template?.Resources || {}).find(([_, resource]) => resource.Type === 'AWS::DynamoDB::Table')?.[0];
484+
Object.entries(template?.Resources || {}).find(([, resource]) => resource.Type === 'AWS::DynamoDB::Table')?.[0];
485485
}

packages/amplify-util-mock/src/api/lambda-arn-to-config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export const lambdaArnToConfig = async (context: $TSContext, arn: $TSAny): Promi
3434
throw new Error(`Cannot interpret Lambda ARN [${JSON.stringify(arn)}]${errorSuffix}`);
3535
}
3636
const lambdaNames = _.entries<{ service: string }>(_.get(stateManager.getMeta(), ['function']))
37-
.filter(([_, funcMeta]) => funcMeta.service === ServiceName.LambdaFunction)
37+
.filter(([, funcMeta]) => funcMeta.service === ServiceName.LambdaFunction)
3838
.map(([key]) => key);
3939
const foundLambdaName = lambdaNames.find((name) => searchString.includes(name));
4040
if (!foundLambdaName) {

yarn.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19604,13 +19604,13 @@ __metadata:
1960419604
languageName: node
1960519605
linkType: hard
1960619606

19607-
"follow-redirects@npm:^1.0.0, follow-redirects@npm:^1.15.4":
19608-
version: 1.15.5
19609-
resolution: "follow-redirects@npm:1.15.5"
19607+
"follow-redirects@npm:^1.15.6":
19608+
version: 1.15.6
19609+
resolution: "follow-redirects@npm:1.15.6"
1961019610
peerDependenciesMeta:
1961119611
debug:
1961219612
optional: true
19613-
checksum: 418d71688ceaf109dfd6f85f747a0c75de30afe43a294caa211def77f02ef19865b547dfb73fde82b751e1cc507c06c754120b848fe5a7400b0a669766df7615
19613+
checksum: 9ff767f0d7be6aa6870c82ac79cf0368cd73e01bbc00e9eb1c2a16fbb198ec105e3c9b6628bb98e9f3ac66fe29a957b9645bcb9a490bb7aa0d35f908b6b85071
1961419614
languageName: node
1961519615
linkType: hard
1961619616

0 commit comments

Comments
 (0)