graphify-sf 0.4.5 → 0.4.7

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.
@@ -2,7 +2,7 @@
2
2
  "use strict";
3
3
 
4
4
  const { spawn } = require("child_process");
5
- const { ensureBinary } = require("../lib/download");
5
+ const { ensureBinary, describeError } = require("../lib/download");
6
6
 
7
7
  ensureBinary()
8
8
  .then((bin) => {
@@ -16,6 +16,6 @@ ensureBinary()
16
16
  });
17
17
  })
18
18
  .catch((err) => {
19
- process.stderr.write(`graphify-sf: ${err.message}\n`);
19
+ process.stderr.write(`graphify-sf: ${describeError(err)}\n`);
20
20
  process.exit(1);
21
21
  });
package/checksums.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
- "graphify-sf-darwin-arm64": "26962e77bf014b8037f2b0cfb52b20430f8ce6ddb2c7c50eeeff09eef03e7f44",
3
- "graphify-sf-darwin-x64": "76c8756303d83631bcf0876cf2f4472a82c66a4e014526fed4da00837ad62e8a",
4
- "graphify-sf-linux-arm64": "3e64503640ae0e8380b6b165e8404aa434e2b8506f60a9909ce54ae1a0e5fc5a",
5
- "graphify-sf-linux-x64": "453819caaf77211961e6b07e2b827fe3302816de9ab2a1381063c6d0693700a7",
6
- "graphify-sf-win32-x64.exe": "7e5df8fff802181e87ae1cab36879e796fc271fb0ef3293bd64152c93455153c"
2
+ "graphify-sf-darwin-arm64": "d4d0bd7f682fc156763bbb8e7002bd22bf1026682d248b668959ddc826f3c520",
3
+ "graphify-sf-darwin-x64": "855892934adb32332a7e5bf7f42e13d320c4bb06832264efb1dadceba2a43c79",
4
+ "graphify-sf-linux-arm64": "fe4d279fb770e9a5b56ced421f18a00fbb00a46c72cd703e4266cb65a7d4ed4e",
5
+ "graphify-sf-linux-x64": "5de737da6454f28397cd837e35d4445ad48b51b9299d28ebf398761236543320",
6
+ "graphify-sf-win32-x64.exe": "28cded0805ad15f36bd5c5da02469478c7be8f474ec7618194096d1a7e380747"
7
7
  }
package/install.js CHANGED
@@ -20,7 +20,7 @@
20
20
  // print actionable remediation and still exit 0; the binary is fetched lazily
21
21
  // on first run instead.
22
22
 
23
- const { envBinary, subpackageBinary, download } = require("./lib/download");
23
+ const { envBinary, subpackageBinary, download, describeError } = require("./lib/download");
24
24
 
25
25
  async function main() {
26
26
  // If a binary already resolves (env override or the platform subpackage),
@@ -38,7 +38,7 @@ async function main() {
38
38
  } catch (err) {
39
39
  process.stderr.write(
40
40
  `\ngraphify-sf: no prebuilt binary for this platform and the fallback download failed.\n` +
41
- ` Reason: ${err.message}\n` +
41
+ ` Reason: ${describeError(err)}\n` +
42
42
  `\n` +
43
43
  ` This is non-fatal — installation will continue. The binary will be\n` +
44
44
  ` fetched automatically the first time you run graphify-sf, provided\n` +
package/lib/download.js CHANGED
@@ -294,8 +294,16 @@ async function ensureBinary(opts) {
294
294
  return dest;
295
295
  }
296
296
 
297
+ // Messages thrown by this module already start with "graphify-sf: ". Callers that print
298
+ // them under their own prefix use this to avoid "graphify-sf: graphify-sf: ...".
299
+ function describeError(err) {
300
+ const message = err && err.message != null ? String(err.message) : String(err);
301
+ return message.replace(/^graphify-sf:\s*/, "");
302
+ }
303
+
297
304
  module.exports = {
298
305
  assetName,
306
+ describeError,
299
307
  binaryPath,
300
308
  binDir,
301
309
  download,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "graphify-sf",
3
- "version": "0.4.5",
3
+ "version": "0.4.7",
4
4
  "description": "Turn any Salesforce SFDX project into a queryable knowledge graph — no Python required.",
5
5
  "bin": {
6
6
  "graphify-sf": "bin/graphify-sf.js"
@@ -11,11 +11,11 @@
11
11
  "test": "node --test"
12
12
  },
13
13
  "optionalDependencies": {
14
- "@graphify-sf/cli-linux-x64": "0.4.5",
15
- "@graphify-sf/cli-linux-arm64": "0.4.5",
16
- "@graphify-sf/cli-darwin-x64": "0.4.5",
17
- "@graphify-sf/cli-darwin-arm64": "0.4.5",
18
- "@graphify-sf/cli-win32-x64": "0.4.5"
14
+ "@graphify-sf/cli-linux-x64": "0.4.7",
15
+ "@graphify-sf/cli-linux-arm64": "0.4.7",
16
+ "@graphify-sf/cli-darwin-x64": "0.4.7",
17
+ "@graphify-sf/cli-darwin-arm64": "0.4.7",
18
+ "@graphify-sf/cli-win32-x64": "0.4.7"
19
19
  },
20
20
  "files": [
21
21
  "bin/graphify-sf.js",