From 8889cac63ce08ad3f1114451123d06d92220c22a Mon Sep 17 00:00:00 2001 From: Oleksii Orel Date: Mon, 16 Dec 2024 19:00:59 +0200 Subject: [PATCH 1/3] upgrade @eclipse-che/che-devworkspace-generator and @devfile/api Signed-off-by: Oleksii Orel --- .deps/EXCLUDED/prod.md | 1 + .deps/prod.md | 8 +++--- packages/common/package.json | 2 +- packages/dashboard-backend/package.json | 4 +-- .../src/constants/devfile.ts | 19 +++++++++++++ .../__tests__/devWorkspaceApi.spec.ts | 6 +++- .../__tests__/devWorkspaceClusterApi.spec.ts | 6 +++- .../__tests__/devWorkspaceTemplateApi.spec.ts | 2 +- .../services/devWorkspaceApi.ts | 6 +++- .../services/devWorkspaceClusterApiService.ts | 6 +++- .../services/devWorkspaceTemplateApi.ts | 2 +- .../src/routes/api/devworkspaceResources.ts | 2 -- packages/dashboard-frontend/package.json | 2 +- .../yarn/old_version/.deps/EXCLUDED/prod.md | 1 + yarn.lock | 28 +++++++++---------- 15 files changed, 65 insertions(+), 30 deletions(-) create mode 100644 packages/dashboard-backend/src/constants/devfile.ts diff --git a/.deps/EXCLUDED/prod.md b/.deps/EXCLUDED/prod.md index 9a01bf422..fe892b414 100644 --- a/.deps/EXCLUDED/prod.md +++ b/.deps/EXCLUDED/prod.md @@ -2,6 +2,7 @@ This file lists dependencies that do not need CQs or auto-detection does not wor | Packages | Resolved CQs | | --- | --- | +| `@devfile/api@2.3.0-1733171449` | N/A | | `@fastify/cors@9.0.1` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@fastify/cors/9.0.1) | | `@fastify/swagger-ui@4.2.0` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@fastify/swagger-ui/4.2.0) | | `@hapi/hoek@10.0.1` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@hapi/hoek/10.0.1) | diff --git a/.deps/prod.md b/.deps/prod.md index 7cb2397e4..79febb821 100644 --- a/.deps/prod.md +++ b/.deps/prod.md @@ -8,8 +8,8 @@ | [`@codemirror/language@6.10.3`](https://github.com/codemirror/language.git) | MIT | clearlydefined | | [`@codemirror/state@6.4.1`](https://github.com/codemirror/state.git) | MIT | clearlydefined | | [`@codemirror/view@6.34.2`](https://github.com/codemirror/view.git) | MIT | clearlydefined | -| [`@devfile/api@2.3.0-1721400636`](https://github.com/GIT_USER_ID/GIT_REPO_ID.git) | Apache-2.0 | clearlydefined | -| [`@eclipse-che/che-devworkspace-generator@7.90.0-next-4510df7`](git+https://github.com/devfile/devworkspace-generator.git) | EPL-2.0 | ecd.che | +| [`@devfile/api@2.3.0-1733171449`](https://github.com/GIT_USER_ID/GIT_REPO_ID.git) | Apache-2.0 | | +| [`@eclipse-che/che-devworkspace-generator@7.96.0-next-da9f364`](git+https://github.com/devfile/devworkspace-generator.git) | EPL-2.0 | ecd.che | | [`@fastify/accept-negotiator@1.1.0`](git+https://github.com/fastify/accept-negotiator.git) | MIT | clearlydefined | | [`@fastify/ajv-compiler@3.6.0`](git+https://github.com/fastify/ajv-compiler.git) | MIT | clearlydefined | | [`@fastify/busboy@2.0.0`](https://github.com/fastify/busboy.git) | MIT | clearlydefined | @@ -78,7 +78,7 @@ | [`abbrev@2.0.0`](https://github.com/npm/abbrev-js.git) | ISC | clearlydefined | | [`abort-controller@3.0.0`](git+https://github.com/mysticatea/abort-controller.git) | MIT | #7592 | | [`abstract-logging@2.0.1`](git+https://github.com/jsumners/abstract-logging.git) | MIT | clearlydefined | -| [`agent-base@7.1.1`](https://github.com/TooTallNate/proxy-agents.git) | MIT | clearlydefined | +| [`agent-base@7.1.1`](https://github.com/TooTallNate/proxy-agents.git) | MIT | #17896 | | `aggregate-error@3.1.0` | MIT | clearlydefined | | [`ajv-formats@2.1.1`](git+https://github.com/ajv-validator/ajv-formats.git) | MIT | clearlydefined | | [`ajv-formats@3.0.1`](git+https://github.com/ajv-validator/ajv-formats.git) | MIT | clearlydefined | @@ -253,7 +253,7 @@ | `http-errors@2.0.0` | MIT | clearlydefined | | [`http-proxy-agent@7.0.2`](https://github.com/TooTallNate/proxy-agents.git) | MIT | clearlydefined | | [`http-signature@1.2.0`](git://github.com/joyent/node-http-signature.git) | MIT | #2732 | -| [`https-proxy-agent@7.0.5`](https://github.com/TooTallNate/proxy-agents.git) | MIT | clearlydefined | +| [`https-proxy-agent@7.0.5`](https://github.com/TooTallNate/proxy-agents.git) | MIT | #17900 | | `https@1.0.0` | ISC | clearlydefined | | [`iconv-lite@0.6.3`](git://github.com/ashtuchkin/iconv-lite.git) | MIT | clearlydefined | | [`ieee754@1.2.1`](git://github.com/feross/ieee754.git) | BSD-3-Clause | clearlydefined | diff --git a/packages/common/package.json b/packages/common/package.json index 1c6ae8dc2..49e64aa8f 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -17,7 +17,7 @@ "test:watch": "yarn test --watch" }, "devDependencies": { - "@devfile/api": "2.3.0-1721400636", + "@devfile/api": "2.3.0-1733171449", "@kubernetes/client-node": "^0.22.1", "@types/jest": "^29.5.3", "@typescript-eslint/eslint-plugin": "^6.3.0", diff --git a/packages/dashboard-backend/package.json b/packages/dashboard-backend/package.json index 0438a4fab..23190433a 100644 --- a/packages/dashboard-backend/package.json +++ b/packages/dashboard-backend/package.json @@ -26,8 +26,8 @@ ], "license": "EPL-2.0", "dependencies": { - "@devfile/api": "2.3.0-1721400636", - "@eclipse-che/che-devworkspace-generator": "7.90.0-next-4510df7", + "@devfile/api": "2.3.0-1733171449", + "@eclipse-che/che-devworkspace-generator": "7.96.0-next-da9f364", "@fastify/cors": "^9.0.1", "@fastify/error": "^3.4.1", "@fastify/http-proxy": "^9.5.0", diff --git a/packages/dashboard-backend/src/constants/devfile.ts b/packages/dashboard-backend/src/constants/devfile.ts new file mode 100644 index 000000000..49960f78c --- /dev/null +++ b/packages/dashboard-backend/src/constants/devfile.ts @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2018-2024 Red Hat, Inc. + * This program and the accompanying materials are made + * available under the terms of the Eclipse Public License 2.0 + * which is available at https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Red Hat, Inc. - initial API and implementation + */ + +export const devworkspaceGroup = 'workspace.devfile.io'; +export const devworkspacePlural = 'devworkspaces'; +export const devworkspaceLatestVersion = 'v1alpha2'; + +export const devworkspacetemplateGroup = 'workspace.devfile.io'; +export const devworkspacetemplatePlural = 'devworkspacetemplates'; +export const devworkspacetemplateLatestVersion = 'v1alpha2'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts index bb63638f7..e82427f0e 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts @@ -13,7 +13,11 @@ /* eslint-disable @typescript-eslint/no-unused-vars */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { devworkspaceGroup, devworkspaceLatestVersion, devworkspacePlural } from '@devfile/api/api'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as mockClient from '@kubernetes/client-node'; import { CustomObjectsApi } from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts index b4374c65a..d5e8b1bbd 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts @@ -11,7 +11,11 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { devworkspaceGroup, devworkspaceLatestVersion, devworkspacePlural } from '@devfile/api/api'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import * as mockClient from '@kubernetes/client-node'; import { CustomObjectsApi } from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts index a2bdaea24..94475bb78 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts @@ -17,7 +17,7 @@ import { devworkspacetemplateGroup, devworkspacetemplateLatestVersion, devworkspacetemplatePlural, -} from '@devfile/api/api'; +} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as mockClient from '@kubernetes/client-node'; import { CustomObjectsApi } from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts index a6db1200b..b5731f139 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts @@ -11,7 +11,11 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { devworkspaceGroup, devworkspaceLatestVersion, devworkspacePlural } from '@devfile/api/api'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as k8s from '@kubernetes/client-node'; import { V1Status } from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts index e259257ca..690515396 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts @@ -11,7 +11,11 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { devworkspaceGroup, devworkspaceLatestVersion, devworkspacePlural } from '@devfile/api/api'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as k8s from '@kubernetes/client-node'; import { V1Status } from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts index 3c8c18272..aebaaeadf 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts @@ -15,7 +15,7 @@ import { devworkspacetemplateGroup, devworkspacetemplateLatestVersion, devworkspacetemplatePlural, -} from '@devfile/api/api'; +} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as k8s from '@kubernetes/client-node'; diff --git a/packages/dashboard-backend/src/routes/api/devworkspaceResources.ts b/packages/dashboard-backend/src/routes/api/devworkspaceResources.ts index 8347506e4..2d5f9a476 100644 --- a/packages/dashboard-backend/src/routes/api/devworkspaceResources.ts +++ b/packages/dashboard-backend/src/routes/api/devworkspaceResources.ts @@ -37,8 +37,6 @@ export function registerDevworkspaceResourcesRoute(instance: FastifyInstance) { { devfileContent, editorPath, - pluginRegistryUrl: undefined, - editorEntry: undefined, editorContent, projects: [], }, diff --git a/packages/dashboard-frontend/package.json b/packages/dashboard-frontend/package.json index 765f31f40..4ef5b63d9 100644 --- a/packages/dashboard-frontend/package.json +++ b/packages/dashboard-frontend/package.json @@ -71,7 +71,7 @@ "sanitize-html": "^2.11.0" }, "devDependencies": { - "@devfile/api": "2.3.0-1721400636", + "@devfile/api": "2.3.0-1733171449", "@eclipse-che/api": "^7.86.0", "@kubernetes/client-node": "^0.22.1", "@react-mock/state": "^0.1.8", diff --git a/scripts/yarn/old_version/.deps/EXCLUDED/prod.md b/scripts/yarn/old_version/.deps/EXCLUDED/prod.md index 9a01bf422..fe892b414 100644 --- a/scripts/yarn/old_version/.deps/EXCLUDED/prod.md +++ b/scripts/yarn/old_version/.deps/EXCLUDED/prod.md @@ -2,6 +2,7 @@ This file lists dependencies that do not need CQs or auto-detection does not wor | Packages | Resolved CQs | | --- | --- | +| `@devfile/api@2.3.0-1733171449` | N/A | | `@fastify/cors@9.0.1` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@fastify/cors/9.0.1) | | `@fastify/swagger-ui@4.2.0` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@fastify/swagger-ui/4.2.0) | | `@hapi/hoek@10.0.1` | [clearlydefined](https://clearlydefined.io/definitions/npm/npmjs/@hapi/hoek/10.0.1) | diff --git a/yarn.lock b/yarn.lock index 720a4b3d2..f27555080 100644 --- a/yarn.lock +++ b/yarn.lock @@ -554,9 +554,9 @@ __metadata: languageName: node linkType: hard -"@devfile/api@npm:2.3.0-1721400636": - version: 2.3.0-1721400636 - resolution: "@devfile/api@npm:2.3.0-1721400636" +"@devfile/api@npm:2.3.0-1733171449": + version: 2.3.0-1733171449 + resolution: "@devfile/api@npm:2.3.0-1733171449" dependencies: "@types/node": "*" "@types/node-fetch": ^2.5.7 @@ -564,7 +564,7 @@ __metadata: form-data: ^2.5.0 node-fetch: ^2.6.0 url-parse: ^1.4.3 - checksum: 98f5e2bc03e3b2d4ec649176aa57a5cf1538fa37a94d1dbe48ebfb4efbdf2d1ecbcf18a4f842f4be9f7bff9ace89fb5d6061d9eb7e24a1a7455ece67fbe36a14 + checksum: 770f09371f97e2e694e1f9a3b5c72726f9e2107f040720a541330365625caa03879f4cced5baab15c55319bd863d6db8a2c9f2880bba8b2b41a3b08c0edd09d0 languageName: node linkType: hard @@ -582,12 +582,12 @@ __metadata: languageName: node linkType: hard -"@eclipse-che/che-devworkspace-generator@npm:7.90.0-next-4510df7": - version: 7.90.0-next-4510df7 - resolution: "@eclipse-che/che-devworkspace-generator@npm:7.90.0-next-4510df7" +"@eclipse-che/che-devworkspace-generator@npm:7.96.0-next-da9f364": + version: 7.96.0-next-da9f364 + resolution: "@eclipse-che/che-devworkspace-generator@npm:7.96.0-next-da9f364" dependencies: - "@devfile/api": 2.3.0-1721400636 - axios: ^1.7.0 + "@devfile/api": 2.3.0-1733171449 + axios: ^1.7.4 fs-extra: ^11.2.0 inversify: ^6.0.2 js-yaml: ^4.0.0 @@ -596,7 +596,7 @@ __metadata: reflect-metadata: ^0.2.2 bin: che-devworkspace-generator: lib/entrypoint.js - checksum: 6bceb055206cf7a7b0e78892705aa83b33ad910778f8e6cf4d5edf230054a5cdeb310ea3d908e9f4b78dfc3bb9d748c2872fcea178dd457b61ff33d690fce78f + checksum: 37806af3c7d6e511354409ac0e484c635235aa7b7b57fb5feeaf7f028860066d22f00c3e74f49f1a28df5914f5d4d429bd5f9efc0b717e08fcff8252ed86858e languageName: node linkType: hard @@ -604,7 +604,7 @@ __metadata: version: 0.0.0-use.local resolution: "@eclipse-che/common@workspace:packages/common" dependencies: - "@devfile/api": 2.3.0-1721400636 + "@devfile/api": 2.3.0-1733171449 "@kubernetes/client-node": ^0.22.1 "@types/jest": ^29.5.3 "@typescript-eslint/eslint-plugin": ^6.3.0 @@ -627,8 +627,8 @@ __metadata: version: 0.0.0-use.local resolution: "@eclipse-che/dashboard-backend@workspace:packages/dashboard-backend" dependencies: - "@devfile/api": 2.3.0-1721400636 - "@eclipse-che/che-devworkspace-generator": 7.90.0-next-4510df7 + "@devfile/api": 2.3.0-1733171449 + "@eclipse-che/che-devworkspace-generator": 7.96.0-next-da9f364 "@fastify/cors": ^9.0.1 "@fastify/error": ^3.4.1 "@fastify/http-proxy": ^9.5.0 @@ -691,7 +691,7 @@ __metadata: "@codemirror/language": ^6.10.3 "@codemirror/state": ^6.4.1 "@codemirror/view": ^6.34.1 - "@devfile/api": 2.3.0-1721400636 + "@devfile/api": 2.3.0-1733171449 "@eclipse-che/api": ^7.86.0 "@kubernetes/client-node": ^0.22.1 "@lezer/highlight": ^1.2.1 From 99b5eb4996e34fd455c08b3b3afcc17506ceff77 Mon Sep 17 00:00:00 2001 From: Oleksii Orel Date: Mon, 16 Dec 2024 19:09:05 +0200 Subject: [PATCH 2/3] fixup! upgrade @eclipse-che/che-devworkspace-generator and @devfile/api Signed-off-by: Oleksii Orel --- .../services/__tests__/devWorkspaceApi.spec.ts | 10 +++++----- .../services/__tests__/devWorkspaceClusterApi.spec.ts | 6 +++--- .../services/__tests__/devWorkspaceTemplateApi.spec.ts | 8 ++++---- .../src/devworkspaceClient/services/devWorkspaceApi.ts | 10 +++++----- .../services/devWorkspaceClusterApiService.ts | 10 +++++----- .../services/devWorkspaceTemplateApi.ts | 6 +++--- 6 files changed, 25 insertions(+), 25 deletions(-) diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts index e82427f0e..9b631295f 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceApi.spec.ts @@ -13,16 +13,16 @@ /* eslint-disable @typescript-eslint/no-unused-vars */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { - devworkspaceGroup, - devworkspaceLatestVersion, - devworkspacePlural, -} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as mockClient from '@kubernetes/client-node'; import { CustomObjectsApi } from '@kubernetes/client-node'; import { IncomingMessage } from 'http'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { DevWorkspaceApiService } from '@/devworkspaceClient/services/devWorkspaceApi'; const namespace = 'user-che'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts index d5e8b1bbd..16919e536 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceClusterApi.spec.ts @@ -11,14 +11,14 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; +import * as mockClient from '@kubernetes/client-node'; +import { CustomObjectsApi } from '@kubernetes/client-node'; + import { devworkspaceGroup, devworkspaceLatestVersion, devworkspacePlural, } from '@/constants/devfile'; -import * as mockClient from '@kubernetes/client-node'; -import { CustomObjectsApi } from '@kubernetes/client-node'; - import { CheClusterCustomResource, CustomResourceDefinitionList, diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts index 94475bb78..a67f44c40 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/__tests__/devWorkspaceTemplateApi.spec.ts @@ -13,15 +13,15 @@ /* eslint-disable @typescript-eslint/no-unused-vars */ import { V1alpha2DevWorkspaceTemplate } from '@devfile/api'; +import { api } from '@eclipse-che/common'; +import * as mockClient from '@kubernetes/client-node'; +import { CustomObjectsApi } from '@kubernetes/client-node'; + import { devworkspacetemplateGroup, devworkspacetemplateLatestVersion, devworkspacetemplatePlural, } from '@/constants/devfile'; -import { api } from '@eclipse-che/common'; -import * as mockClient from '@kubernetes/client-node'; -import { CustomObjectsApi } from '@kubernetes/client-node'; - import { DevWorkspaceTemplateApiService, DevWorkspaceTemplateList, diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts index b5731f139..51169f76b 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceApi.ts @@ -11,16 +11,16 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { - devworkspaceGroup, - devworkspaceLatestVersion, - devworkspacePlural, -} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as k8s from '@kubernetes/client-node'; import { V1Status } from '@kubernetes/client-node'; import http, { IncomingHttpHeaders } from 'http'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { createError } from '@/devworkspaceClient/services/helpers/createError'; import { CustomObjectAPI, diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts index 690515396..437ed61fb 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceClusterApiService.ts @@ -11,16 +11,16 @@ */ import { V1alpha2DevWorkspace } from '@devfile/api'; -import { - devworkspaceGroup, - devworkspaceLatestVersion, - devworkspacePlural, -} from '@/constants/devfile'; import { api } from '@eclipse-che/common'; import * as k8s from '@kubernetes/client-node'; import { V1Status } from '@kubernetes/client-node'; import http from 'http'; +import { + devworkspaceGroup, + devworkspaceLatestVersion, + devworkspacePlural, +} from '@/constants/devfile'; import { prepareCustomObjectWatch } from '@/devworkspaceClient/services/helpers/prepareCustomObjectWatch'; import { ServerConfigApiService } from '@/devworkspaceClient/services/serverConfigApi'; import { IDevWorkspaceClusterApi } from '@/devworkspaceClient/types'; diff --git a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts index aebaaeadf..15c1c4a1b 100644 --- a/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts +++ b/packages/dashboard-backend/src/devworkspaceClient/services/devWorkspaceTemplateApi.ts @@ -11,14 +11,14 @@ */ import { V1alpha2DevWorkspaceTemplate } from '@devfile/api'; +import { api } from '@eclipse-che/common'; +import * as k8s from '@kubernetes/client-node'; + import { devworkspacetemplateGroup, devworkspacetemplateLatestVersion, devworkspacetemplatePlural, } from '@/constants/devfile'; -import { api } from '@eclipse-che/common'; -import * as k8s from '@kubernetes/client-node'; - import { createError } from '@/devworkspaceClient/services/helpers/createError'; import { CustomObjectAPI, From b4e18dc1890f8501496482c56d9c4ece072f21cd Mon Sep 17 00:00:00 2001 From: Oleksii Orel Date: Tue, 17 Dec 2024 12:39:29 +0200 Subject: [PATCH 3/3] fixup! fixup! upgrade @eclipse-che/che-devworkspace-generator and @devfile/api Signed-off-by: Oleksii Orel --- packages/dashboard-backend/jest.config.js | 7 ------- packages/dashboard-backend/webpack.config.common.js | 4 ---- 2 files changed, 11 deletions(-) diff --git a/packages/dashboard-backend/jest.config.js b/packages/dashboard-backend/jest.config.js index c5bbd513f..f2f5e2070 100644 --- a/packages/dashboard-backend/jest.config.js +++ b/packages/dashboard-backend/jest.config.js @@ -21,14 +21,7 @@ module.exports = { moduleNameMapper: { // mapping for absolute imports (see tsconfig.json) '^@/(.*)$': '/src/$1', - - // not everything we need is exported from the package - // so we need to alias the rest - '@devfile/api/(.*)$': '/../../node_modules/@devfile/api/$1.ts', }, - transformIgnorePatterns: [ - 'node_modules/(?!@devfile/api)', - ], collectCoverageFrom: [ ...base.collectCoverageFrom, diff --git a/packages/dashboard-backend/webpack.config.common.js b/packages/dashboard-backend/webpack.config.common.js index 3ddfcafcf..94548edc2 100644 --- a/packages/dashboard-backend/webpack.config.common.js +++ b/packages/dashboard-backend/webpack.config.common.js @@ -44,10 +44,6 @@ module.exports = () => { alias: { // alias for absolute imports (see tsconfig.json) '@': path.resolve(__dirname, 'src/'), - - // not everything we need is exported from the package - // so we need to alias the rest - '@devfile/api/api': path.resolve(__dirname, '../../node_modules/@devfile/api/api.ts'), }, }, resolveLoader: {},