Server Error in '/' Application.

Duplicate type name within an assembly.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentException: Duplicate type name within an assembly.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[ArgumentException: Duplicate type name within an assembly.]
   System.Reflection.Emit.ModuleBuilder.CheckTypeNameConflict(String strTypeName, Type enclosingType) +14366816
   System.Reflection.Emit.AssemblyBuilderData.CheckTypeNameConflict(String strTypeName, TypeBuilder enclosingType) +64
   System.Reflection.Emit.TypeBuilder.Init(String fullname, TypeAttributes attr, Type parent, Type[] interfaces, ModuleBuilder module, PackingSize iPackingSize, Int32 iTypeSize, TypeBuilder enclosingType) +165
   System.Reflection.Emit.ModuleBuilder.DefineType(String name, TypeAttributes attr, Type parent, Type[] interfaces) +169
   Castle.DynamicProxy.Builder.CodeBuilder.EasyType..ctor(ModuleScope modulescope, String name, Type baseType, Type[] interfaces, Boolean serializable) +202
   Castle.DynamicProxy.Builder.CodeGenerators.BaseCodeGenerator.CreateTypeBuilder(String typeName, Type baseType, Type[] interfaces) +157
   Castle.DynamicProxy.Builder.CodeGenerators.ClassProxyGenerator.GenerateCode(Type baseClass, Type[] interfaces) +492
   Castle.DynamicProxy.Builder.DefaultProxyBuilder.CreateClassProxy(Type theClass, Type[] interfaces) +128
   Castle.DynamicProxy.ProxyGenerator.CreateClassProxy(Type baseClass, Type[] interfaces, IInterceptor interceptor, Boolean checkAbstract, Object[] argumentsForConstructor) +182
   NHibernate.Proxy.CastleProxyFactory.GetProxy(Object id, ISessionImplementor session) +195

[HibernateException: Creating a proxy instance failed]
   NHibernate.Proxy.CastleProxyFactory.GetProxy(Object id, ISessionImplementor session) +469
   NHibernate.Persister.Entity.AbstractEntityPersister.CreateProxy(Object id, ISessionImplementor session) +26
   NHibernate.Impl.SessionImpl.DoLoadByClass(Type clazz, Object id, Boolean checkDeleted, Boolean allowProxyCreation) +554
   NHibernate.Impl.SessionImpl.InternalLoad(Type clazz, Object id, Boolean eager, Boolean isNullable) +59
   NHibernate.Type.EntityType.ResolveIdentifier(Object id, ISessionImplementor session) +70
   NHibernate.Type.EntityType.ResolveIdentifier(Object id, ISessionImplementor session, Object owner) +51
   NHibernate.Impl.SessionImpl.InitializeEntity(Object obj) +299
   NHibernate.Loader.Loader.InitializeEntitiesAndCollections(IList hydratedObjects, Object resultSetId, ISessionImplementor session) +426
   NHibernate.Loader.Loader.DoQuery(ISessionImplementor session, QueryParameters queryParameters, Boolean returnProxies) +1140
   NHibernate.Loader.Loader.DoQueryAndInitializeNonLazyCollections(ISessionImplementor session, QueryParameters queryParameters, Boolean returnProxies) +78
   NHibernate.Loader.Loader.LoadCollection(ISessionImplementor session, Object id, IType type) +471
   NHibernate.Persister.Collection.AbstractCollectionPersister.Initialize(Object key, ISessionImplementor session) +105
   NHibernate.Impl.SessionImpl.InitializeCollection(IPersistentCollection collection, Boolean writing) +419
   NHibernate.Collection.AbstractPersistentCollection.Initialize(Boolean writing) +131

[LazyInitializationException: Failed to lazily initialize a collection]
   NHibernate.Collection.AbstractPersistentCollection.Initialize(Boolean writing) +486
   NHibernate.Collection.Generic.PersistentGenericBag`1.get_Count() +24

[MethodInvocationException: Invocation of method 'Count' in NHibernate.Collection.Generic.PersistentGenericBag`1[[Ramtha.Core.CartModule.Product, Ramtha.Core, Version=1.0.7096.28932, Culture=neutral, PublicKeyToken=null]], template list\CatStyleList.vm Line 18 Column 52 threw an exception]
   NVelocity.Runtime.Parser.Node.ASTIdentifier.Execute(Object o, IInternalContextAdapter context) +3736
   NVelocity.Runtime.Parser.Node.ASTReference.Execute(Object o, IInternalContextAdapter context) +1325
   NVelocity.Runtime.Parser.Node.ASTReference.Value(IInternalContextAdapter context) +87
   NVelocity.Runtime.Parser.Node.ASTEQNode.Evaluate(IInternalContextAdapter context) +102
   NVelocity.Runtime.Parser.Node.ASTExpression.Evaluate(IInternalContextAdapter context) +95
   NVelocity.Runtime.Parser.Node.ASTIfStatement.Render(IInternalContextAdapter context, TextWriter writer) +102
   NVelocity.Runtime.Parser.Node.ASTBlock.Render(IInternalContextAdapter context, TextWriter writer) +130
   NVelocity.Runtime.Directive.Foreach.Render(IInternalContextAdapter context, TextWriter writer, INode node) +633
   NVelocity.Runtime.Parser.Node.ASTDirective.Render(IInternalContextAdapter context, TextWriter writer) +125
   NVelocity.Runtime.Parser.Node.ASTBlock.Render(IInternalContextAdapter context, TextWriter writer) +130
   NVelocity.Runtime.Parser.Node.ASTIfStatement.Render(IInternalContextAdapter context, TextWriter writer) +176
   NVelocity.Runtime.Parser.Node.SimpleNode.Render(IInternalContextAdapter context, TextWriter writer) +130
   NVelocity.Template.Merge(IContext context, TextWriter writer) +258
   Castle.MonoRail.Framework.Views.NVelocity.NVelocityViewEngine.Process(IRailsEngineContext context, Controller controller, String viewName) +798
   Castle.MonoRail.Framework.Services.DefaultViewEngineManager.Process(IRailsEngineContext context, Controller controller, String templateName) +295
   Castle.MonoRail.Framework.ControllerLifecycleExecutor.ProcessView() +120
   Castle.MonoRail.Framework.ControllerLifecycleExecutor.ProcessSelectedAction(IDictionary actionArgs) +1296
   Castle.MonoRail.Framework.ControllerLifecycleExecutor.ProcessSelectedAction() +40
   Castle.MonoRail.Framework.MonoRailHttpHandler.Process(IRailsEngineContext context) +1006
   Castle.MonoRail.Framework.MonoRailHttpHandler.ProcessRequest(HttpContext context) +86
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +542
   System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +75
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +93


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4700.0