Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only. On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live. Read our full announcement for more information and let us know if you have any questions.

Resolved Visual scripting automated build failure

Discussion in 'Visual Scripting' started by YurySedyakin, Oct 1, 2021.

  1. YurySedyakin

    YurySedyakin

    Joined:
    Jul 25, 2018
    Posts:
    80
    Hello,
    I am trying to build a basically empty project with visual scripting.
    Unity 2021.1.18f1
    Visual Scripting 1.6.1
    I can successfully build from the editor, but on our teamcity buildmachines I always get the following error:

    InvalidOperationException: Trying to access plugin container before it is initialized.
    at Unity.VisualScripting.PluginContainer.EnsureInitialized () [0x0001a] in /Applications/buildAgent/work/BLU/branches/visualScriptTest/ios/Library/PackageCache/com.unity.visualscripting@1.6.1/Editor/VisualScripting.Core/Plugins/PluginContainer.cs:349
    at Unity.VisualScripting.PluginContainer.get_plugins () [0x00000] in /Applications/buildAgent/work/BLU/branches/visualScriptTest/ios/Library/PackageCache/com.unity.visualscripting@1.6.1/Editor/VisualScripting.Core/Plugins/PluginContainer.cs:82
    at Unity.VisualScripting.AotPreBuilder.GenerateLinker () [0x00016] in /Applications/buildAgent/work/BLU/branches/visualScriptTest/ios/Library/PackageCache/com.unity.visualscripting@1.6.1/Editor/VisualScripting.Core/Platforms/AotPreBuilder.cs:110
    at Unity.VisualScripting.AotPreBuilder.GenerateAotStubs () [0x00000] in /Applications/buildAgent/work/BLU/branches/visualScriptTest/ios/Library/PackageCache/com.unity.visualscripting@1.6.1/Editor/VisualScripting.Core/Platforms/AotPreBuilder.cs:76

    I'm not sure I should submit a bugreport since it only happens on the buildmachine and I can't repro locally.
    Any suggestions as to why this happens and how to prevent that error are greatly appreciated.
     
    KislunA likes this.
  2. YurySedyakin

    YurySedyakin

    Joined:
    Jul 25, 2018
    Posts:
    80
    For anyone who encounters this - I upgraded com.unity.visualscripting version to 1.7.3 and it properly builds now. The confusing thing is that Unity 2021.1 doesn't show any version beyond 1.6.1, even though I have "show preview packages" turned on, so I had to do it by manually updating manifest.json.
     
  3. PanthenEye

    PanthenEye

    Joined:
    Oct 14, 2013
    Posts:
    2,158
    I'm pretty sure you're not seeing 1.7.3 on 2021.1 because they broke SubGraph serialization between 1.6 to 1.7 by renaming SuperUnits to SubGraphs. So 1.7.3 is what you get by default on 2021.2. Forcing the update on 2021.1 via manifest.json with an empty project worked fine on my end, though your mileage may vary.