File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -767,8 +767,7 @@ private bool CheckFeeds(out HashSet<string> explicitFeeds, out HashSet<string> a
767767 /// <returns>True if all feeds are reachable or false otherwise.</returns>
768768 private bool CheckSpecifiedFeeds ( HashSet < string > feeds )
769769 {
770- logger . LogInfo ( "Checking that NuGet feeds are reachable..." ) ;
771-
770+ // Exclude any feeds that are configured by the corresponding environment variable.
772771 var excludedFeeds = EnvironmentVariables . GetURLs ( EnvironmentVariableNames . ExcludedNugetFeedsFromResponsivenessCheck )
773772 . ToHashSet ( ) ;
774773
@@ -777,9 +776,10 @@ private bool CheckSpecifiedFeeds(HashSet<string> feeds)
777776 logger . LogInfo ( $ "Excluded NuGet feeds from responsiveness check: { string . Join ( ", " , excludedFeeds . OrderBy ( f => f ) ) } ") ;
778777 }
779778
780- var ( initialTimeout , tryCount ) = GetFeedRequestSettings ( isFallback : false ) ;
779+ var feedsToCheck = feeds . Where ( feed => ! excludedFeeds . Contains ( feed ) ) . ToHashSet ( ) ;
780+ var reachableFeeds = this . GetReachableNuGetFeeds ( feedsToCheck , isFallback : false ) ;
781+ var allFeedsReachable = reachableFeeds . Count == feedsToCheck . Count ;
781782
782- var allFeedsReachable = feeds . All ( feed => excludedFeeds . Contains ( feed ) || IsFeedReachable ( feed , initialTimeout , tryCount ) ) ;
783783 if ( ! allFeedsReachable )
784784 {
785785 logger . LogWarning ( "Found unreachable NuGet feed in C# analysis with build-mode 'none'. This may cause missing dependencies in the analysis." ) ;
You can’t perform that action at this time.
0 commit comments