@appland/appmap 3.155.0 → 3.155.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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ # [@appland/appmap-v3.155.1](https://github.com/getappmap/appmap-js/compare/@appland/appmap-v3.155.0...@appland/appmap-v3.155.1) (2024-07-25)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * conditionally create sql_warnings.txt ([737f59f](https://github.com/getappmap/appmap-js/commit/737f59f323b3c9300bc6985cb179fa7264c8f7fd))
7
+
1
8
  # [@appland/appmap-v3.155.0](https://github.com/getappmap/appmap-js/compare/@appland/appmap-v3.154.0...@appland/appmap-v3.155.0) (2024-07-24)
2
9
 
3
10
 
@@ -7,12 +7,19 @@ let SqlParseErrorFileOpened = false;
7
7
  async function writeErrorToFile(error) {
8
8
  const flags = SqlParseErrorFileOpened ? 'a' : 'w';
9
9
  SqlParseErrorFileOpened = true;
10
- (0, promises_1.open)(SqlParseErrorFileName, flags).then((handle) => {
11
- handle.write([String(error), ''].join('\n')).finally(handle.close.bind(handle));
12
- });
10
+ const msg = [String(error), ''].join('\n');
11
+ try {
12
+ (0, promises_1.open)(SqlParseErrorFileName, flags).then((handle) => {
13
+ handle.write(msg).finally(handle.close.bind(handle));
14
+ });
15
+ }
16
+ catch (e) {
17
+ console.warn(e);
18
+ console.warn(`SQL Error: ${msg}`);
19
+ }
13
20
  }
14
21
  function sqlErrorLog(parseError) {
15
- if (!SqlErrors.has(parseError.sql)) {
22
+ if (process.env['APPMAP_SQL_WARNING'] && !SqlErrors.has(parseError.sql)) {
16
23
  writeErrorToFile(parseError);
17
24
  SqlErrors.add(parseError.sql);
18
25
  }
@@ -1 +1 @@
1
- {"version":3,"file":"sqlErrorLog.js","sourceRoot":"","sources":["../../src/lib/sqlErrorLog.ts"],"names":[],"mappings":";;AACA,0CAAmC;AAEnC,MAAM,SAAS,GAAG,IAAI,GAAG,EAAE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CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC3C,IAAI;QACF,IAAA,eAAI,EAAC,qBAAqB,EAAE,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE;YACjD,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;QACvD,CAAC,CAAC,CAAC;KACJ;IAAC,OAAO,CAAC,EAAE;QACV,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAChB,OAAO,CAAC,IAAI,CAAC,cAAc,GAAG,EAAE,CAAC,CAAC;KACnC;AACH,CAAC;AAED,SAAwB,WAAW,CAAC,UAAsB;IACxD,IAAI,OAAO,CAAC,GAAG,CAAC,oBAAoB,CAAC,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE;QACvE,gBAAgB,CAAC,UAAU,CAAC,CAAC;QAC7B,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;KAC/B;AACH,CAAC;AALD,8BAKC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appland/appmap",
3
- "version": "3.155.0",
3
+ "version": "3.155.1",
4
4
  "description": "",
5
5
  "bin": "built/cli.js",
6
6
  "engines": {