none
SOS ! Win10/Target 1903/ MSBUILD : error MSB4166: Child node “2” RRS feed

  • Question

  • When I compile my UWP app with Target 1903 SDK.
    It make this error.

    MSBUILD : error MSB4166: Child node “2”

    Here is MSBuild_*.failure.txt.

    UNHANDLED EXCEPTIONS FROM PROCESS 9884:
    =====================
    2019/06/13 18:19:03
    System.IO.IOException: Pipe is broken
       場所 System.IO.Pipes.NamedPipeServerStream.CheckConnectOperationsServer()
       場所 System.IO.Pipes.NamedPipeServerStream.BeginWaitForConnection(AsyncCallback callback, Object state)
       場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.PacketPumpProc()
    ===================
    UNHANDLED EXCEPTIONS FROM PROCESS 18248:
    =====================
    2019/06/13 18:19:03
    System.IO.IOException: Pipe broken
       場所 System.IO.Pipes.NamedPipeServerStream.CheckConnectOperationsServer()
       場所 System.IO.Pipes.NamedPipeServerStream.BeginWaitForConnection(AsyncCallback callback, Object state)
       場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.PacketPumpProc()
    ===================
    UNHANDLED EXCEPTIONS FROM PROCESS 18964:
    =====================
    2019/06/13 20:49:46
    System.IO.IOException: Pipe is broken
       場所 System.IO.Pipes.PipeStream.CheckWriteOperations()
       場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
       場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    ===================
    UNHANDLED EXCEPTIONS FROM PROCESS 10108:
    =====================
    2019/06/13 19:53:02
    System.IO.IOException: Pipe is broken
       場所 System.IO.Pipes.PipeStream.WinIOError(Int32 errorCode)
       場所 System.IO.Pipes.PipeStream.BeginWriteCore(Byte[] buffer, Int32 offset, Int32 count, AsyncCallback callback, Object state)
       場所 System.IO.Pipes.PipeStream.WriteCore(Byte[] buffer, Int32 offset, Int32 count)
       場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
       場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    ===================


    Error happen with below condition.

    • UWP app , When I used Target = 1903(18362) SDK.
    • Windows 10 OS 1903 or 1809, I tested both. Both make same error from Visual Studio.

    I tried below.

    • Re-create new project and copy files from previous project to new one.
      Result was same : ( wow..
    • I tried different PC to compile. but It happened same result.
      this mean, Without I have to resolve this issue, I can not use 1903-Win-10... Please help...
    • Environment value "MSBUILDDISABLENODEREUSE=1", I tried. It make same error still.

    To pass the compile, I need below

    • Change back to Target = 1809 (17763). Compile work fine.
    • Windows 10 OS 1903 or 1809, I tested both. As long as I use Target=1809, It is possible to do compile

    Here is my environment.
    Visual Studio 2017 (15.9.13)
    Windows 10 Professional OS

    Here is my Visual Studio compile output : ( sorry, it's Japanese )

    1>------ ビルド開始: プロジェクト: Bg7Uwp1, 構成: Debug x64 ------
    1>MSBUILD : error MSB4166: 子ノード "2" は処理の途中で終了しました。シャットダウンしています。診断情報は "C:\Users\nakayama\AppData\Local\Temp\" のファイル内で見つかる可能性があり、MSBuild_*.failure.txt という名前になります。この場所は変更できます。変更するには、MSBUILDDEBUGPATH 環境変数を別のディレクトリに設定します。
    ========== ビルド: 0 正常終了、1 失敗、0 更新不要、0 スキップ ==========

    I also tried with Visual Studio 2019. It make same error.
    When 2019 VS, It generated this error in output

    1>------ ビルド開始: プロジェクト: Bg7Uwp1, 構成: Release x64 ------
    1>MSBUILD : error MSB4166: 子ノード "2" は処理の途中で終了しました。シャットダウンしています。診断情報は "C:\Users\nakayama\AppData\Local\Temp\" のファイル内で見つかる可能性があり、MSBuild_*.failure.txt という名前になります。この場所は変更できます。変更するには、MSBUILDDEBUGPATH 環境変数を別のディレクトリに設定します。
    1>MSBUILD : error MSB4166: C:\Users\nakayama\AppData\Local\Temp\MSBuild_pid-21904_26c2cbfa24d64814aba1093682768db8.failure.txt:
    1>MSBUILD : error MSB4166: UNHANDLED EXCEPTIONS FROM PROCESS 21904:
    1>MSBUILD : error MSB4166: =====================
    1>MSBUILD : error MSB4166: 2019/06/14 16:49:46
    1>MSBUILD : error MSB4166: System.IO.IOException: パイプが壊れています。
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WinIOError(Int32 errorCode)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.BeginWriteCore(Byte[] buffer, Int32 offset, Int32 count, AsyncCallback callback, Object state)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WriteCore(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    1>MSBUILD : error MSB4166: ===================
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: 
    ========== ビルド: 0 正常終了、1 失敗、0 更新不要、0 スキップ ==========

    Please help .



    Friday, June 14, 2019 4:25 AM

All replies

  • Hi friend,

    Welcome to MSDN forum.

    I've configured the environment and so some tests:

    Situation1: Win10 OS 1903, VS15.9.13, create a new UWP blank app and builds well

    Situation2: Win10 OS 1809, VS15.9.13, new UWP blank app and builds well

    Here are my suggestions may help:

    1.Please create a new UWP blank project to check if the build error exists.

    2.If the blank one builds well, then something in your project may cause this issue, you can moving source files from your failed project to the blank one piece by piece. After moving something, checking the project to make sure it still built. To locate this issue.

    3.If the blank one builds with failure too,  please:

    #1 Restart the PC (After first time installing the 1809 SDK, it needs a restart to take effect)

    #2 Open vs, clean and build the project again

    4. It seems you build the project in X64, try if X86 and Any CPU makes a difference

    Also, according to the error message pipe is broken, maybe pipe is the cause, you can check if the pipe makes the difference.

    In addition: Maybe you can get some help from this link.

    Hope all above helps! And if there has any update please feel free to let me know. It could be better if you can share a simple sample with same issue so that we can check it directly. (After deleting the code)

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.



    Friday, June 14, 2019 9:31 AM
  • Dear Lance

    Blank project can work without any error. I confirmed before.
    then, My project may has problem. I think so.
    But without any hint, To resolve is not easy.
    Compiler should give more hint.
    My project can work at 1809(Target). but not work at 1903(Target).
    Why ?? it should work both.

    >> If the blank one builds well, then something in your project may cause this issue, you can moving source files from your failed project to the blank one piece by piece. After moving something, checking the project to make sure it still built. To locate this issue.

    this is not so easy. We have lot of files. It is connected each other.
    To copy file one by one. MMMmm??? No. it's not possible.
    If we move a file, I also have to move connected file.
    You can understand.
    To separate file is not possible in C# Project.I need more hint to fix it from compiler.

    Please advice to output more information from MSbuild.exe.

    Why Pipe is broken ? I do not use any pipe in my code.



    Friday, June 14, 2019 9:56 AM
  • Hi, maybe you can try changing the build verbosity from minimal to detailed.

    Go Tools=>Options=>Project and Solutions=>Build and Run=> change the build output verbosity to detailed. Then rebuild the project and you can see detailed info from the build output window.


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, June 14, 2019 10:00 AM
  • I tried already. 
    Even if diagnostic log, It does not have any useful information.
    but If expert check it, He may find something...

    Here is my log.
    https://drive.google.com/file/d/19JO53hxnAia0tJ0La2DZQWKBUZVUZSGy/view?usp=sharing

    Friday, June 14, 2019 10:21 AM
  • If we wait for next release of VS update or SDK update,
    Will it fix this problem ??

    or If I do resolve now, My all UWP work go to waste ?
    My development took for 2 years. I can not stop it... : (

    PLease give me a hint.
    What is "error MSB4166" ?

    Friday, June 14, 2019 11:25 AM
  • Output has no enough information. This mean , I believe, Error come from XAML. UI arround.
    then, I investigate all imported Nuget library about UI, XAML.
    and I found a cause. At least,
    I success compile with Target 1903 with my UWP without below one.

    This library : 
    https://github.com/Herdo/AdaptiveTriggerLibrary

    This library make same error with Target 1903 compile !

    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NuGet パッケージの復元に失敗しました。警告とエラーの詳細は、[エラー一覧] ウィンドウを参照してください。
    1>------ ビルド開始: プロジェクト: AdaptiveTriggerLibrary.TryOut, 構成: Debug x86 ------
    1>MSBUILD : error MSB4166: 子ノード "2" は処理の途中で終了しました。シャットダウンしています。診断情報は "C:\Users\nakayama\AppData\Local\Temp\" のファイル内で見つかる可能性があり、MSBuild_*.failure.txt という名前になります。この場所は変更できます。変更するには、MSBUILDDEBUGPATH 環境変数を別のディレクトリに設定します。
    1>MSBUILD : error MSB4166: C:\Users\nakayama\AppData\Local\Temp\MSBuild_pid-17976_4755cc4dc7a9457f9303ad647c503063.failure.txt:
    1>MSBUILD : error MSB4166: UNHANDLED EXCEPTIONS FROM PROCESS 17976:
    1>MSBUILD : error MSB4166: =====================
    1>MSBUILD : error MSB4166: 2019/06/14 21:17:32
    1>MSBUILD : error MSB4166: System.IO.IOException: パイプが壊れています。
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WinIOError(Int32 errorCode)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.BeginWriteCore(Byte[] buffer, Int32 offset, Int32 count, AsyncCallback callback, Object state)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WriteCore(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    1>MSBUILD : error MSB4166: ===================
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: C:\Users\nakayama\AppData\Local\Temp\MSBuild_pid-18268_0f9ccb9a058544ba956e26639a72f44f.failure.txt:
    1>MSBUILD : error MSB4166: UNHANDLED EXCEPTIONS FROM PROCESS 18268:
    1>MSBUILD : error MSB4166: =====================
    1>MSBUILD : error MSB4166: 2019/06/14 21:16:20
    1>MSBUILD : error MSB4166: System.IO.IOException: パイプが壊れています。
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WinIOError(Int32 errorCode)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.BeginWriteCore(Byte[] buffer, Int32 offset, Int32 count, AsyncCallback callback, Object state)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WriteCore(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    1>MSBUILD : error MSB4166: ===================
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: C:\Users\nakayama\AppData\Local\Temp\MSBuild_pid-20076_f66164f2bd8f418e9ad6ed23bb6ec5be.failure.txt:
    1>MSBUILD : error MSB4166: UNHANDLED EXCEPTIONS FROM PROCESS 20076:
    1>MSBUILD : error MSB4166: =====================
    1>MSBUILD : error MSB4166: 2019/06/14 21:17:32
    1>MSBUILD : error MSB4166: System.IO.IOException: パイプが壊れています。
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WinIOError(Int32 errorCode)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.BeginWriteCore(Byte[] buffer, Int32 offset, Int32 count, AsyncCallback callback, Object state)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.WriteCore(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 System.IO.Pipes.PipeStream.Write(Byte[] buffer, Int32 offset, Int32 count)
    1>MSBUILD : error MSB4166:    場所 Microsoft.Build.BackEnd.NodeEndpointOutOfProcBase.RunReadLoop(Stream localReadPipe, Stream localWritePipe, ConcurrentQueue`1 localPacketQueue, AutoResetEvent localPacketAvailable, AutoResetEvent localTerminatePacketPump)
    1>MSBUILD : error MSB4166: ===================
    1>MSBUILD : error MSB4166: 
    1>MSBUILD : error MSB4166: 
    ========== ビルド: 0 正常終了、1 失敗、1 更新不要、0 スキップ ==========

    then, Solution will be following.. ( I did not try yet,  I have to go home. : )

    1. Un-install this library from Nuget. (Nuget package used ver 5.0 of Microsoft.NETCore.UniversalWindowsPlatform )
    2. Get source code. and import as project into my UWP
    3. Update "Microsoft.NETCore.UniversalWindowsPlatform" in the library project.
    4. Recompile with my UWP !

    then, Here is my advice. If someone get "MSBUILD : error MSB4166: Child node “2”,
    First, DO check all UI , XAML related nuget package. Someone maybe linked old version Nuget package of "Microsoft.NETCore.UniversalWindowsPlatform".

    I hope it will help someone ! 

    Thank you for helping ,Lance ,

    With your reply, I could keep investigate for another 3 hours !

    Kazu

    ps. I tested a bit. This library maybe max 1809. I do not know why...

    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-arm-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x64-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86 と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NU1201: プロジェクト AdaptiveTriggerLibrary は uap10.0.10240 (UAP,Version=v10.0.10240) / win10-x86-aot と互換性がありません。 プロジェクト AdaptiveTriggerLibrary がサポートするもの: uap10.0.18362 (UAP,Version=v10.0.18362)
    NuGet パッケージの復元に失敗しました。警告とエラーの詳細は、[エラー一覧] ウィンドウを参照してください。
    1>------ すべてのリビルド開始: プロジェクト:AdaptiveTriggerLibrary, 構成: Debug x64 ------
    1>D:\develop\visualstudio2\Github\AdaptiveTriggerLibrary-master\AdaptiveTriggerLibrary\Triggers\UserInterfaceTriggers\FullScreenTrigger.cs(73,31,73,44): warning CS0618: 'ApplicationView.IsFullScreen.get' は旧形式です ('To check full screen mode, use IsFullScreenMode. To check if the view is adjacent to both edges, use AdjacentToLeftDisplayEdge and AdjacentToRightDisplayEdge. For more info, see MSDN.')
    1>  AdaptiveTriggerLibrary -> D:\develop\visualstudio2\Github\AdaptiveTriggerLibrary-master\AdaptiveTriggerLibrary\bin\x64\Debug\AdaptiveTriggerLibrary.dll
    ========== すべてリビルド: 1 正常終了、0 失敗、0 スキップ ==========
    


    Friday, June 14, 2019 12:28 PM
  • Is there any way to find What line of XAML code has this error ?

    Finally, I found 2 problem Nuget library.

    1) https://github.com/Live-Charts/Live-Charts

    2https://github.com/Herdo/AdaptiveTriggerLibrary

    each code can pass compile for Target 1903.

    but When I use the library in my projejct. It make error like this.


    MSBUILD : error MSB4166: Child node “2” 


    Here is minimum project to reproduce this error. but MSBuild never provide useful information to fix it.

    https://drive.google.com/file/d/1Z9a0GadcE3Ahy1bCobt6oi0KKVHiuOMI/view?usp=sharing

    Do you have any idea why it happen ?

    Saturday, June 15, 2019 6:28 AM
  • Hello Again !

    Here is my conclusion of the cause of  MSBUILD : error MSB4166: Child node “2”
    It come from XAML. 
    in 1903 SDK, Compiler can not find a DependencyProperty if it is in base class.
    in 1809 SDK, Compiler can find it at easy !

    1) "CustomTriggerClass" extended from a Base Class.
    2) Base class extended from StateTriggerBase.
    3) Base class has a DependencyProperty.

    If we do compile this with 1809 SDK. No problem.
    if we do compile this with 1903 SDK, It make error MSB4166.

    To resolve this. I did like this.

    1) Move the DependencyProperty to Top class = "CustomTriggerClass"
    2) because Compiler can not find a DependencyProperty in base class. ( WHY ??? )

    Here is fixed project.

    https://drive.google.com/file/d/1dd1XOGB4kBNOo2NXIDpj3dGMuMFgP4uE/view?usp=sharing

    but I want to say..

    Why Microsoft change the rule of DependencyProperty ?



    Sunday, June 16, 2019 4:52 AM
  • Hi friend,

    Sorry for the delay. I've checked your first log and it seems to have something to do with XAML.

    And about the error MSB4166: child node, there are many possibilities which may cause this issue. And there is a discussion about more details about this. But it seems it is not available for UWP projects for now.

    I'm glad that you have found the workaround for this issue. And you can mark it as accepted answer for this issue. But for the original cause of the this issue, as you said it's like an issue about DependencyProperty, I have no idea why this issue happens.

    And since I can reprodcue the issue with the shared project from you, I suggest you can report this issue in VS by Help=>send feedback=>Report a problem to report this issue to product team. Thanks for your understanding and support to make VS better.

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, June 18, 2019 4:22 AM
  • Hi friend,

    It seems you've solved that issue by the workaround. You could consider marking it as accepted answer, so that other members with similar issue could easily find it. Also, then we can archive this thread for you.

    Have a nice day!

    Best Regards
    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, June 20, 2019 10:29 AM