diff --git a/dist/index.js b/dist/index.js index 8c745f3f7..10098d294 100644 --- a/dist/index.js +++ b/dist/index.js @@ -5161,7 +5161,9 @@ function findMatch(versionSpec, stable) { core.debug(`matched ${candidate.version}`); match = candidate; break; - } + } else { + core.debug(`version statisfied ${candidateversion}, but coulnd't find supported platform and/or architecture`); + } } } if (match && goFile) { diff --git a/src/installer.ts b/src/installer.ts index 0e0d5d399..42b9e98fe 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -210,11 +210,17 @@ export async function findMatch( version = version + '.0'; } - core.debug(`check ${version} satisfies ${versionSpec}`); - if ( - semver.satisfies(version, versionSpec) && - (!stable || candidate.stable === stable) - ) { + let satisfied = semver.satisfies(version, versionSpec); + + if(!satisfied) { + core.debug(`${version} doesn't satisfy ${versionSpec}`); + continue; + } + + core.debug(`${version} does satisfy ${versionSpec}`); + + if (!stable || candidate.stable === stable) + { goFile = candidate.files.find(file => { core.debug( `${file.arch}===${archFilter} && ${file.os}===${platFilter}`