From 97d4c5d7bea934582794ad6dc7f9ec01df2f500f Mon Sep 17 00:00:00 2001 From: unadlib Date: Fri, 13 Dec 2024 11:14:06 +0800 Subject: [PATCH] fix(cli): add fetch log --- packages/cli/src/utils/fetch.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/cli/src/utils/fetch.ts b/packages/cli/src/utils/fetch.ts index fef9f31..e415a5e 100644 --- a/packages/cli/src/utils/fetch.ts +++ b/packages/cli/src/utils/fetch.ts @@ -40,8 +40,10 @@ const fetchWithModule = async ({ }) => { if (deps[name]) return; const url = `${registry}/api/modules/${name}/releases/${version}`; + console.log('module registry fetch:', url); const response = await fetch(url); const moduleData: DepData = await response.json(); + console.log('module registry response:', moduleData); deps[name] = moduleData.variants.map((item) => ({ entry: item.remoteEntry, version: moduleData.version, @@ -95,8 +97,10 @@ export const fetchInfo = async ({ }; if (isApp) { const url = `${registry}/api/apps/${name}/releases/${version}`; + console.log('app registry fetch:', url); const response = await fetch(url); const result = await response.json(); + console.log('app registry response:', result); for (const [moduleName, moduleInfo] of Object.entries( result.dependencyLocks ) as [string, DepData][]) {