Skip to content

Commit

Permalink
chore: upgrade aws sdk, remove internal, fix npm publish
Browse files Browse the repository at this point in the history
  • Loading branch information
Fernando Pauer authored and github-actions[bot] committed Nov 20, 2024
1 parent 18e7b04 commit 2701ef1
Show file tree
Hide file tree
Showing 34 changed files with 1,421 additions and 1,672 deletions.
Binary file removed iot-black-pearl-internal-v3.tgz
Binary file not shown.
2,993 changes: 1,373 additions & 1,620 deletions package-lock.json

Large diffs are not rendered by default.

5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,13 @@
"test:git": "git diff --exit-code",
"release": "npm run build",
"pack": "turbo run pack",
"publish-packages": "turbo run clean && rimraf .turbo && npm run install-ws && turbo run build lint test",
"publish-packages": "npm run install-ws && turbo run build lint test",
"versionup:patch": "turbo run version --no-git-tag-version patch",
"versionup:minor": "turbo run version --no-git-tag-version minor",
"versionup:major": "turbo run version --no-git-tag-version major",
"prepare": "husky install",
"test:ci": "if test \"$NODE_ENV\" = \"production\"; then echo \"Yes!\"; fi"
},
"dependencies": {
"@amzn/iot-black-pearl-internal-v3": "file:./iot-black-pearl-internal-v3.tgz"
},
"devDependencies": {
"@swc/core": "^1.3.71",
"@swc/jest": "^0.2.26",
Expand Down
7 changes: 4 additions & 3 deletions packages/core-util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@
"fix": "eslint --fix . --cache --cache-location .cache/eslint/",
"test": "npm run test:jest",
"test:jest": "TZ=UTC jest --cacheDirectory .cache/jest",
"test:typescript": "tsc --noEmit"
"test:typescript": "tsc --noEmit",
"pack": "npm pack"
},
"dependencies": {
"@iot-app-kit/core": "12.0.0",
Expand All @@ -44,7 +45,7 @@
"zustand": "^4.5.2"
},
"devDependencies": {
"@aws-sdk/types": "^3.310.0",
"@aws-sdk/types": "^3.696.0",
"@iot-app-kit/jest-config": "12.0.0",
"@iot-app-kit/ts-config": "12.0.0",
"@types/jest": "^29.4.0",
Expand All @@ -59,6 +60,6 @@
},
"peerDependencies": {
"@aws-sdk/client-iot-events": "^3.354.0",
"@aws-sdk/client-iotsitewise": "^3.456.0"
"@aws-sdk/client-iotsitewise": "^3.696.0"
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from './client';

jest.mock('@amzn/iot-black-pearl-internal-v3');
jest.mock('@aws-sdk/client-iotsitewise');

function flushPromises() {
return new Promise(jest.requireActual('timers').setImmediate);
Expand Down
5 changes: 1 addition & 4 deletions packages/core-util/src/sdks/IotSitewiseAssistant/client.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
import type {
IoTSiteWise,
ResponseStream,
} from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise, ResponseStream } from '@aws-sdk/client-iotsitewise';
import type {
AssistantClientInstanceParams,
AssistantClientInvocationCompleteHandler,
Expand Down
2 changes: 1 addition & 1 deletion packages/core-util/src/sdks/IotSitewiseAssistant/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import type {
ResponseStream,
IoTSiteWise,
InvokeAssistantRequest,
} from '@amzn/iot-black-pearl-internal-v3';
} from '@aws-sdk/client-iotsitewise';

export type AssistantClientInstanceParams = {
iotSiteWiseClient: Pick<IoTSiteWise, 'invokeAssistant'>;
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
"typescript": "^4.9.5"
},
"peerDependencies": {
"@aws-sdk/client-iotsitewise": "^3.456.0"
"@aws-sdk/client-iotsitewise": "^3.696.0"
},
"bugs": {
"url": "https://github.com/awslabs/iot-app-kit/issues"
Expand Down
5 changes: 3 additions & 2 deletions packages/dashboard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@
"fix": "eslint --fix . --cache --cache-location ./cache/eslint/",
"test:ui": "npx playwright test",
"test:ui:ci": "npx playwright test",
"test:ui:watch": "npx playwright test --ui"
"test:ui:watch": "npx playwright test --ui",
"pack": "npm pack"
},
"devDependencies": {
"@faker-js/faker": "^8.2.0",
Expand Down Expand Up @@ -133,7 +134,7 @@
},
"peerDependencies": {
"@aws-sdk/client-iot-events": "^3.354.0",
"@aws-sdk/client-iotsitewise": "^3.456.0",
"@aws-sdk/client-iotsitewise": "^3.696.0",
"@aws-sdk/client-iottwinmaker": "^3.354.0",
"react": "^18",
"react-dom": "^18"
Expand Down
7 changes: 5 additions & 2 deletions packages/dashboard/src/components/dashboard/getClients.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
import { IoTEventsClient } from '@aws-sdk/client-iot-events';
import { IoTSiteWiseClient, IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import {
IoTSiteWiseClient,
IoTSiteWise,
IoTSiteWise as InternalIoTSiteWise,
} from '@aws-sdk/client-iotsitewise';
import { IoTTwinMakerClient } from '@aws-sdk/client-iottwinmaker';
import { IoTSiteWise as InternalIoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import { type DashboardClientConfiguration } from '~/types';
import { type DashboardClientContext } from './clientContext';
import { isCredentials } from '~/hooks/useAWSRegion';
Expand Down
4 changes: 2 additions & 2 deletions packages/dashboard/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { type IoTSiteWise as InternalIoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import { type IoTEventsClient } from '@aws-sdk/client-iot-events';
import {
type IoTSiteWise as InternalIoTSiteWise,
type DescribeDashboardRequest,
type DescribeDashboardResponse,
type IoTSiteWise,
type IoTSiteWiseClient,
} from '@aws-sdk/client-iotsitewise';
import { type IoTEventsClient } from '@aws-sdk/client-iot-events';
import { type IoTTwinMakerClient } from '@aws-sdk/client-iottwinmaker';
import type { AwsCredentialIdentity, Provider } from '@aws-sdk/types';
import type { Viewport } from '@iot-app-kit/core';
Expand Down
2 changes: 1 addition & 1 deletion packages/doc-site/stories/mockAssistantAPI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import {
type InvokeAssistantCommandInput,
type InvokeAssistantCommandOutput,
type ResponseStream,
} from '@amzn/iot-black-pearl-internal-v3';
} from '@aws-sdk/client-iotsitewise';

export const mockedInvokeAssistantResponse1: ResponseStream = {
trace: {
Expand Down
2 changes: 1 addition & 1 deletion packages/react-components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@
"zustand": "^4.3.9"
},
"peerDependencies": {
"@aws-sdk/client-iotsitewise": "^3.456.0",
"@aws-sdk/client-iotsitewise": "^3.696.0",
"cytoscape": "^3.25",
"react": "^18",
"react-dom": "^18"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ResponseStream } from "@amzn/iot-black-pearl-internal-v3";
import type { ResponseStream } from "@aws-sdk/client-iotsitewise";

export const mockedInvokeAssistantResponse1:ResponseStream = {
trace: {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ResponseStream } from '@amzn/iot-black-pearl-internal-v3';
import type { ResponseStream } from '@aws-sdk/client-iotsitewise';
import { render } from '@testing-library/react';
import userEvent from '@testing-library/user-event';
import { MessageType } from '../../hooks/useAssistant/types';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ import Box from '@cloudscape-design/components/box';
import ExpandableSection from '@cloudscape-design/components/expandable-section';
import Link from '@cloudscape-design/components/link';
import SpaceBetween from '@cloudscape-design/components/space-between';
import type {
Citation,
ResponseStream,
} from '@amzn/iot-black-pearl-internal-v3';
import type { Citation, ResponseStream } from '@aws-sdk/client-iotsitewise';
import Markdown from 'react-markdown';
import remarkGfm from 'remark-gfm';
import { spaceStaticL } from '@cloudscape-design/design-tokens';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ResponseStream } from '@amzn/iot-black-pearl-internal-v3';
import type { ResponseStream } from '@aws-sdk/client-iotsitewise';
import { render, screen } from '@testing-library/react';
import userEvent from '@testing-library/user-event';
import { IntlProvider } from 'react-intl';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import {
act,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { type DataStream } from '@iot-app-kit/core';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { mockTimeSeriesDataQuery } from '@iot-app-kit/testing-util';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { mockTimeSeriesDataQuery } from '@iot-app-kit/testing-util';
import { render, renderHook, screen } from '@testing-library/react';
Expand Down
2 changes: 1 addition & 1 deletion packages/react-components/src/components/kpi/kpi.spec.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { mockTimeSeriesDataQuery } from '@iot-app-kit/testing-util';
import { render, renderHook, screen } from '@testing-library/react';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import type { PascalCaseStateName } from '@iot-app-kit/source-iotsitewise';
import { render } from '@testing-library/react';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import cloudscapeWrapper from '@cloudscape-design/components/test-utils/dom';
import type { DataStream } from '@iot-app-kit/core';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { render } from '@testing-library/react';
import { mockedInvokeAssistantResponse3 } from '../../__mocks__/assistantMockedResponse';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { render, waitFor } from '@testing-library/react';
import userEvent from '@testing-library/user-event';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ResponseStream } from '@amzn/iot-black-pearl-internal-v3';
import type { ResponseStream } from '@aws-sdk/client-iotsitewise';
import type { IMessage, IMessageParser, UniqueID } from './types';
import type { AssistantInvocationRequest } from '@iot-app-kit/core-util';
import { MessageType } from './types';
Expand Down
2 changes: 1 addition & 1 deletion packages/react-components/src/hooks/useAssistant/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ResponseStream } from '@amzn/iot-black-pearl-internal-v3';
import type { ResponseStream } from '@aws-sdk/client-iotsitewise';
import type {
AssistantInvocationRequest,
InvokeAssistantOptions,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { IoTSitewiseAssistantClient } from '@iot-app-kit/core-util';
import { useAssistant } from './useAssistant';
import { renderHook, waitFor, act } from '@testing-library/react';
import type { MessageParser } from './messageParser';
import type { IoTSiteWise } from '@amzn/iot-black-pearl-internal-v3';
import type { IoTSiteWise } from '@aws-sdk/client-iotsitewise';
import { MessageType } from './types';

const response1 = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import {
type InvokeAssistantCommandInput,
type InvokeAssistantCommandOutput,
} from '@amzn/iot-black-pearl-internal-v3';
} from '@aws-sdk/client-iotsitewise';
import {
mockedInvokeAssistantResponse1,
mockedInvokeAssistantResponse2,
Expand Down
8 changes: 4 additions & 4 deletions packages/scene-composer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
"license": "Apache-2.0",
"main": "./dist/cjs/src/index.js",
"module": "./dist/esm/src/index.js",
"types": "./dist/esm/src/index.d.ts",
"types": "./dist/src/index.d.ts",
"exports": {
".": {
"types": "./dist/esm/src/index.d.ts",
"types": "./dist/src/index.d.ts",
"require": "./dist/cjs/src/index.js",
"import": "./dist/esm/src/index.js",
"default": "./dist/esm/src/index.js"
Expand All @@ -24,7 +24,7 @@
"test": "__tests__"
},
"files": [
"dist/",
"dist",
"CHANGELOG.md",
"THIRD-PARTY-LICENSES",
"*NOTICE"
Expand Down Expand Up @@ -91,7 +91,7 @@
},
"devDependencies": {
"@aws-sdk/credential-providers": "^3.395.0",
"@aws-sdk/types": "^3.310.0",
"@aws-sdk/types": "^3.696.0",
"@awsui/jest-preset": "^2.0.20",
"@babel/preset-env": "^7.22.5",
"@babel/preset-react": "^7.22.5",
Expand Down
4 changes: 2 additions & 2 deletions packages/source-iotsitewise/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
"rxjs": "^7.8.1"
},
"devDependencies": {
"@aws-sdk/types": "^3.310.0",
"@aws-sdk/types": "^3.696.0",
"@iot-app-kit/jest-config": "12.0.0",
"@iot-app-kit/testing-util": "12.0.0",
"@iot-app-kit/ts-config": "12.0.0",
Expand All @@ -82,7 +82,7 @@
},
"peerDependencies": {
"@aws-sdk/client-iot-events": "^3.354.0",
"@aws-sdk/client-iotsitewise": "^3.456.0"
"@aws-sdk/client-iotsitewise": "^3.696.0"
},
"bugs": {
"url": "https://github.com/awslabs/iot-app-kit/issues"
Expand Down
4 changes: 2 additions & 2 deletions packages/source-iottwinmaker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"pack": "npm pack"
},
"dependencies": {
"@aws-sdk/client-iotsitewise": "3.456.0",
"@aws-sdk/client-iotsitewise": "3.696.0",
"@aws-sdk/client-iottwinmaker": "3.589.0",
"@aws-sdk/client-kinesis-video": "3.354.0",
"@aws-sdk/client-kinesis-video-archived-media": "3.354.0",
Expand All @@ -65,7 +65,7 @@
"rxjs": "^7.8.1"
},
"devDependencies": {
"@aws-sdk/types": "^3.310.0",
"@aws-sdk/types": "^3.696.0",
"@iot-app-kit/jest-config": "12.0.0",
"@iot-app-kit/ts-config": "12.0.0",
"@types/jest": "^29.4.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/testing-util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
},
"dependencies": {
"@aws-sdk/client-iot-events": "3.354.0",
"@aws-sdk/client-iotsitewise": "3.456.0",
"@aws-sdk/client-iotsitewise": "3.696.0",
"@iot-app-kit/core": "12.0.0",
"parse-duration": "^1.1.0"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/tools-iottwinmaker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"@aws-sdk/client-kinesis-video": "^3.363.0",
"@aws-sdk/client-s3": "^3.363.0",
"@aws-sdk/client-sts": "^3.363.0",
"@aws-sdk/types": "^3.363.0",
"@aws-sdk/types": "^3.696.0",
"prompts": "^2.4.2",
"yargs": "^17.7.2"
},
Expand Down

0 comments on commit 2701ef1

Please sign in to comment.