eXpandFramework / eXpand

DevExpress XAF (eXpressApp) extension framework. 𝗹𝗶𝗻𝗸𝗲𝗱𝗶𝗻.𝗲𝘅𝗽𝗮𝗻𝗱𝗳𝗿𝗮𝗺𝗲𝘄𝗼𝗿𝗸.𝗰𝗼𝗺, 𝘆𝗼𝘂𝘁𝘂𝗯𝗲.𝗲𝘅𝗽𝗮𝗻𝗱𝗳𝗿𝗮𝗺𝗲𝘄𝗼𝗿𝗸.𝗰𝗼𝗺 and 𝘁𝘄𝗶𝘁𝘁𝗲𝗿 @𝗲𝘅𝗽𝗮𝗻𝗱𝗳𝗿𝗮𝗺𝗲𝘄𝗼𝗿𝗸 and or simply 𝗦𝘁𝗮𝗿/𝘄𝗮𝘁𝗰𝗵 this repository and get notified from 𝗚𝗶𝘁𝗛𝘂𝗯
http://expand.expandframework.com
Microsoft Public License
222 stars 115 forks source link

Can't start my application any more after editing model ('MapperWin637010291105362639, Version=1.1.36.1 not found) #504

Closed vimarx closed 5 years ago

vimarx commented 5 years ago

I managed to open model editor and after changing the XMlcontent editor in MDO_DetailView and restart, the application fails to start with the

10.08.19 10:19:10.350 Resolve the 'DevExpress.Persistent.BaseImpl.v19.1' assembly 10.08.19 10:19:10.961 Customize TypesInfo 10.08.19 10:19:11.083 Generación de estructura de interfaz de usuario de aplicación... 10.08.19 10:19:21.658 ModelMapper assembly created 10.08.19 10:19:21.973 Resolve the 'MapperWin637010291105362639, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' assembly vxerp.win.exe Error: 0 : 10.08.19 10:19:21.978 ================================================================================ The error occurred:

Type:       AggregateException
Message:    Se han producido uno o varios errores.
Data:       0 entries
Stack trace:

en System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) en System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) en DevExpress.ExpressApp.Win.WinApplication.SetupCore(String applicationName, IList`1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.XafApplication.Setup() en VxERP.Win.Program.Main(String[] arguments)

InnerException:

        Type:       ObjectCreatingException
        Message:    Unable to create an instance of the "ModelApplicationCreatorInfo" type.

Reason: "No se puede cargar el archivo o ensamblado 'MapperWin637010291105362639, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' ni una de sus dependencias. El sistema no puede encontrar el archivo especificado." Data: 0 entries Stack trace:

en DevExpress.ExpressApp.Utils.Reflection.TypeData.CreateInstance(Object[] args) en DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.CreateCreatorInfo(ModelApplicationCreator modelApplicationCreator) en DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.get_CreatorInfo() en DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.AddValidator[T](IModelNodeValidator1 validator) en DevExpress.ExpressApp.SystemModule.SystemModule.AddModelNodeValidators(IModelNodeValidatorRegistrator validatorRegistrator) en DevExpress.ExpressApp.ApplicationModelManager.SetupModelApplicationCreator(ModelApplicationCreator creator, IEnumerable1 modules, IEnumerable1 aspects) en DevExpress.ExpressApp.ApplicationModelManager.Setup(ITypesInfo typesInfo, IEnumerable1 boModelTypes, IEnumerable1 modules, IEnumerable1 controllers, IEnumerable1 applicationLocalizerTypes, IEnumerable1 applicationAspects, ModelStoreBase applicationModelDifferenceStore, String modelAssemblyFile) en DevExpress.ExpressApp.XafApplication.CreateModelManager(IEnumerable1 boModelTypes) en DevExpress.ExpressApp.Win.WinApplication.CreateModelManager(IEnumerable1 boModelTypes) en DevExpress.ExpressApp.XafApplication.Setup(ExpressApplicationSetupParameters parameters) en DevExpress.ExpressApp.XafApplication.SetupCore(String applicationName, IList1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.Win.WinApplication.<>n__0(String applicationName, IList1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.Win.WinApplication.<>c__DisplayClass77_0.b__0() en System.Threading.Tasks.Task.InnerInvoke() en System.Threading.Tasks.Task.Execute()

        InnerException:

                Type:       FileNotFoundException
                Message:    No se puede cargar el archivo o ensamblado 'MapperWin637010291105362639, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' ni una de sus dependencias. El sistema no puede encontrar el archivo especificado.
                Data:       0 entries
                Stack trace:

en ModelApplicationCreatorInfo..ctor(ModelApplicationCreator applicationCreator) InnerException is null


vimarx commented 5 years ago

had to delete modelassembly.dll

vimarx commented 5 years ago

and startup.profile

apobekiaris commented 5 years ago

hard to follow did u resolve it?

vimarx commented 5 years ago

btw I had a C:\Users\gmarzioni\AppData\Local\Temp\ModelMapperModule\vxerp path with each mapperwinxxxx.dll

vimarx commented 5 years ago

the logs says "10.08.19 13:58:30.588 Resolve the 'MapperWin637010420746958963, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' assembly" but the Mapperwinxxxx.dll generated is a difrrent one

vimarx commented 5 years ago

If I delete the modelassembly. it start ok. but if I start it a second time (this second time the modelassembly is already there), it fails again, so it is not a workaround

apobekiaris commented 5 years ago

MapperWin637010291105362639

latest version store the assemblies in temp, along with related application name. Whats the location of this file?

though from the version we can tell that is generated from the latest modelmapper

vimarx commented 5 years ago

C:\Users\gmarzioni\AppData\Local\Temp\ModelMapperModule\vxerp

wich is temp+app.name (vxerp)

but the numbers are different

vimarx commented 5 years ago

Also now I found this exception on startup Type: AggregateException Message: Se han producido uno o varios errores. Data: 0 entries Stack trace:

en System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) en System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) en DevExpress.ExpressApp.Win.WinApplication.SetupCore(String applicationName, IList`1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.XafApplication.Setup() en VxERP.Win.Program.Main(String[] arguments)

InnerException:

        Type:       FileNotFoundException
        Message:    El sistema no puede encontrar el archivo especificado. (Excepción de HRESULT: 0x80070002)
        Data:       0 entries
        Stack trace:

en System.Reflection.RuntimeAssembly.nLoadFile(String path, Evidence evidence) en System.Reflection.Assembly.LoadFile(String path) en Xpand.XAF.Modules.ModelMapper.Services.TypeMapping.TypeMappingService.<>cDisplayClass90_0.b10(Boolean ) en System.Reactive.Linq.ObservableImpl.Select`2.Selector..OnNext(TSource value) --- Fin del seguimiento de la pila de la ubicación anterior donde se produjo la excepción --- en System.Reactive.PlatformServices.ExceptionServicesImpl.Rethrow(Exception exception) en System.Reactive.Stubs.<>c.<.cctor>b21(Exception ex) en System.Reactive.AnonymousSafeObserver1.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.HalfSerializer.ForwardOnError[T](ISink1 sink, Exception ex, Int32& wip, Exception& error) en System.Reactive.Linq.ObservableImpl.TakeUntil2..OnError(Exception ex) en System.Reactive.Linq.ObservableImpl.Merge1.Observables._.InnerObserver.OnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.Switch1..InnerObserver.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.SelectMany2.ObservableSelector..InnerObserver.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive(Int32 count) en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive() en System.Reactive.Subjects.ReplaySubject1.ReplayBase.OnError(Exception error) en System.Reactive.Subjects.ReplaySubject1.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.SelectMany2.ObservableSelector..InnerObserver.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.Switch1..InnerObserver.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive(Int32 count) en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive() en System.Reactive.Subjects.ReplaySubject1.ReplayBase.OnError(Exception error) en System.Reactive.Subjects.ReplaySubject1.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Subjects.Subject1.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Sink2.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.Switch1._.OnError(Exception error) en System.Reactive.Sink1.ForwardOnError(Exception error) en System.Reactive.Linq.ObservableImpl.Select2.Selector._.OnNext(TSource value) en System.Reactive.Linq.ObservableImpl.All1..OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Linq.ObservableImpl.Do1.Observer..OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Sink2.OnCompleted() en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive(Int32 count) en System.Reactive.Subjects.FastImmediateObserver1.EnsureActive() en System.Reactive.Subjects.ReplaySubject1.ReplayBase.OnCompleted() en System.Reactive.Subjects.ReplaySubject1.OnCompleted() en Xpand.XAF.Modules.ModelMapper.Services.TypeMapping.TypeMappingService.Start() en System.Reactive.Linq.ObservableImpl.Finally1._.Dispose(Boolean disposing) en System.Reactive.Sink1.Dispose() en System.Reactive.Disposables.Disposable.TryDispose(IDisposable& fieldRef) en System.Reactive.Sink1.Dispose(Boolean disposing) en System.Reactive.Sink1.Dispose() en System.Reactive.Disposables.Disposable.TryDispose(IDisposable& fieldRef) en System.Reactive.Linq.ObservableImpl.Switch1._.OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Sink2.OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Sink2.OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Linq.ObservableImpl.Switch1._.OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Sink2.OnCompleted() en System.Reactive.Sink1.ForwardOnCompleted() en System.Reactive.Linq.ObservableImpl.ToObservableRecursive1._.LoopRec(IScheduler scheduler) en System.Reactive.Linq.ObservableImpl.ToObservableRecursive1._.<>c.b__50(IScheduler innerScheduler, this) en System.Reactive.Concurrency.ScheduledItem2.InvokeCore() en System.Reactive.Concurrency.CurrentThreadScheduler.Trampoline.Run(SchedulerQueue1 queue) en System.Reactive.Concurrency.CurrentThreadScheduler.Schedule[TState](TState state, TimeSpan dueTime, Func3 action) en System.Reactive.Concurrency.LocalScheduler.Schedule[TState](TState state, Func3 action) en System.Reactive.Concurrency.Scheduler.ScheduleAction[TState](IScheduler scheduler, TState state, Action1 action) en System.Reactive.Producer2.SubscribeRaw(IObserver1 observer, Boolean enableSafeguard) en System.ObservableExtensions.SubscribeSafe[T](IObservable1 source, IObserver1 observer) en System.Reactive.Linq.ObservableImpl.Switch1..OnNext(IObservable1 value) en System.Reactive.Sink1.ForwardOnNext(TTarget value) en System.Reactive.Linq.ObservableImpl.Select`2.Selector..OnNext(TSource value) en System.Reactive.Sink1.ForwardOnNext(TTarget value) en System.Reactive.Linq.ObservableImpl.Select2.Selector..OnNext(TSource value) en System.Reactive.Sink1.ForwardOnNext(TTarget value) en System.Reactive.Linq.ObservableImpl.FirstAsync1.Sequence..OnNext(TSource value) en System.Reactive.Sink1.ForwardOnNext(TTarget value) en System.Reactive.Linq.ObservableImpl.Switch1._.InnerObserver.OnNext(TSource value) en System.Reactive.Subjects.Subject1.OnNext(T value) en Xpand.XAF.Modules.Reactive.ReactiveModule.ExtendModelInterfaces(ModelInterfaceExtenders extenders) en DevExpress.ExpressApp.ApplicationModelManager.CreateModelApplicationCreatorProperties(IEnumerable1 modules, IEnumerable1 controllers, String assemblyFileAbsolutePath) en DevExpress.ExpressApp.ApplicationModelManager.Setup(ITypesInfo typesInfo, IEnumerable1 boModelTypes, IEnumerable1 modules, IEnumerable1 controllers, IEnumerable1 applicationLocalizerTypes, IEnumerable1 applicationAspects, ModelStoreBase applicationModelDifferenceStore, String modelAssemblyFile) en DevExpress.ExpressApp.XafApplication.CreateModelManager(IEnumerable1 boModelTypes) en DevExpress.ExpressApp.Win.WinApplication.CreateModelManager(IEnumerable1 boModelTypes) en DevExpress.ExpressApp.XafApplication.Setup(ExpressApplicationSetupParameters parameters) en DevExpress.ExpressApp.XafApplication.SetupCore(String applicationName, IList`1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.Win.WinApplication.<>n0(String applicationName, IList`1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) en DevExpress.ExpressApp.Win.WinApplication.<>c__DisplayClass77_0.b__0() en System.Threading.Tasks.Task.InnerInvoke() en System.Threading.Tasks.Task.Execute() InnerException is null

vimarx commented 5 years ago

this is my temp path after several tries image

vimarx commented 5 years ago

the issue is very easy to reproduce (attached sample)

1) start an app as standalone (not in vs), modelassembly is creaded and starts Ok 2) start it a second time. it fails Varios.zip

apobekiaris commented 5 years ago

great I let u know then once I rpro and fix it.

vimarx commented 5 years ago

my temp path after several tries with this sample app image it may be generating garbage ....

apobekiaris commented 5 years ago

see the docs when assembly generation happens, this might be expected

vimarx commented 5 years ago

BTW I had xpand and dx in GAC

isatahiri commented 5 years ago

I'm having the same issue with eXpand 19.1.502.8 : The error occurred:

Type:       AggregateException
Message:    Une ou plusieurs erreurs se sont produites.
Data:       0 entries
Stack trace:

à System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) à System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) à DevExpress.ExpressApp.Win.WinApplication.SetupCore(String applicationName, IList`1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) à DevExpress.ExpressApp.XafApplication.Setup() à PME_Affaire.Win.Program.Main() dans C:\Users\isata\Documents\PME Projects\PME_Affaire\PME_Affaire.Win\Program.cs:ligne 57

InnerException:

        Type:       ObjectCreatingException
        Message:    Unable to create an instance of the "ModelApplicationCreatorInfo" type.

Reason: "Impossible de charger le fichier ou l'assembly 'MapperWin637010632231313945, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' ou une de ses dépendances. Le fichier spécifié est introuvable." Data: 0 entries Stack trace:

à DevExpress.ExpressApp.Utils.Reflection.TypeData.CreateInstance(Object[] args) à DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.CreateCreatorInfo(ModelApplicationCreator modelApplicationCreator) à DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.get_CreatorInfo() à DevExpress.ExpressApp.Model.Core.ModelApplicationCreator.AddValidator[T](IModelNodeValidator1 validator) à DevExpress.ExpressApp.SystemModule.SystemModule.AddModelNodeValidators(IModelNodeValidatorRegistrator validatorRegistrator) à DevExpress.ExpressApp.ApplicationModelManager.SetupModelApplicationCreator(ModelApplicationCreator creator, IEnumerable1 modules, IEnumerable1 aspects) à DevExpress.ExpressApp.ApplicationModelManager.Setup(ITypesInfo typesInfo, IEnumerable1 boModelTypes, IEnumerable1 modules, IEnumerable1 controllers, IEnumerable1 applicationLocalizerTypes, IEnumerable1 applicationAspects, ModelStoreBase applicationModelDifferenceStore, String modelAssemblyFile) à DevExpress.ExpressApp.XafApplication.CreateModelManager(IEnumerable1 boModelTypes) à DevExpress.ExpressApp.Win.WinApplication.CreateModelManager(IEnumerable1 boModelTypes) à DevExpress.ExpressApp.XafApplication.Setup(ExpressApplicationSetupParameters parameters) à DevExpress.ExpressApp.XafApplication.SetupCore(String applicationName, IList1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) à DevExpress.ExpressApp.Win.WinApplication.<>n__0(String applicationName, IList1 objectSpaceProviders, ApplicationModulesManager modulesManager, ISecurityStrategyBase security) à DevExpress.ExpressApp.Win.WinApplication.<>c__DisplayClass77_0.b__0() à System.Threading.Tasks.Task.InnerInvoke() à System.Threading.Tasks.Task.Execute()

        InnerException:

                Type:       FileNotFoundException
                Message:    Impossible de charger le fichier ou l'assembly 'MapperWin637010632231313945, Version=1.1.36.1, Culture=neutral, PublicKeyToken=null' ou une de ses dépendances. Le fichier spécifié est introuvable.
                Data:       0 entries
                Stack trace:

à ModelApplicationCreatorInfo..ctor(ModelApplicationCreator applicationCreator) InnerException is null

I tried to delete the tmp folder but not change

expand commented 5 years ago

The DevExpress.XAF repository includes commits that relate to this task:

Please update the related Nuget packages and test if issues is addressed. These are nightly nuget packages available only from our NugetServer.

If you do not use the Xpand.XAF.Modules directly but through a module of the main eXpandFramework project, please wait for the bot to notify you again when integration is finished or update the related packages manually.

Thanks a lot for your contribution.

vimarx commented 5 years ago

works Ok!!