@synkro-sh/cli 1.3.23 → 1.3.24

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/dist/bootstrap.js CHANGED
@@ -3333,7 +3333,7 @@ function writeConfigEnv(opts) {
3333
3333
  `SYNKRO_CREDENTIALS_PATH=${shellQuoteSingle(credsPath)}`,
3334
3334
  `SYNKRO_TIER=${shellQuoteSingle(safeTier)}`,
3335
3335
  `SYNKRO_INFERENCE=${shellQuoteSingle(safeInference)}`,
3336
- `SYNKRO_VERSION=${shellQuoteSingle("1.3.23")}`
3336
+ `SYNKRO_VERSION=${shellQuoteSingle("1.3.24")}`
3337
3337
  ];
3338
3338
  if (safeUserId) lines.push(`SYNKRO_USER_ID=${shellQuoteSingle(safeUserId)}`);
3339
3339
  if (safeOrgId) lines.push(`SYNKRO_ORG_ID=${shellQuoteSingle(safeOrgId)}`);
@@ -4387,13 +4387,17 @@ async function fetchScanContext(gatewayUrl, apiKey, repo, prNumber, sha) {
4387
4387
  const headers = { "x-synkro-api-key": apiKey };
4388
4388
  const ghToken = process.env.GH_TOKEN || process.env.GITHUB_TOKEN || "";
4389
4389
  if (ghToken) headers["x-github-token"] = ghToken;
4390
+ console.log(`[scan-context] POST ${url}`);
4390
4391
  const resp = await fetch(url, {
4391
4392
  headers,
4392
4393
  signal: AbortSignal.timeout(15e3)
4393
4394
  });
4395
+ const body = await resp.text();
4396
+ console.log(`[scan-context] ${resp.status}: ${body.slice(0, 300)}`);
4394
4397
  if (!resp.ok) return { scan_all: true };
4395
- return await resp.json();
4396
- } catch {
4398
+ return JSON.parse(body);
4399
+ } catch (err) {
4400
+ console.warn(`[scan-context] error: ${err.message}`);
4397
4401
  return { scan_all: true };
4398
4402
  }
4399
4403
  }