From 436c472a6e2a7a3cd735da60e4378bb52a746820 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Fri, 4 Sep 2020 14:50:34 +0800 Subject: [PATCH 01/12] add verbose info for target circular dependence --- .../BackEnd/Components/RequestBuilder/TargetBuilder.cs | 8 +++++--- .../BackEnd/Components/RequestBuilder/TaskBuilder.cs | 2 +- src/Build/Resources/Strings.resx | 7 ++++++- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs index 834d87e57b2..94e311932e6 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs @@ -677,7 +677,7 @@ private async Task PushTargets(IList targets, TargetE // continue so we could throw the exception. if (_requestEntry.RequestConfiguration.ActivelyBuildingTargets.ContainsKey(targetSpecification.TargetName)) { - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependency", targetSpecification.TargetName); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName); } } else @@ -689,7 +689,7 @@ private async Task PushTargets(IList targets, TargetE } // We are already building this target on this request. That's a circular dependency. - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependency", targetSpecification.TargetName); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName); } } else @@ -698,12 +698,14 @@ private async Task PushTargets(IList targets, TargetE if (buildReason == TargetBuiltReason.BeforeTargets || buildReason == TargetBuiltReason.DependsOn || buildReason == TargetBuiltReason.None) { TargetEntry currentParent = parentTargetEntry; + List parentChain = new List(); while (currentParent != null) { + parentChain.Add(currentParent.Name); if (String.Equals(currentParent.Name, targetSpecification.TargetName, StringComparison.OrdinalIgnoreCase)) { // We are already building this target on this request. That's a circular dependency. - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependency", targetSpecification.TargetName); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraphWithVerbosity", targetSpecification.TargetName, parentTargetEntry.Name, buildReason, string.Join("<-", parentChain)); } currentParent = currentParent.ParentEntry; diff --git a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs index d3431b4bf8c..60368e32719 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs @@ -866,7 +866,7 @@ private async Task ExecuteInstantiatedTask(ITaskExecutionHost ta else if (type == typeof(CircularDependencyException)) { _continueOnError = ContinueOnError.ErrorAndStop; - ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependency", taskLoggingContext.TargetLoggingContext.Target.Name); + ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name); } else if (type == typeof(InvalidProjectFileException)) { diff --git a/src/Build/Resources/Strings.resx b/src/Build/Resources/Strings.resx index 55a89a1db36..137e8ae11c5 100644 --- a/src/Build/Resources/Strings.resx +++ b/src/Build/Resources/Strings.resx @@ -264,11 +264,16 @@ {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target {1} has a {2} dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". {StrBegin="MSB4086: "} From 197263e4ede64e480f437fbfc8ba80e6cf28bc7f Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Fri, 4 Sep 2020 17:08:15 +0800 Subject: [PATCH 02/12] update error message --- src/Build/Resources/Strings.resx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Build/Resources/Strings.resx b/src/Build/Resources/Strings.resx index 137e8ae11c5..f4913368296 100644 --- a/src/Build/Resources/Strings.resx +++ b/src/Build/Resources/Strings.resx @@ -270,7 +270,7 @@ request a target to build itself (perhaps via a chain of other targets). - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target {1} has a {2} dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). From 5742b019dce6483fb0dc88d9d190d58a9bd990f1 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Mon, 7 Sep 2020 11:52:48 +0800 Subject: [PATCH 03/12] update xlf --- src/Build/Resources/xlf/Strings.cs.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.de.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.en.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.es.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.fr.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.it.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.ja.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.ko.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.pl.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.pt-BR.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.ru.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.tr.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.zh-Hans.xlf | 18 ++++++++++++------ src/Build/Resources/xlf/Strings.zh-Hant.xlf | 18 ++++++++++++------ 14 files changed, 168 insertions(+), 84 deletions(-) diff --git a/src/Build/Resources/xlf/Strings.cs.xlf b/src/Build/Resources/xlf/Strings.cs.xlf index 5991f465065..7320c102b32 100644 --- a/src/Build/Resources/xlf/Strings.cs.xlf +++ b/src/Build/Resources/xlf/Strings.cs.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: Elementy <Choose> nemohou být vnořeny ve více než {0} úrovních. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Existuje cyklická závislost v grafu závislosti cílů zahrnující cíl {0}. - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.de.xlf b/src/Build/Resources/xlf/Strings.de.xlf index 662d0f59824..4a0bed7b08c 100644 --- a/src/Build/Resources/xlf/Strings.de.xlf +++ b/src/Build/Resources/xlf/Strings.de.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose>-Elemente können nicht mehr als {0} Ebenen tief geschachtelt werden. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Im Zielabhängigkeitsdiagramm besteht eine Ringabhängigkeit im Zusammenhang mit dem Ziel "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.en.xlf b/src/Build/Resources/xlf/Strings.en.xlf index 9558c861f7b..343a8379cc0 100644 --- a/src/Build/Resources/xlf/Strings.en.xlf +++ b/src/Build/Resources/xlf/Strings.en.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> elements cannot be nested more than {0} levels deep. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.es.xlf b/src/Build/Resources/xlf/Strings.es.xlf index 09e2180e0a3..74e6af72c7f 100644 --- a/src/Build/Resources/xlf/Strings.es.xlf +++ b/src/Build/Resources/xlf/Strings.es.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: Los elementos <Choose> no se pueden anidar más de {0} niveles de profundidad. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Existe una dependencia circular en el gráfico de dependencias de destino en la que está involucrado el destino "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.fr.xlf b/src/Build/Resources/xlf/Strings.fr.xlf index f578b5ce53b..4067feda605 100644 --- a/src/Build/Resources/xlf/Strings.fr.xlf +++ b/src/Build/Resources/xlf/Strings.fr.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: Impossible d'imbriquer les éléments <Choose> de plus de {0} niveaux. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Il existe une dépendance circulaire dans le graphique de dépendance cible qui implique la cible "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.it.xlf b/src/Build/Resources/xlf/Strings.it.xlf index e583fca423e..f5f31c527ac 100644 --- a/src/Build/Resources/xlf/Strings.it.xlf +++ b/src/Build/Resources/xlf/Strings.it.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: il limite massimo di annidamento degli elementi <Choose> è di {0} livelli. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: è presente una dipendenza circolare nel grafico di dipendenze che usa la destinazione "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.ja.xlf b/src/Build/Resources/xlf/Strings.ja.xlf index f25b31b5d56..450bd98965a 100644 --- a/src/Build/Resources/xlf/Strings.ja.xlf +++ b/src/Build/Resources/xlf/Strings.ja.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> 要素は {0} レベル以上では入れ子にできません。 {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: ターゲット "{0}" で、ターゲット依存グラフに循環する依存関係が存在します。 - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.ko.xlf b/src/Build/Resources/xlf/Strings.ko.xlf index 79ffea47246..8e53e455087 100644 --- a/src/Build/Resources/xlf/Strings.ko.xlf +++ b/src/Build/Resources/xlf/Strings.ko.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> 요소는 {0}단계 이하로만 중첩할 수 있습니다. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: 대상 종속성 그래프에 "{0}" 대상과 관련된 순환 종속성이 있습니다. - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.pl.xlf b/src/Build/Resources/xlf/Strings.pl.xlf index 107873c75b5..5bd6bfe5808 100644 --- a/src/Build/Resources/xlf/Strings.pl.xlf +++ b/src/Build/Resources/xlf/Strings.pl.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: Elementy <Choose> nie mogą być zagnieżdżone na poziomie głębszym niż {0}. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Istnieje zależność cykliczna na wykresie zależności elementu docelowego, obejmująca element docelowy „{0}”. - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.pt-BR.xlf b/src/Build/Resources/xlf/Strings.pt-BR.xlf index dcd153df703..0b4f537d296 100644 --- a/src/Build/Resources/xlf/Strings.pt-BR.xlf +++ b/src/Build/Resources/xlf/Strings.pt-BR.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: Os elementos <Choose> não podem ser aninhados a mais de {0} níveis de profundidade. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: Há uma dependência circular no elemento gráfico de dependência circular de destino envolvendo o destino "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.ru.xlf b/src/Build/Resources/xlf/Strings.ru.xlf index eeb54ff9174..51d73186062 100644 --- a/src/Build/Resources/xlf/Strings.ru.xlf +++ b/src/Build/Resources/xlf/Strings.ru.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: уровень вложения элемента <Choose> не может превышать {0}. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: круговая зависимость между целями в графике зависимостей для цели "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.tr.xlf b/src/Build/Resources/xlf/Strings.tr.xlf index 9854cc7ddfa..58ebbf724f8 100644 --- a/src/Build/Resources/xlf/Strings.tr.xlf +++ b/src/Build/Resources/xlf/Strings.tr.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> öğeleri {0} düzeyden daha fazla iç içe geçirilemez. {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: "{0}" hedefini içeren hedef bağımlılık grafiğinde döngüsel bağımlılık var. - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.zh-Hans.xlf b/src/Build/Resources/xlf/Strings.zh-Hans.xlf index e2ca02b06c7..78f7263eb6e 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hans.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hans.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> 元素的嵌套深度不能超过 {0} 层。 {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: 涉及目标“{0}”的目标依赖项关系图中存在循环依赖项。 - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". diff --git a/src/Build/Resources/xlf/Strings.zh-Hant.xlf b/src/Build/Resources/xlf/Strings.zh-Hant.xlf index 15c7df1bd3c..6deba1cd854 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hant.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hant.xlf @@ -69,6 +69,18 @@ {StrBegin="MSB4251:"} This message is shown when a graph build detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets) + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4257: The specified output result cache file is empty. @@ -405,12 +417,6 @@ MSB4114: <Choose> 項目無法放在深於 {0} 層以上的巢狀結構中。 {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: 涉及目標 "{0}" 的目標相依性圖形中有循環相依性。 - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). MSB4086: A numeric comparison was attempted on "{1}" that evaluates to "{2}" instead of a number, in condition "{0}". From 0961dc082c144ddd78930075a66ec9945c243c52 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Mon, 7 Sep 2020 20:22:34 +0800 Subject: [PATCH 04/12] add UT --- .../BackEnd/TargetBuilder_Tests.cs | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs index 1804b8157ca..f33cbd43ea1 100644 --- a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs +++ b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs @@ -1254,6 +1254,31 @@ public void TestCircularDependencyInCallTarget() Assert.False(success); } + /// + /// Tests a circular dependency target. + /// + [Fact] + public void TestCircularDependencyTarget() + { + string projectContents = @" + + + + + + + + + + + + "; + StringReader reader = new StringReader(projectContents); + Project project = new Project(new XmlTextReader(reader), null, null); + bool success = project.Build(_mockLogger); + Assert.False(success); + } + /// /// Tests that cancel with no entries after building does not fail. /// From eb91aa5cd63b3062d7259d11af2fd1708f3e9752 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Fri, 16 Oct 2020 14:59:34 +0800 Subject: [PATCH 05/12] update error message format --- src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs | 4 ++++ .../Components/RequestBuilder/TargetBuilder.cs | 9 +++++---- src/Build/Resources/Strings.resx | 13 ++++--------- src/Build/Resources/xlf/Strings.cs.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.de.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.en.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.es.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.fr.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.it.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.ja.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.ko.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.pl.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.pt-BR.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.ru.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.tr.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.zh-Hans.xlf | 10 ++-------- src/Build/Resources/xlf/Strings.zh-Hant.xlf | 10 ++-------- 17 files changed, 41 insertions(+), 125 deletions(-) diff --git a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs index f33cbd43ea1..3e1c1dfd83f 100644 --- a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs +++ b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs @@ -1273,10 +1273,14 @@ public void TestCircularDependencyTarget() "; + string errorMessage = @"There is a circular dependency in the target dependency graph involving target ""TargetA"". Since ""TargetC"" has ""DependsOn"" dependence on ""TargetA"", the circular is TargetA<-TargetC<-TargetB<-TargetA."; + StringReader reader = new StringReader(projectContents); Project project = new Project(new XmlTextReader(reader), null, null); bool success = project.Build(_mockLogger); Assert.False(success); + Assert.Equal(1, _mockLogger.ErrorCount); + Assert.Equal(errorMessage, _mockLogger.Errors[0].Message); } /// diff --git a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs index 94e311932e6..d1f6a912f93 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs @@ -677,7 +677,7 @@ private async Task PushTargets(IList targets, TargetE // continue so we could throw the exception. if (_requestEntry.RequestConfiguration.ActivelyBuildingTargets.ContainsKey(targetSpecification.TargetName)) { - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, null); } } else @@ -689,7 +689,7 @@ private async Task PushTargets(IList targets, TargetE } // We are already building this target on this request. That's a circular dependency. - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, null); } } else @@ -698,14 +698,15 @@ private async Task PushTargets(IList targets, TargetE if (buildReason == TargetBuiltReason.BeforeTargets || buildReason == TargetBuiltReason.DependsOn || buildReason == TargetBuiltReason.None) { TargetEntry currentParent = parentTargetEntry; - List parentChain = new List(); + List parentChain = new List() { targetSpecification.TargetName }; while (currentParent != null) { parentChain.Add(currentParent.Name); if (String.Equals(currentParent.Name, targetSpecification.TargetName, StringComparison.OrdinalIgnoreCase)) { // We are already building this target on this request. That's a circular dependency. - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraphWithVerbosity", targetSpecification.TargetName, parentTargetEntry.Name, buildReason, string.Join("<-", parentChain)); + string errorMessage = $"Since \"{parentTargetEntry.Name}\" has \"{buildReason}\" dependence on \"{targetSpecification.TargetName}\", the circular is {string.Join("<-", parentChain)}."; + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, errorMessage); } currentParent = currentParent.ParentEntry; diff --git a/src/Build/Resources/Strings.resx b/src/Build/Resources/Strings.resx index f4913368296..14512ba60b0 100644 --- a/src/Build/Resources/Strings.resx +++ b/src/Build/Resources/Strings.resx @@ -265,12 +265,7 @@ LOCALIZATION: Do not localize "Choose" as it is an XML element name. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -1106,7 +1101,7 @@ LOCALIZATION: "{2}" is a localized message from a CLR/FX exception. Also, Microsoft.Build.Framework should not be localized - + MSB4181: The "{0}" task returned false but did not log an error. {StrBegin="MSB4181: "} @@ -1666,7 +1661,7 @@ Utilization: {0} Average Utilization: {1:###.0} MSB4231: ProjectRootElement can't reload if it contains unsaved changes. {StrBegin="MSB4231: "} - + The parameters have been truncated beyond this point. To view all parameters, clear the MSBUILDTRUNCATETASKINPUTLOGGING environment variable. @@ -1842,4 +1837,4 @@ Utilization: {0} Average Utilization: {1:###.0} Couldn't create an instance of IRarController for '{0}' type - + \ No newline at end of file diff --git a/src/Build/Resources/xlf/Strings.cs.xlf b/src/Build/Resources/xlf/Strings.cs.xlf index 7320c102b32..5ceb7f66bdf 100644 --- a/src/Build/Resources/xlf/Strings.cs.xlf +++ b/src/Build/Resources/xlf/Strings.cs.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.de.xlf b/src/Build/Resources/xlf/Strings.de.xlf index 4a0bed7b08c..431f0641edc 100644 --- a/src/Build/Resources/xlf/Strings.de.xlf +++ b/src/Build/Resources/xlf/Strings.de.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.en.xlf b/src/Build/Resources/xlf/Strings.en.xlf index 343a8379cc0..9ebe87a071e 100644 --- a/src/Build/Resources/xlf/Strings.en.xlf +++ b/src/Build/Resources/xlf/Strings.en.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.es.xlf b/src/Build/Resources/xlf/Strings.es.xlf index 74e6af72c7f..1808c2f6dea 100644 --- a/src/Build/Resources/xlf/Strings.es.xlf +++ b/src/Build/Resources/xlf/Strings.es.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.fr.xlf b/src/Build/Resources/xlf/Strings.fr.xlf index 4067feda605..c23508b9f40 100644 --- a/src/Build/Resources/xlf/Strings.fr.xlf +++ b/src/Build/Resources/xlf/Strings.fr.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.it.xlf b/src/Build/Resources/xlf/Strings.it.xlf index f5f31c527ac..04c002bc0c2 100644 --- a/src/Build/Resources/xlf/Strings.it.xlf +++ b/src/Build/Resources/xlf/Strings.it.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ja.xlf b/src/Build/Resources/xlf/Strings.ja.xlf index 450bd98965a..f5b6e617353 100644 --- a/src/Build/Resources/xlf/Strings.ja.xlf +++ b/src/Build/Resources/xlf/Strings.ja.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ko.xlf b/src/Build/Resources/xlf/Strings.ko.xlf index 8e53e455087..c02ce07afd4 100644 --- a/src/Build/Resources/xlf/Strings.ko.xlf +++ b/src/Build/Resources/xlf/Strings.ko.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.pl.xlf b/src/Build/Resources/xlf/Strings.pl.xlf index 5bd6bfe5808..a6577b6ef21 100644 --- a/src/Build/Resources/xlf/Strings.pl.xlf +++ b/src/Build/Resources/xlf/Strings.pl.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.pt-BR.xlf b/src/Build/Resources/xlf/Strings.pt-BR.xlf index 0b4f537d296..8b398e82525 100644 --- a/src/Build/Resources/xlf/Strings.pt-BR.xlf +++ b/src/Build/Resources/xlf/Strings.pt-BR.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ru.xlf b/src/Build/Resources/xlf/Strings.ru.xlf index 51d73186062..0244b86c755 100644 --- a/src/Build/Resources/xlf/Strings.ru.xlf +++ b/src/Build/Resources/xlf/Strings.ru.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.tr.xlf b/src/Build/Resources/xlf/Strings.tr.xlf index 58ebbf724f8..278557310ad 100644 --- a/src/Build/Resources/xlf/Strings.tr.xlf +++ b/src/Build/Resources/xlf/Strings.tr.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.zh-Hans.xlf b/src/Build/Resources/xlf/Strings.zh-Hans.xlf index 78f7263eb6e..9f747f5e7f0 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hans.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hans.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.zh-Hant.xlf b/src/Build/Resources/xlf/Strings.zh-Hant.xlf index 6deba1cd854..8cef41e0501 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hant.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hant.xlf @@ -71,14 +71,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot - request a target to build itself (perhaps via a chain of other targets). - - - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Target "{1}" has a "{2}" dependency on it, but it is depended upon by {3}. + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). From 28d28dcc6285fe4f0f301962c5d4acbcb4e165ff Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Fri, 16 Oct 2020 15:22:26 +0800 Subject: [PATCH 06/12] resolve conflicts --- src/Build/Resources/Strings.resx | 60 ++++++++++++++++---------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/src/Build/Resources/Strings.resx b/src/Build/Resources/Strings.resx index 14512ba60b0..1b3947ad23e 100644 --- a/src/Build/Resources/Strings.resx +++ b/src/Build/Resources/Strings.resx @@ -1,17 +1,17 @@  - @@ -1101,7 +1101,7 @@ LOCALIZATION: "{2}" is a localized message from a CLR/FX exception. Also, Microsoft.Build.Framework should not be localized - + MSB4181: The "{0}" task returned false but did not log an error. {StrBegin="MSB4181: "} @@ -1661,7 +1661,7 @@ Utilization: {0} Average Utilization: {1:###.0} MSB4231: ProjectRootElement can't reload if it contains unsaved changes. {StrBegin="MSB4231: "} - + The parameters have been truncated beyond this point. To view all parameters, clear the MSBUILDTRUNCATETASKINPUTLOGGING environment variable. @@ -1837,4 +1837,4 @@ Utilization: {0} Average Utilization: {1:###.0} Couldn't create an instance of IRarController for '{0}' type - \ No newline at end of file + From 87302fa74474d99a2d843c3c44526757206c73ae Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Wed, 18 Nov 2020 13:05:09 +0800 Subject: [PATCH 07/12] Apply suggestions from code review Co-authored-by: Forgind Co-authored-by: Ben Villalobos <4691428+BenVillalobos@users.noreply.github.com> --- src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs | 7 +++---- src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs index 3e1c1dfd83f..1dab221fe0a 100644 --- a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs +++ b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs @@ -1277,10 +1277,9 @@ public void TestCircularDependencyTarget() StringReader reader = new StringReader(projectContents); Project project = new Project(new XmlTextReader(reader), null, null); - bool success = project.Build(_mockLogger); - Assert.False(success); - Assert.Equal(1, _mockLogger.ErrorCount); - Assert.Equal(errorMessage, _mockLogger.Errors[0].Message); + project.Build(_mockLogger).ShouldBeFalse(); + mockLogger.ErrorCount.ShouldBe(1); + mockLogger.Errors[0].Message.ShouldBe(errorMessage); } /// diff --git a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs index 60368e32719..c188f3e1ef7 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs @@ -866,7 +866,7 @@ private async Task ExecuteInstantiatedTask(ITaskExecutionHost ta else if (type == typeof(CircularDependencyException)) { _continueOnError = ContinueOnError.ErrorAndStop; - ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name); + ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name, null); } else if (type == typeof(InvalidProjectFileException)) { From a21241d7a658381a17885323ec23277b81c8aa50 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Sat, 5 Dec 2020 22:00:22 +0800 Subject: [PATCH 08/12] Add CircularDependencyInTargetGraph with same error code to show the circular dependence --- .../BackEnd/TargetBuilder_Tests.cs | 6 +- .../RequestBuilder/TargetBuilder.cs | 51 ++++++++---- src/Build/Resources/Strings.resx | 80 ++++++++++++------- src/Build/Resources/xlf/Strings.cs.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.de.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.en.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.es.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.fr.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.it.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.ja.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.ko.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.pl.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.pt-BR.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.ru.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.tr.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.zh-Hans.xlf | 34 ++++++-- src/Build/Resources/xlf/Strings.zh-Hant.xlf | 34 ++++++-- 17 files changed, 467 insertions(+), 146 deletions(-) diff --git a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs index 1dab221fe0a..dbddb7b9d39 100644 --- a/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs +++ b/src/Build.UnitTests/BackEnd/TargetBuilder_Tests.cs @@ -1273,13 +1273,13 @@ public void TestCircularDependencyTarget() "; - string errorMessage = @"There is a circular dependency in the target dependency graph involving target ""TargetA"". Since ""TargetC"" has ""DependsOn"" dependence on ""TargetA"", the circular is TargetA<-TargetC<-TargetB<-TargetA."; + string errorMessage = @"There is a circular dependency in the target dependency graph involving target ""TargetA"". Since ""TargetC"" has ""DependsOn"" dependence on ""TargetA"", the circular is ""TargetA<-TargetC<-TargetB<-TargetA""."; StringReader reader = new StringReader(projectContents); Project project = new Project(new XmlTextReader(reader), null, null); project.Build(_mockLogger).ShouldBeFalse(); - mockLogger.ErrorCount.ShouldBe(1); - mockLogger.Errors[0].Message.ShouldBe(errorMessage); + _mockLogger.ErrorCount.ShouldBe(1); + _mockLogger.Errors[0].Message.ShouldBe(errorMessage); } /// diff --git a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs index d1f6a912f93..3b12ddb341d 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs @@ -677,7 +677,7 @@ private async Task PushTargets(IList targets, TargetE // continue so we could throw the exception. if (_requestEntry.RequestConfiguration.ActivelyBuildingTargets.ContainsKey(targetSpecification.TargetName)) { - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, null); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependency", targetSpecification.TargetName); } } else @@ -689,7 +689,7 @@ private async Task PushTargets(IList targets, TargetE } // We are already building this target on this request. That's a circular dependency. - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, null); + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependency", targetSpecification.TargetName); } } else @@ -697,19 +697,10 @@ private async Task PushTargets(IList targets, TargetE // Does this target exist in our direct parent chain, if it is a before target (since these can cause circular dependency issues) if (buildReason == TargetBuiltReason.BeforeTargets || buildReason == TargetBuiltReason.DependsOn || buildReason == TargetBuiltReason.None) { - TargetEntry currentParent = parentTargetEntry; - List parentChain = new List() { targetSpecification.TargetName }; - while (currentParent != null) + List targetDependenceChain; + if (HasCircularDependenceInTargets(parentTargetEntry, targetSpecification, out targetDependenceChain)) { - parentChain.Add(currentParent.Name); - if (String.Equals(currentParent.Name, targetSpecification.TargetName, StringComparison.OrdinalIgnoreCase)) - { - // We are already building this target on this request. That's a circular dependency. - string errorMessage = $"Since \"{parentTargetEntry.Name}\" has \"{buildReason}\" dependence on \"{targetSpecification.TargetName}\", the circular is {string.Join("<-", parentChain)}."; - ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, errorMessage); - } - - currentParent = currentParent.ParentEntry; + ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, parentTargetEntry.Name, buildReason, targetSpecification.TargetName, string.Join("<-", targetDependenceChain)); } } else @@ -815,5 +806,37 @@ private void ComputeAfterTargetFailures(string[] targetNames) } } } + + private bool HasCircularDependenceInTargets(TargetEntry parentTargetEntry, TargetSpecification targetSpecification, out List circularDependenceChain) + { + TargetEntry currentParent = parentTargetEntry; + circularDependenceChain = new List(); + bool hasCircularDependence = false; + + while (currentParent != null) + { + if (String.Equals(currentParent.Name, targetSpecification.TargetName, StringComparison.OrdinalIgnoreCase)) + { + // We are already building this target on this request. That's a circular dependency. + hasCircularDependence = true; + + // Cache the circular dependence chain only when circular dependency occurs. + currentParent = parentTargetEntry; + circularDependenceChain.Add(targetSpecification.TargetName); + while (!String.Equals(currentParent.Name, targetSpecification.TargetName, StringComparison.OrdinalIgnoreCase)) + { + circularDependenceChain.Add(currentParent.Name); + currentParent = currentParent.ParentEntry; + } + + circularDependenceChain.Add(currentParent.Name); + break; + } + + currentParent = currentParent.ParentEntry; + } + + return hasCircularDependence; + } } } diff --git a/src/Build/Resources/Strings.resx b/src/Build/Resources/Strings.resx index 1b3947ad23e..aaf104c7040 100644 --- a/src/Build/Resources/Strings.resx +++ b/src/Build/Resources/Strings.resx @@ -1,17 +1,17 @@  - @@ -264,8 +264,13 @@ {StrBegin="MSB4114: "}UE: This message appears if the project file contains unreasonably nested Choose elements. LOCALIZATION: Do not localize "Choose" as it is an XML element name. + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). + - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -313,6 +318,18 @@ t2.targets and t2.targets tries to import t1.targets, then it results in a circular dependency. + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + Search paths being used for {0} are {1} @@ -478,6 +495,10 @@ MSB4110: Expected a property at position {1} in condition "{0}". Did you forget the opening parenthesis after the '$'? To use a literal '$', use '%24' instead. {StrBegin="MSB4110: "} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4101: Expected a closing quote after position {1} in condition "{0}". {StrBegin="MSB4101: "} @@ -1834,7 +1855,4 @@ Utilization: {0} Average Utilization: {1:###.0} "EvaluationContext objects created with SharingPolicy.Isolated do not support being passed an MSBuildFileSystemBase file system." - - Couldn't create an instance of IRarController for '{0}' type - diff --git a/src/Build/Resources/xlf/Strings.cs.xlf b/src/Build/Resources/xlf/Strings.cs.xlf index 5ceb7f66bdf..ee3105fd255 100644 --- a/src/Build/Resources/xlf/Strings.cs.xlf +++ b/src/Build/Resources/xlf/Strings.cs.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Při zápisu do výstupních souborů mezipaměti pro výsledky v cestě {0} byla zjištěna chyba: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Následující vstupní soubory mezipaměti pro výsledky neexistují: {0} @@ -184,11 +209,6 @@ Počáteční hodnota vlastnosti: $({0})={1} Zdroj: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: Projekt {0} přeskočil omezení izolace grafu v odkazovaném projektu {1}. diff --git a/src/Build/Resources/xlf/Strings.de.xlf b/src/Build/Resources/xlf/Strings.de.xlf index 431f0641edc..d92f68b7277 100644 --- a/src/Build/Resources/xlf/Strings.de.xlf +++ b/src/Build/Resources/xlf/Strings.de.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Beim Schreiben der Cachedatei für Ausgabeergebnisse im Pfad "{0}" wurde ein Fehler festgestellt: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Die folgenden Cachedateien für Eingabeergebnisse sind nicht vorhanden: "{0}" @@ -184,11 +209,6 @@ Anfangswert der Eigenschaft: $({0})="{1}", Quelle: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: Das Projekt "{0}" hat Graphisolationseinschränkungen für das referenzierte Projekt "{1}" übersprungen. diff --git a/src/Build/Resources/xlf/Strings.en.xlf b/src/Build/Resources/xlf/Strings.en.xlf index 9ebe87a071e..62def2d02ff 100644 --- a/src/Build/Resources/xlf/Strings.en.xlf +++ b/src/Build/Resources/xlf/Strings.en.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Writing output result cache file in path "{0}" encountered an error: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: The following input result cache files do not exist: "{0}" @@ -184,11 +209,6 @@ Property initial value: $({0})="{1}" Source: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" diff --git a/src/Build/Resources/xlf/Strings.es.xlf b/src/Build/Resources/xlf/Strings.es.xlf index 1808c2f6dea..c9febb7e414 100644 --- a/src/Build/Resources/xlf/Strings.es.xlf +++ b/src/Build/Resources/xlf/Strings.es.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Error al escribir el archivo de caché de resultados de salida en la ruta de acceso "{0}": {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Los siguientes archivos de caché de resultados de entrada no existen: "{0}" @@ -184,11 +209,6 @@ Valor inicial de la propiedad: $({0})="{1}" Origen: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: El proyecto "{0}" ha omitido las restricciones de aislamiento de gráficos en el proyecto "{1}" al que se hace referencia. diff --git a/src/Build/Resources/xlf/Strings.fr.xlf b/src/Build/Resources/xlf/Strings.fr.xlf index c23508b9f40..0bec7fe9f11 100644 --- a/src/Build/Resources/xlf/Strings.fr.xlf +++ b/src/Build/Resources/xlf/Strings.fr.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: L'écriture du fichier cache des résultats de sortie dans le chemin "{0}" a rencontré une erreur : {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Les fichiers cache des résultats d'entrée suivants n'existent pas : "{0}" @@ -184,11 +209,6 @@ Valeur initiale de la propriété : $({0})="{1}" Source : {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: le projet "{0}" a ignoré les contraintes d'isolement de graphe dans le projet référencé "{1}" diff --git a/src/Build/Resources/xlf/Strings.it.xlf b/src/Build/Resources/xlf/Strings.it.xlf index 04c002bc0c2..22caa33cf79 100644 --- a/src/Build/Resources/xlf/Strings.it.xlf +++ b/src/Build/Resources/xlf/Strings.it.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: durante la scrittura del file della cache dei risultati di output nel percorso "{0}" è stato rilevato un errore: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: i file della cache dei risultati di input seguenti non esistono: "{0}" @@ -184,11 +209,6 @@ Valore iniziale della proprietà: $({0})="{1}". Origine: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: il progetto "{0}" ha ignorato i vincoli di isolamento del grafico nel progetto di riferimento "{1}" diff --git a/src/Build/Resources/xlf/Strings.ja.xlf b/src/Build/Resources/xlf/Strings.ja.xlf index f5b6e617353..e44f1dc246c 100644 --- a/src/Build/Resources/xlf/Strings.ja.xlf +++ b/src/Build/Resources/xlf/Strings.ja.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: パス "{0}" の出力結果キャッシュ ファイルに書き込む処理でエラーが発生しました: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: 以下の入力結果キャッシュ ファイルが存在しません: "{0}" @@ -184,11 +209,6 @@ プロパティの初期値: $({0})="{1}" ソース: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: プロジェクト "{0}" は、参照先のプロジェクト "{1}" で、グラフの分離制約をスキップしました diff --git a/src/Build/Resources/xlf/Strings.ko.xlf b/src/Build/Resources/xlf/Strings.ko.xlf index c02ce07afd4..6268f332f3b 100644 --- a/src/Build/Resources/xlf/Strings.ko.xlf +++ b/src/Build/Resources/xlf/Strings.ko.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: "{0}" 경로에서 출력 결과 캐시 파일을 쓰는 중 오류가 발생했습니다. {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: 다음 입력 결과 캐시 파일이 존재하지 않습니다. "{0}" @@ -184,11 +209,6 @@ 속성 초기 값: $({0})="{1}" 소스: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: 프로젝트 "{0}"에서 참조된 프로젝트 "{1}"의 그래프 격리 제약 조건을 건너뛰었습니다. diff --git a/src/Build/Resources/xlf/Strings.pl.xlf b/src/Build/Resources/xlf/Strings.pl.xlf index a6577b6ef21..404a2257da9 100644 --- a/src/Build/Resources/xlf/Strings.pl.xlf +++ b/src/Build/Resources/xlf/Strings.pl.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Podczas zapisywania pliku wyjściowej pamięci podręcznej wyników w ścieżce „{0}” wystąpił błąd: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Następujące pliki wejściowej pamięci podręcznej wyników nie istnieją: „{0}” @@ -184,11 +209,6 @@ Wartość początkowa właściwości: $({0})=„{1}” Źródło: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: W przypadku projektu „{0}” pominięto ograniczenia izolacji grafu dla przywoływanego projektu „{1}” diff --git a/src/Build/Resources/xlf/Strings.pt-BR.xlf b/src/Build/Resources/xlf/Strings.pt-BR.xlf index 8b398e82525..fb92ab880b0 100644 --- a/src/Build/Resources/xlf/Strings.pt-BR.xlf +++ b/src/Build/Resources/xlf/Strings.pt-BR.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: a gravação do arquivo de cache do resultado de saída no caminho "{0}" encontrou um erro: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: os arquivos de cache do resultado de entrada a seguir não existem: "{0}" @@ -184,11 +209,6 @@ Valor inicial da propriedade: $({0})="{1}" Origem: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: o projeto "{0}" ignorou as restrições de isolamento do gráfico no projeto referenciado "{1}" diff --git a/src/Build/Resources/xlf/Strings.ru.xlf b/src/Build/Resources/xlf/Strings.ru.xlf index 0244b86c755..9569c56204a 100644 --- a/src/Build/Resources/xlf/Strings.ru.xlf +++ b/src/Build/Resources/xlf/Strings.ru.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: произошла ошибка при записи выходного файла кэша результатов в пути "{0}": {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: следующие входные файлы кэша результатов не существуют: "{0}" @@ -184,11 +209,6 @@ Начальное значение свойства: $({0})="{1}" Источник: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: проект "{0}" пропустил ограничения изоляции графа в проекте "{1}", на который указывает ссылка. diff --git a/src/Build/Resources/xlf/Strings.tr.xlf b/src/Build/Resources/xlf/Strings.tr.xlf index 278557310ad..46806d5bdda 100644 --- a/src/Build/Resources/xlf/Strings.tr.xlf +++ b/src/Build/Resources/xlf/Strings.tr.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: Çıkış sonucu önbellek dosyası "{0}" yoluna yazılırken bir hatayla karşılaşıldı: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: Şu giriş sonucu önbellek dosyaları mevcut değil: "{0}" @@ -184,11 +209,6 @@ Özellik başlangıç değeri: $({0})="{1}" Kaynak: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: "{0}" projesi, başvurulan "{1}" projesindeki graf yalıtımı kısıtlamalarını atladı diff --git a/src/Build/Resources/xlf/Strings.zh-Hans.xlf b/src/Build/Resources/xlf/Strings.zh-Hans.xlf index 9f747f5e7f0..81b150b12c2 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hans.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hans.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: 从路径“{0}”写入输出结果缓存文件时遇到错误: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: 以下输入结果缓存文件不存在:“{0}” @@ -184,11 +209,6 @@ 属性初始值: $({0})=“{1}”,源: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: 项目“{0}”已跳过所引用的项目“{1}”上的图形隔离约束 diff --git a/src/Build/Resources/xlf/Strings.zh-Hant.xlf b/src/Build/Resources/xlf/Strings.zh-Hant.xlf index 8cef41e0501..a551307110c 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hant.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hant.xlf @@ -61,6 +61,26 @@ {StrBegin="MSB4248: "}UE: This message is shown when metadata cannot be expanded in an expression for some reason e.g. trying to apply %(RootDir) to an item-spec that's not a valid path would result in this error. LOCALIZATION: "{1}" is a localized message explaining the problem. + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to an invalid format. Enabling all change wave versions. Entered value: {0}. + + Value should be of the format: xx.yy + + + + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + Environment variable MSBUILDDISABLEFEATURESFROMVERSION is set to a version that is out of rotation. Defaulting to Change Wave version: {0}. Entered value: {1}. + + Refer to https://github.com/dotnet/msbuild/tree/master/documentation/wiki/ChangeWaves.md to see what the current Change Waves are. + + + + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot + request a target to build itself (perhaps via a chain of other targets). MSB4251: There is a circular dependency involving the following projects: {0} @@ -71,8 +91,8 @@ - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". {1} + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". + MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". Since "{1}" has "{2}" dependence on "{3}", the circular is "{4}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). @@ -96,6 +116,11 @@ MSB4258: 在路徑 "{0}" 中寫入輸出結果快取檔案發生錯誤: {1} + + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + MSB4259: Unexpected space at position "{1}" of condition "{0}". Did you forget to remove a space? + {StrBegin="MSB4259: "} + MSB4255: The following input result cache files do not exist: "{0}" MSB4255: 下列輸入結果快取檔案不存在: "{0}" @@ -184,11 +209,6 @@ 屬性初始值: $({0})="{1}" 來源: {2} - - Couldn't create an instance of IRarController for '{0}' type - Couldn't create an instance of IRarController for '{0}' type - - MSB4260: Project "{0}" skipped graph isolation constraints on referenced project "{1}" MSB4260: 專案 "{0}" 已跳過參考專案 "{1}" 上的圖形隔離條件約束 From 8323608398c48976efc54a9b10f5cebc6491a24a Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Sun, 6 Dec 2020 15:00:00 +0800 Subject: [PATCH 09/12] revert changes in TaskBuilder --- src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs index c188f3e1ef7..60368e32719 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs @@ -866,7 +866,7 @@ private async Task ExecuteInstantiatedTask(ITaskExecutionHost ta else if (type == typeof(CircularDependencyException)) { _continueOnError = ContinueOnError.ErrorAndStop; - ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name, null); + ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name); } else if (type == typeof(InvalidProjectFileException)) { From 791ba899f8697c75eedc511dd367bb1f9957413c Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Sun, 6 Dec 2020 15:04:15 +0800 Subject: [PATCH 10/12] revert changes in TaskBuilder --- src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs index 60368e32719..d3431b4bf8c 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TaskBuilder.cs @@ -866,7 +866,7 @@ private async Task ExecuteInstantiatedTask(ITaskExecutionHost ta else if (type == typeof(CircularDependencyException)) { _continueOnError = ContinueOnError.ErrorAndStop; - ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependencyInTargetGraph", taskLoggingContext.TargetLoggingContext.Target.Name); + ProjectErrorUtilities.ThrowInvalidProject(taskLoggingContext.Task.Location, "CircularDependency", taskLoggingContext.TargetLoggingContext.Target.Name); } else if (type == typeof(InvalidProjectFileException)) { From 0981570aac92b477604dfd28405d60c92b1ee55d Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Sun, 6 Dec 2020 16:19:34 +0800 Subject: [PATCH 11/12] revert bad changes caused by merge conflicts --- src/Build/Resources/xlf/Strings.cs.xlf | 2 +- src/Build/Resources/xlf/Strings.de.xlf | 2 +- src/Build/Resources/xlf/Strings.es.xlf | 2 +- src/Build/Resources/xlf/Strings.fr.xlf | 2 +- src/Build/Resources/xlf/Strings.it.xlf | 2 +- src/Build/Resources/xlf/Strings.ja.xlf | 2 +- src/Build/Resources/xlf/Strings.ko.xlf | 2 +- src/Build/Resources/xlf/Strings.pl.xlf | 2 +- src/Build/Resources/xlf/Strings.pt-BR.xlf | 2 +- src/Build/Resources/xlf/Strings.ru.xlf | 2 +- src/Build/Resources/xlf/Strings.tr.xlf | 2 +- src/Build/Resources/xlf/Strings.zh-Hans.xlf | 2 +- src/Build/Resources/xlf/Strings.zh-Hant.xlf | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/Build/Resources/xlf/Strings.cs.xlf b/src/Build/Resources/xlf/Strings.cs.xlf index 15ab5476813..af5343f913c 100644 --- a/src/Build/Resources/xlf/Strings.cs.xlf +++ b/src/Build/Resources/xlf/Strings.cs.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Existuje cyklická závislost v grafu závislosti cílů zahrnující cíl {0}. {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.de.xlf b/src/Build/Resources/xlf/Strings.de.xlf index 28649ac318f..3f37e151f5f 100644 --- a/src/Build/Resources/xlf/Strings.de.xlf +++ b/src/Build/Resources/xlf/Strings.de.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Im Zielabhängigkeitsdiagramm besteht eine Ringabhängigkeit im Zusammenhang mit dem Ziel "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.es.xlf b/src/Build/Resources/xlf/Strings.es.xlf index fb6e4db24da..e5ae9cf06fa 100644 --- a/src/Build/Resources/xlf/Strings.es.xlf +++ b/src/Build/Resources/xlf/Strings.es.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Existe una dependencia circular en el gráfico de dependencias de destino en la que está involucrado el destino "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.fr.xlf b/src/Build/Resources/xlf/Strings.fr.xlf index 2d0a5876e53..43b1e5d1a62 100644 --- a/src/Build/Resources/xlf/Strings.fr.xlf +++ b/src/Build/Resources/xlf/Strings.fr.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Il existe une dépendance circulaire dans le graphique de dépendance cible qui implique la cible "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.it.xlf b/src/Build/Resources/xlf/Strings.it.xlf index f1e27155bb2..b5b73d827fa 100644 --- a/src/Build/Resources/xlf/Strings.it.xlf +++ b/src/Build/Resources/xlf/Strings.it.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: è presente una dipendenza circolare nel grafico di dipendenze che usa la destinazione "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ja.xlf b/src/Build/Resources/xlf/Strings.ja.xlf index 55fd8ceb9e1..9c1883c241d 100644 --- a/src/Build/Resources/xlf/Strings.ja.xlf +++ b/src/Build/Resources/xlf/Strings.ja.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: ターゲット "{0}" で、ターゲット依存グラフに循環する依存関係が存在します。 {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ko.xlf b/src/Build/Resources/xlf/Strings.ko.xlf index 5e73607e7fc..5f8b1d179d3 100644 --- a/src/Build/Resources/xlf/Strings.ko.xlf +++ b/src/Build/Resources/xlf/Strings.ko.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: 대상 종속성 그래프에 "{0}" 대상과 관련된 순환 종속성이 있습니다. {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.pl.xlf b/src/Build/Resources/xlf/Strings.pl.xlf index b1813b67089..f645019bccd 100644 --- a/src/Build/Resources/xlf/Strings.pl.xlf +++ b/src/Build/Resources/xlf/Strings.pl.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Istnieje zależność cykliczna na wykresie zależności elementu docelowego, obejmująca element docelowy „{0}”. {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.pt-BR.xlf b/src/Build/Resources/xlf/Strings.pt-BR.xlf index a41206eea8e..0e7308fdf0e 100644 --- a/src/Build/Resources/xlf/Strings.pt-BR.xlf +++ b/src/Build/Resources/xlf/Strings.pt-BR.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: Há uma dependência circular no elemento gráfico de dependência circular de destino envolvendo o destino "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.ru.xlf b/src/Build/Resources/xlf/Strings.ru.xlf index 7d0bbda5135..ad19ccbfbfe 100644 --- a/src/Build/Resources/xlf/Strings.ru.xlf +++ b/src/Build/Resources/xlf/Strings.ru.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: круговая зависимость между целями в графике зависимостей для цели "{0}". {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.tr.xlf b/src/Build/Resources/xlf/Strings.tr.xlf index 1159b646c12..ba72165a10f 100644 --- a/src/Build/Resources/xlf/Strings.tr.xlf +++ b/src/Build/Resources/xlf/Strings.tr.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: "{0}" hedefini içeren hedef bağımlılık grafiğinde döngüsel bağımlılık var. {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.zh-Hans.xlf b/src/Build/Resources/xlf/Strings.zh-Hans.xlf index db8a53f8c98..3529f8664a8 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hans.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hans.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: 涉及目标“{0}”的目标依赖项关系图中存在循环依赖项。 {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). diff --git a/src/Build/Resources/xlf/Strings.zh-Hant.xlf b/src/Build/Resources/xlf/Strings.zh-Hant.xlf index 544ba52c464..eba950ac5c2 100644 --- a/src/Build/Resources/xlf/Strings.zh-Hant.xlf +++ b/src/Build/Resources/xlf/Strings.zh-Hant.xlf @@ -78,7 +78,7 @@ MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". - MSB4006: There is a circular dependency in the target dependency graph involving target "{0}". + MSB4006: 涉及目標 "{0}" 的目標相依性圖形中有循環相依性。 {StrBegin="MSB4006: "}UE: This message is shown when the build engine detects a target referenced in a circular manner -- a project cannot request a target to build itself (perhaps via a chain of other targets). From ead5b8586a42e2b6c69ef75ea6b3755064360901 Mon Sep 17 00:00:00 2001 From: Haiyu Zhu Date: Tue, 15 Dec 2020 17:12:07 +0800 Subject: [PATCH 12/12] add type to out keywords Co-authored-by: Forgind --- src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs index 3b12ddb341d..d79147775b7 100644 --- a/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs +++ b/src/Build/BackEnd/Components/RequestBuilder/TargetBuilder.cs @@ -697,8 +697,7 @@ private async Task PushTargets(IList targets, TargetE // Does this target exist in our direct parent chain, if it is a before target (since these can cause circular dependency issues) if (buildReason == TargetBuiltReason.BeforeTargets || buildReason == TargetBuiltReason.DependsOn || buildReason == TargetBuiltReason.None) { - List targetDependenceChain; - if (HasCircularDependenceInTargets(parentTargetEntry, targetSpecification, out targetDependenceChain)) + if (HasCircularDependenceInTargets(parentTargetEntry, targetSpecification, out List targetDependenceChain)) { ProjectErrorUtilities.ThrowInvalidProject(targetLocation, "CircularDependencyInTargetGraph", targetSpecification.TargetName, parentTargetEntry.Name, buildReason, targetSpecification.TargetName, string.Join("<-", targetDependenceChain)); }