I have a user who is using the LF payment portal plugin with the Braintree SDK. Is there any problems that may occur when updating the Braintree SDK?
Question
Question
Replies
For the out-of-box Braintree payment gateway integration provided by Forms, we plan to upgrade the SDK to the latest version in the first half of this year.
Braintree mentions the 4.11.0 version used by Forms currently will not be supported from August 2023: https://github.com/braintree/braintree_dotnet
4.11 will not be supported after Feb 28th.
4.18.1 will be supported until August.
LF Forms is currently using 4.11.
I downloaded the 4.18.1 and when staring the LF Forms Routing Services I get the following error:
An unexpected error has occurred. [LFF502-UnexpectedError]
Details:
URL: /Forms/CHLForm
Error: UnexpectedError
Date: 1/30/2023 1:39:04 PM (Pacific Standard Time)
HTTP Status Code: 500
Business Process ID: 0
User:
IP: 10.21.46.124
Browser: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36
Business Process Name:
Stack Trace:
Caught exception: Laserfiche.Forms.CommonUtils.Exceptions.LFFormsException
Message: An unexpected error has occurred. [LFF502-UnexpectedError]
Inner exception: System.TypeInitializationException
Message: The type initializer for 'Laserfiche.Forms.CommonUtils.PayPalBraintreeStatusUtil' threw an exception.
at Laserfiche.Forms.CommonUtils.PayPalBraintreeStatusUtil.FormatAmountInput(Decimal amount, String pc)
at E_Forms.Classes.FormGenerator.GetPaymentHtml(Boolean isUserTask)
at E_Forms.Classes.FormGenerator.PopulateForm(FormSetting formSetting, Boolean prevXml, Boolean IsFriendlyName, HttpRequest request, NameValueCollection retainCollection)
at E_Forms.Models.ViewModels.Form.NewSubmission.PopulateForm(Boolean IsFriendlyName, HttpRequestBase request)
at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1)
at ASP._Page_Views_Form__FormLayout_cshtml.Execute() in c:\Program Files\Laserfiche\Laserfiche Forms\Forms\Views\Form\_FormLayout.cshtml:line 321
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy()
at System.Web.Mvc.WebViewPage.ExecutePageHierarchy()
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage)
at System.Web.WebPages.WebPageBase.<>c__DisplayClass40_0.<RenderPageCore>b__0(TextWriter writer)
at System.Web.WebPages.WebPageBase.Write(HelperResult result)
at System.Web.WebPages.WebPageBase.RenderSurrounding(String partialViewName, Action`1 body)
at System.Web.WebPages.WebPageBase.PopContext()
at System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult)
at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass3_1.<BeginInvokeAction>b__1(IAsyncResult asyncResult)
Inner exception: System.IO.FileLoadException
Message: Could not load file or assembly 'Braintree, Version=4.11.0.0, Culture=neutral, PublicKeyToken=31b586f34d3e96c7' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
at Laserfiche.Forms.CommonUtils.PayPalBraintreeStatusUtil..cctor()
Laserfiche has released updates for Forms 10.4.5 and Forms 11 to update the Braintree SDKs, see more information from https://support.laserfiche.com/kb/1014423/laserfiche-forms-braintree-payment-gateway-sdks-update