Reset passwords in User controller

Whenever I try to reset a password with the options under Users - > additional -> reset passwords and check both options, “generate random passwords” and “send email with password”

I’ve got following errors, please see attached pictures.
34
21

also this is the stacktrace from tomcat catalina.out

20:38:52.005 ERROR c.h.cuba.core.sys.ServiceInterceptor - Exception: 
java.lang.ExceptionInInitializerError: null
	at org.codehaus.groovy.runtime.InvokerHelper.<clinit>(InvokerHelper.java:66)
	at groovy.lang.GroovyObjectSupport.<init>(GroovyObjectSupport.java:34)
	at groovy.lang.Binding.<init>(Binding.java:35)
	at groovy.lang.GroovyShell.<init>(GroovyShell.java:86)
	at groovy.text.SimpleTemplateEngine.<init>(SimpleTemplateEngine.java:110)
	at com.haulmont.cuba.security.app.UserManagementServiceBean.changePasswordsAtLogonAndSendEmails(UserManagementServiceBean.java:222)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
	at org.springframework.aop.aspectj.MethodInvocationProceedingJoinPoint.proceed(MethodInvocationProceedingJoinPoint.java:85)
	at com.haulmont.cuba.core.sys.ServiceInterceptor.aroundInvoke(ServiceInterceptor.java:117)
	at sun.reflect.GeneratedMethodAccessor150.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:629)
	at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:618)
	at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:70)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:168)
	at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
	at com.sun.proxy.$Proxy60.changePasswordsAtLogonAndSendEmails(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at com.haulmont.cuba.core.sys.remoting.LocalServiceInvokerImpl.invoke(LocalServiceInvokerImpl.java:94)
	at com.haulmont.cuba.web.sys.remoting.LocalServiceProxy$LocalServiceInvocationHandler.invoke(LocalServiceProxy.java:154)
	at com.sun.proxy.$Proxy213.changePasswordsAtLogonAndSendEmails(Unknown Source)
	at com.haulmont.cuba.gui.app.security.user.browse.UserBrowser.resetPasswords(UserBrowser.java:237)
	at com.haulmont.cuba.gui.app.security.user.browse.UserBrowser.lambda$changePasswordAtLogon$6(UserBrowser.java:223)
	at com.haulmont.cuba.web.gui.WebWindow.fireWindowClosed(WebWindow.java:909)
	at com.haulmont.cuba.web.gui.WebWindow.onClose(WebWindow.java:901)
	at com.haulmont.cuba.web.gui.WebWindow.close(WebWindow.java:1198)
Caused by: groovy.lang.GroovyRuntimeException: Conflicting module versions. Module [groovy-all is loaded in version 2.4.4 and you are trying to load version 2.4.12
	at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl$DefaultModuleListener.onModule(MetaClassRegistryImpl.java:513)
	at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanExtensionModuleFromProperties(ExtensionModuleScanner.java:80)
	at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanExtensionModuleFromMetaInf(ExtensionModuleScanner.java:74)
	at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanClasspathModules(ExtensionModuleScanner.java:56)
	at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.<init>(MetaClassRegistryImpl.java:113)
	at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.<init>(MetaClassRegistryImpl.java:74)
	at groovy.lang.GroovySystem.<clinit>(GroovySystem.java:36)
	... 104 common frames omitted

Hi,
it seems that you use two different versions of Groovy in your project:

To make sure of this go to the Tomcat - shared - lib package and check that you have more than one groovy.jar.
There is a possibility that you use some libraries that support another version of Groovy. Please, check this moment and if it is the case, then exclude groovy from the dependencies.