Upgrading to 2021.2.0a11 breaks projects using Entities 0.17.0

After upgrading to 2021.2.0a11 (from 2021.2.0a10), my project will no longer load. I receive the following error message:

Library\PackageCache\com.unity.platforms@0.10.0-preview.10\Editor\Unity.InternalAPIEditorBridge.012\EditorGUIBridge.cs(15,45): error CS0426: The type name ‘HyperLinkClickedEventArgs’ does not exist in the type ‘EditorGUILayout’

It appears that the source of the problem is that the latest version of the Entities package has a dependency on the com.unity.platforms package, which is broken by the upgrade to 2021.2.0a11.

Tracing the dependency in the packages-lock.json file, it looks like the Entities package (com.unity.entities) is the source of the dependency on com.unity.platforms 0.10.0-preview.10. My project uses the latest version of the Entities package (0.17.0-preview.41).

To rule out that it was an issue with the upgrade process, I also create a new project with 2021.2.0a11. This worked fine. Then I added the latest version of the Entities package (0.17.0) and then I get the same error message in the com.unity.platforms package.

Cross posted to the 2021.2 Alpha forum: Upgrading to 2021.2.0a11 breaks Entities 0.17.0-preview.41 package

I copied “com.unity.platforms@0.10.0-preview.10” to the packages folder to make it embedded, then changed the EditorGuiBridge.cs file to this:

using System;
using System.Collections.Generic;
using UnityEditor;

namespace Unity.Build.Bridge
{
    internal static class EditorGUIBridge
    {
        [InitializeOnLoadMethod]
        static void Register()
        {
            EditorGUI.hyperLinkClicked += (sender, args) =>
            {
                var hyperLinkArgs = new Dictionary<string, string>();
                if (args is HyperLinkClickedEventArgs editorArgs)
                {
                    foreach (var pair in editorArgs.hyperLinkData)
                    {
                        hyperLinkArgs.Add(pair.Key, pair.Value);
                    }
                }
                HyperLinkClicked?.Invoke(hyperLinkArgs);
            };
        }

        public static event Action<IReadOnlyDictionary<string, string>> HyperLinkClicked;
    }
}

Lines 15 and 17 have been edited.

Uh, I am just gonna wait til Unity fixes it properly. I got this bug in .11 and .12 So I stay on .10

Despite my above post, I reverted back to LTS because I couldn’t remember what f****** scripts were meant to be where my ‘missing script’ errors were… I can’t believe this is still a problem today… can you just tell us the last known script name…

PSA: If you are using UI toolkit and upgrading from a UI Toolkit package version, screenshot all your UI Toolkit scripts in the hierarchy so you know what to fix…

I just tried upgrading to 2021.2.0a12 and I’m still seeing this issue.

The lesson I’ve learned is just don’t bother trying to use alpha releases. There is usually something that breaks my project, or at least an annoying/confusing UX change. Sometimes everything works(or mostly works), but it’s not worth the time downloading, upgrading, and debugging when it doesn’t.

Unless there is something you need in the alpha, or you’re really committed to helping Unity solve this issue, stick to official releases/lts. I use all the latest DOTS packages on 2020.3.2f1

I’m mostly just attracted to the syntactic sugar in the c# 9 release. But that can wait a bit longer haha.

The reduced build times with the alpha are really nice, considering how important for dots(in my case anyway) it is to make sure things are working in editor and a build, since things can go wonky pretty easily. The UITK issues are frustrating & hard to narrow down, but I guess that’s my fault for using all preview stuff on top of an alpha

To be clear, I’m not complaining that there are bugs in the alpha build. It’s an alpha, bugs (even serious ones) are going to happen. I’ve got my reasons why I feel it makes sense to be working with the alpha builds for my project.

I posted because this particular issue breaks the Editor when using DOTS, which I know is a core focus for the future of Unity, and so I wanted to raise awareness to both the Unity team and any other developers trying to work with DOTS and the 2021.2 alpha build path.

Well, now I am complaining.

Apparently the root cause of this is that DOTS (or at least the part of the stack that depends on the Entities package, which is most of DOTS) is not, and will not be, supported on Unity 2021. Per an announcement made yesterday , anything dependent on the Entities package will only be supported on Unity 2020 LTS. This will remain the case until some undefined time in the future, but definitely not before 2022.

So, for anyone who wants to work with the ECS part of DOTS (which is a core part of DOTS), you’ll need to stay on the 2020 LTS path until further notice. If you’re like me and you’re already running on the 2021 path, you’ll need to downgrade your project(s) to 2020 LTS in order to work with ECS.