Server Side Error for Method Directive Post Processing

I have created a post process for Erp.BO.Quote.CreateOrder to copy over a UD field from the QuoteHed to the newly created OrderHed.

I have accomplished this two different ways and both ways have Validated successfully in the BPM Workflow Designer. However, when I go to save the BPM, I receive a Server Side Error. The error is the same for either of the two Post Processing methods that I have created. I am a bit perplexed and I am not sure what I have missed.

Here is the full detail of the error message.

Server Side Exception

There is at least one compilation error.
CustomizationAdapter.cs(384,100): error CS0433: The type 'ETCAddrValidationTableset' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'
CustomizationAdapter.cs(389,30): error CS0433: The type 'ETCAddrValidationTableset' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'
CustomizationAdapter.cs(9,132): error CS0738: 'QuoteSvcCustomization' does not implement interface member 'QuoteSvcContract.ETCValidateAddress(int, int, out bool, out bool, out string)'. 'QuoteSvcCustomization.ETCValidateAddress(int, int, out bool, out bool, out string)' cannot implement 'QuoteSvcContract.ETCValidateAddress(int, int, out bool, out bool, out string)' because it does not have the matching return type of 'ETCAddrValidationTableset'.
CustomizationAdapter.cs(9,132): error CS0535: 'QuoteSvcCustomization' does not implement interface member 'QuoteSvcContract.ETCAfterAddressValidationOTS(ref QuoteTableset, ETCAddrValidationTableset, int)'
CreateOrder.CommonTypes.cs(167,55): error CS0433: The type 'QuoteQtyRow' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'

Exception caught in: Epicor.ServiceModel

Error Detail 
============
Correlation ID:  052aa19c-8fa8-4697-b36e-d830b48ca45d
Description:  There is at least one compilation error.
Details:  
CustomizationAdapter.cs(384,100): error CS0433: The type 'ETCAddrValidationTableset' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'
CustomizationAdapter.cs(389,30): error CS0433: The type 'ETCAddrValidationTableset' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'
CustomizationAdapter.cs(9,132): error CS0738: 'QuoteSvcCustomization' does not implement interface member 'QuoteSvcContract.ETCValidateAddress(int, int, out bool, out bool, out string)'. 'QuoteSvcCustomization.ETCValidateAddress(int, int, out bool, out bool, out string)' cannot implement 'QuoteSvcContract.ETCValidateAddress(int, int, out bool, out bool, out string)' because it does not have the matching return type of 'ETCAddrValidationTableset'.
CustomizationAdapter.cs(9,132): error CS0535: 'QuoteSvcCustomization' does not implement interface member 'QuoteSvcContract.ETCAfterAddressValidationOTS(ref QuoteTableset, ETCAddrValidationTableset, int)'
CreateOrder.CommonTypes.cs(167,55): error CS0433: The type 'QuoteQtyRow' exists in both 'Erp.Contracts.BO.Quote, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992' and 'Erp.Contracts.BO.SalesOrder, Version=11.2.200.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992'
Program:  Epicor.Customization.dll
Method:  MoveNext
Line Number:  53
Column Number:  17
Server Trace Stack:     at Epicor.Customization.Standard.EcfInMemoryCompiler.AnalyzeProjectAsync(CustomizationProject project) in C:\_releases\ICE\ICE4.2.200.0\Source\Server\Framework\Epicor.Customization\Standard\EcfInMemoryCompiler.cs:line 53
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetExistingTaskResult(Task`1 task, TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetResult(TResult result)
   at Microsoft.CodeAnalysis.Diagnostics.CompilationWithAnalyzers.GetAllDiagnosticsAsync(CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetExistingTaskResult(Task`1 task, TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetResult(TResult result)
   at Microsoft.CodeAnalysis.Diagnostics.CompilationWithAnalyzers.GetAllDiagnosticsWithoutStateTrackingAsync(ImmutableArray`1 analyzers, CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerDriver.GetDiagnosticsAsync(Compilation compilation)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task.FinishSlow(Boolean userDelegateExecute)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
   at System.Threading.Tasks.ThreadPoolTaskScheduler.TryExecuteTaskInline(Task task, Boolean taskWasPreviouslyQueued)
   at System.Threading.Tasks.TaskContinuation.InlineIfPossibleOrElseQueue(Task task, Boolean needsProtection)
   at System.Threading.Tasks.ContinueWithTaskContinuation.Run(Task completedTask, Boolean canInlineContinuationTask)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetExistingTaskResult(Task`1 task, TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder.SetResult()
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerDriver.ExecutePrimaryAnalysisTaskAsync(AnalysisScope analysisScope, AnalysisState analysisState, Boolean usingPrePopulatedEventQueue, CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.SetExistingTaskResult(Task`1 task, TResult result)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder.SetResult()
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerDriver.ProcessCompilationEventsAsync(AnalysisScope analysisScope, AnalysisState analysisState, Boolean prePopulatedEventQueue, CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.ExecutionContextCallback(Object s)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext()
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task.TrySetResult()
   at System.Threading.Tasks.Task.WhenAllPromise.Invoke(Task completedTask)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at System.Threading.Tasks.UnwrapPromise`1.TrySetFromTask(Task task, Boolean lookForOce)
   at System.Threading.Tasks.UnwrapPromise`1.Invoke(Task completingTask)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerDriver.<>c__DisplayClass127_0.<<ProcessCompilationEventsAsync>b__2>d.MoveNext()
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(IAsyncStateMachineBox box, Boolean allowInlining)
   at System.Threading.Tasks.Task.RunContinuations(Object continuationObject)
   at System.Threading.Tasks.Task`1.TrySetResult(TResult result)
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerDriver.ProcessCompilationEventsCoreAsync(AnalysisScope analysisScope, AnalysisState analysisState, Boolean prePopulatedEventQueue, CancellationToken cancellationToken)
   at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.AsyncStateMachineBox`1.MoveNext(Thread threadPoolThread)
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
   at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()



Client Stack Trace 
==================
   at Ice.Cloud.ProxyBase`1.CallWithCommunicationFailureRetry(String methodName, ProxyValuesIn valuesIn, ProxyValuesOut valuesOut, RestRpcValueSerializer serializer)
   at Ice.Cloud.ProxyBase`1.CallWithMultistepBpmHandling(String methodName, ProxyValuesIn valuesIn, ProxyValuesOut valuesOut, Boolean useSparseCopy)
   at Ice.Cloud.ProxyBase`1.Call(String methodName, ProxyValuesIn valuesIn, ProxyValuesOut valuesOut, Boolean useSparseCopy)
   at Ice.Proxy.BO.BpMethodImpl.Update(BpMethodDataSet ds)
   at Ice.Adapters.BpMethodAdapter.OnUpdate()
   at Ice.Lib.Framework.EpiBaseAdapter.Update()
   at Ice.UI.App.BpMethodEntry.Transactions.MainTransactionBase.adapterUpdate()

Something like this might help.

Thank you Greg. I’ll have a look!

@jharrington did you ever figure this out? I’m running into the same issue, trying to do the exact same thing. Thanks

The linked post should help you out.