@embeddable.com/sdk-core 3.4.0 → 3.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.js CHANGED
@@ -4972,21 +4972,26 @@ async function dataModelsValidation(filesList) {
4972
4972
  const errors = [];
4973
4973
  for (const [_, filePath] of filesList) {
4974
4974
  const fileContentRaw = await fs__namespace.readFile(filePath, "utf8");
4975
- const cube = YAML__namespace.parse(fileContentRaw);
4976
- if (!(cube === null || cube === void 0 ? void 0 : cube.cubes) && !(cube === null || cube === void 0 ? void 0 : cube.views)) {
4977
- return [`${filePath}: At least one cubes or views must be defined`];
4978
- }
4979
- const cubeModelSafeParse = cubeModelSchema.safeParse(cube);
4980
- const viewModelSafeParse = viewModelSchema.safeParse(cube);
4981
- if (cube.cubes && !cubeModelSafeParse.success) {
4982
- errorFormatter(cubeModelSafeParse.error.issues).forEach((error) => {
4983
- errors.push(`${filePath}: ${error}`);
4984
- });
4975
+ try {
4976
+ const cube = YAML__namespace.parse(fileContentRaw);
4977
+ if (!(cube === null || cube === void 0 ? void 0 : cube.cubes) && !(cube === null || cube === void 0 ? void 0 : cube.views)) {
4978
+ return [`${filePath}: At least one cubes or views must be defined`];
4979
+ }
4980
+ const cubeModelSafeParse = cubeModelSchema.safeParse(cube);
4981
+ const viewModelSafeParse = viewModelSchema.safeParse(cube);
4982
+ if (cube.cubes && !cubeModelSafeParse.success) {
4983
+ errorFormatter(cubeModelSafeParse.error.issues).forEach((error) => {
4984
+ errors.push(`${filePath}: ${error}`);
4985
+ });
4986
+ }
4987
+ if (cube.views && !viewModelSafeParse.success) {
4988
+ errorFormatter(viewModelSafeParse.error.issues).forEach((error) => {
4989
+ errors.push(`${filePath}: ${error}`);
4990
+ });
4991
+ }
4985
4992
  }
4986
- if (cube.views && !viewModelSafeParse.success) {
4987
- errorFormatter(viewModelSafeParse.error.issues).forEach((error) => {
4988
- errors.push(`${filePath}: ${error}`);
4989
- });
4993
+ catch (e) {
4994
+ errors.push(`${filePath}: ${e.message}`);
4990
4995
  }
4991
4996
  }
4992
4997
  return errors;
@@ -20962,7 +20967,7 @@ var defineConfig = ({ plugins, pushBaseUrl, audienceUrl, authDomain, authClientI
20962
20967
  };
20963
20968
 
20964
20969
  var name = "@embeddable.com/sdk-core";
20965
- var version = "3.4.0";
20970
+ var version = "3.4.1";
20966
20971
  var description = "Core Embeddable SDK module responsible for web-components bundling and publishing.";
20967
20972
  var keywords = [
20968
20973
  "embeddable",
@@ -21013,7 +21018,7 @@ var dependencies = {
21013
21018
  ora: "^8.0.1",
21014
21019
  "serve-static": "^1.15.0",
21015
21020
  sorcery: "^0.11.0",
21016
- vite: "^5.3.1",
21021
+ vite: "^5.3.2",
21017
21022
  ws: "^8.17.0",
21018
21023
  yaml: "^2.3.3"
21019
21024
  };