Help plees

InvalidOperationException: Operation is not valid due to the current state of the object
System.Collections.Stack.Peek () (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections/Stack.cs:321)
UnityEngine.GUILayoutUtility.EndLayoutGroup ()
UnityEngine.GUILayout.EndVertical ()
UnityEditor.AnimEditor.OnBreadcrumbGUI (UnityEditor.EditorWindow parent, Rect position) (at /Users/builduser/buildslave/unity/build/Editor/Mono/Animation/AnimationWindow/AnimEditor.cs:114)
UnityEditor.AnimationWindow.OnGUI () (at /Users/builduser/buildslave/unity/build/Editor/Mono/Animation/AnimationWindow/AnimationWindow.cs:47)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[ ] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)

There are a few things you can improve to help others understand the issue you are having.

First of all, a meaningful thread title helps. There are several forum members who skip topics without a meaningful title.
You are also not sharing any information when this error happens. Is it in the editor when you perform certain actions, when you enter play mode, when you switch scenes or something completely different?

This error occurs when selecting an object, create an animation.

Can’t reproduce it.

Animation reproduced but only in Unity and in the emulator. On the device, no animation, no object

It might be useful to have a precise reproduction that is very detailed.

I create an object. Then when you create the animation for this object flies error in the console. Unity latest release. All updated.