Unity Bug - UnityEditor.EditorWindow.Close

Hello, Unity presents this bug sometimes when I open it and try to click on a menu for example in the scale menu to change it or on objects in the scene to watch the Inspector

This problem has been happening several times, is there a solution?

I’m using the latest version of Unity available on Unity Hub, 2020.1.7f1

NullReferenceException: Object reference not set to an instance of an object
    UnityEditor.EditorWindow.Close () (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.PopupWindow.CloseWindow () (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.PopupWindow.Show (UnityEngine.Rect activatorRect, UnityEditor.PopupWindowContent windowContent, UnityEditor.PopupLocation[] locationPriorityOrder, UnityEditor.ShowMode showMode) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.PopupWindow.Show (UnityEngine.Rect activatorRect, UnityEditor.PopupWindowContent windowContent, UnityEditor.PopupLocation[] locationPriorityOrder) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.PopupWindow.Show (UnityEngine.Rect activatorRect, UnityEditor.PopupWindowContent windowContent) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.EditorGUI.GameViewSizePopup (UnityEngine.Rect buttonRect, UnityEditor.GameViewSizeGroupType groupType, System.Int32 selectedIndex, UnityEditor.IGameViewSizeMenuUser gameView, UnityEngine.GUIStyle guiStyle) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.EditorGUILayout.GameViewSizePopup (UnityEditor.GameViewSizeGroupType groupType, System.Int32 selectedIndex, UnityEditor.IGameViewSizeMenuUser gameView, UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.GameView.DoToolbarGUI () (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.GameView.OnGUI () (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.HostView.InvokeOnGUI (UnityEngine.Rect onGUIPosition, UnityEngine.Rect viewRect) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.DockArea.DrawView (UnityEngine.Rect viewRect, UnityEngine.Rect dockAreaRect) (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEditor.DockArea.OldOnGUI () (at <7dae22651edf474ead4ab15fa947a891>:0)
    UnityEngine.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt, UnityEngine.Matrix4x4 parentTransform, UnityEngine.Rect clippingRect, System.Boolean isComputingLayout, UnityEngine.Rect layoutSize, System.Action onGUIHandler, System.Boolean canAffectFocus) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, UnityEngine.Matrix4x4 worldTransform, UnityEngine.Rect clippingRect, System.Action onGUIHandler, System.Boolean canAffectFocus) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, System.Action onGUIHandler, System.Boolean canAffectFocus) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, System.Boolean canAffectFocus) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.SendEventToIMGUIRaw (UnityEngine.UIElements.EventBase evt, System.Boolean canAffectFocus, System.Boolean verifyBounds) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.SendEventToIMGUI (UnityEngine.UIElements.EventBase evt, System.Boolean canAffectFocus, System.Boolean verifyBounds) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.IMGUIContainer.HandleEvent (UnityEngine.UIElements.EventBase evt) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatchUtilities.PropagateEvent (UnityEngine.UIElements.EventBase evt) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.MouseEventDispatchingStrategy.SendEventToRegularTarget (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.BaseVisualElementPanel panel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.MouseEventDispatchingStrategy.SendEventToTarget (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.BaseVisualElementPanel panel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.MouseEventDispatchingStrategy.DispatchEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel iPanel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, System.Boolean imguiEventIsInitiallyUsed) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.ProcessEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.ProcessEventQueue () (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.OpenGate () (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcherGate.Dispose () (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.ProcessEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.EventDispatcher.Dispatch (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, UnityEngine.UIElements.DispatchMode dispatchMode) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.BaseVisualElementPanel.SendEvent (UnityEngine.UIElements.EventBase e, UnityEngine.UIElements.DispatchMode dispatchMode) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.UIElementsUtility.DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel panel) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.UIElementsUtility.UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& eventHandled) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.UIEventRegistration.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.UIElements.UIEventRegistration+<>c.<.cctor>b__1_2 (System.Int32 i, System.IntPtr ptr) (at <e11cddb636f444f68eec62123764f018>:0)
    UnityEngine.GUIUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& result) (at <2500dd078a544a69b6c923861af6cd15>:0)

@ZOTGames, try to set default layout (Window → Layouts → Default)