@forzalabs/remora 0.2.5 → 0.2.6

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/Constants.js CHANGED
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const CONSTANTS = {
4
- cliVersion: '0.2.5',
4
+ cliVersion: '0.2.6',
5
5
  backendVersion: 1,
6
6
  backendPort: 5088,
7
7
  workerVersion: 2,
@@ -158,7 +158,7 @@ class LocalSourceDriver {
158
158
  totalLineCount = yield copyLocally(fileKey, dataset.getFirstLine(), appendMode, sourceFilename, streamXLS);
159
159
  break;
160
160
  default:
161
- totalLineCount = yield copyLocally(fileKey, dataset.getFirstLine(), false, sourceFilename);
161
+ totalLineCount = yield copyLocally(fileKey, dataset.getFirstLine(), appendMode, sourceFilename);
162
162
  break;
163
163
  }
164
164
  return totalLineCount;
@@ -177,7 +177,7 @@ class LocalSourceDriver {
177
177
  const currentFileKey = allFileKeys[i];
178
178
  // Pass the filename (just the basename) if includeSourceFilename is enabled
179
179
  const sourceFilename = includeSourceFilename ? path_1.default.basename(currentFileKey) : undefined;
180
- totalLineCount += yield handleFileAndGetLineCount(currentFileKey, true, file.fileType, sourceFilename); // Append mode for subsequent files
180
+ totalLineCount += yield handleFileAndGetLineCount(currentFileKey, i > 0, file.fileType, sourceFilename); // Append mode for subsequent files
181
181
  }
182
182
  dataset.setCount(totalLineCount);
183
183
  return dataset;
@@ -50,7 +50,10 @@ class TransformationEngineClass {
50
50
  break;
51
51
  case 'fail':
52
52
  default:
53
- throw error;
53
+ if (field.transform)
54
+ throw new Error(`an error occured during the transformation ${field.transform} on filedKey: ${fieldKey} the error is the following: ${error}`);
55
+ else
56
+ throw new Error(`an error occured at filedKey: ${fieldKey} the error is the following: ${error}`);
54
57
  }
55
58
  }
56
59
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forzalabs/remora",
3
- "version": "0.2.5",
3
+ "version": "0.2.6",
4
4
  "description": "A powerful CLI tool for seamless data translation.",
5
5
  "main": "index.js",
6
6
  "private": false,