Search Unity

"Failed to run serialization weaver with command" error

Discussion in 'Windows' started by scbundy, Jun 20, 2015.

  1. scbundy

    scbundy

    Joined:
    May 23, 2014
    Posts:
    51
    Hi everyone, my game compiled fine with 5.0.1. But I just upgraded Unity to 5.1.1 and now I'm getting a compile error when I try to build for Windows Store (compiles fine for Windows x86). Is anyone else seeing thiss upgrading to 5.1.1?

    UnityException: Failed to run serialization weaver with command "Temp\StagingArea\LetterFarm.Windows\Data\Managed\UnityEngine.Networking.dll" -pdb -verbose -unity-engine=Temp\StagingArea\LetterFarm.Windows\Data\Managed\UnityEngine.dll "Temp\StagingArea\LetterFarm.Windows\TempSerializationWeaver".
    Symbols will be read from Temp\StagingArea\LetterFarm.Windows\Data\Managed\UnityEngine.pdb
    Weaving assembly E:\Letter Farm\Temp\StagingArea\LetterFarm.Windows\Data\Managed\UnityEngine.Networking.dll
    No symbols for Temp\StagingArea\LetterFarm.Windows\Data\Managed\UnityEngine.Networking.dll
    + UnityEngine.Networking.NetworkAnimator
    + UnityEngine.Networking.NetworkBehaviour
    + UnityEngine.Networking.NetworkHash128
    + UnityEngine.Networking.NetworkIdentity
    + UnityEngine.Networking.NetworkInstanceId
    Mono.Cecil.ResolutionException: Failed to resolve UnityEngine.Networking.ConnectionConfig
    at Unity.CecilTools.Extensions.ResolutionExtensions.Resolve[TReference,TDefinition](TReference reference, Func`2 resolve)
    at Unity.CecilTools.Extensions.TypeReferenceExtensions.IsAssignableTo(TypeReference typeRef, String typeName)
    at Unity.SerializationLogic.UnitySerializationLogic.IsTypeSerializable(TypeReference typeReference)
    at Unity.SerializationLogic.UnitySerializationLogic.IsFieldTypeSerializable(TypeReference typeReference)
    at Unity.SerializationLogic.UnitySerializationLogic.WillUnitySerialize(FieldDefinition fieldDefinition, TypeResolver typeResolver)
    at Unity.Serialization.Weaver.MethodEmitterBase.WillUnitySerialize(FieldDefinition fieldDefinition)
    at Unity.Serialization.Weaver.SerializeMethodEmitter.ShouldProcess(FieldDefinition fieldDefinition)
    at System.Linq.Enumerable.<>c__DisplayClassf`1.<CombinePredicates>b__e(TSource x)
    at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
    at Unity.Serialization.Weaver.MethodEmitterBase.EmitMethodBody()
    at Unity.Serialization.Weaver.SerializationWeaver.AddSerializeMethod()
    at Unity.Serialization.Weaver.SerializationWeaver.Weave()
    at usw.Weaver.WeaveAssembly(String assemblyPath, AssemblyDefinition unityEngineAssemblyDefinition)
    at usw.Weaver.Weave()
    at usw.Program.RunProgram(ConversionOptions options)
    at usw.Program.Main(String[] args)

    PostProcessWinRT.RunSerializationWeaver () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:372)
    PostProcessUniversal81.RunSerializationWeaver () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessUniversal81.cs:82)
    PostProcessWinRT.Process () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:96)
    PostProcessUniversal81.Process () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessUniversal81.cs:42)
    UnityEditor.Metro.BuildPostprocessor.PostProcess (BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:100)
    UnityEditor.PostprocessBuildPlayer.Postprocess (BuildTarget target, System.String installPath, System.String companyName, System.String productName, Int32 width, Int32 height, System.String downloadWebplayerUrl, System.String manualDownloadWebplayerUrl, BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/PostprocessBuildPlayer.cs:316)
    UnityEditor.HostView:OnGUI()
     
  2. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,894
    Does that happen with empty project as well? In any case, could you submit a bug with repro attached, something went wrong with new Networking stuff :/
     
  3. scbundy

    scbundy

    Joined:
    May 23, 2014
    Posts:
    51
    It does not happen with an empty project. So something went weird with the migration with 5.1.1 with my old project. Unfortunately I can't just submit a bug with the repro, this project is huge. I've had nothing but problems with my Windows Store build. There's some strangeness with a memory leak that only happens on the Windows Phone build of a universal app under 5.0.2. So I upgraded and now this. At least it would compile before. I'm thinking I just won't bother with the WS build. Clearly Unity just doesn't support it well.
     
  4. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,894
  5. scbundy

    scbundy

    Joined:
    May 23, 2014
    Posts:
    51
    I would but I've already upgraded to 5.1.1. Think I'll just wait until Windows 10. Hopefully you guys will have it all sorted by then
     
  6. Epic_Cube

    Epic_Cube

    Joined:
    Jul 3, 2012
    Posts:
    99
    Same problem for me too... :-(
     
  7. Epic_Cube

    Epic_Cube

    Joined:
    Jul 3, 2012
    Posts:
    99
    FIXED
    Hi,
    I'm using Unity 5.1.2 and I've got the same problem as above.
    Untill I was using Unity 5.0.1 no problem occurred while exporting, but after Unity update, I had the same problem as you.
    Here it's the fix:
    If you look inside YOUR_PROJECT/Library folder, you'll see there's a directory called "ScriptAssemblies". You should delete all its content. On next build Unity will detect that the deleted files are missing and will ask you to "try again". Click on "try again" and the new files will be correctly rebuild, and post process tasks will work! ;-)