tracker issue : CF-4202035

select a category, or use search below
(searches all categories and all time range)
Title:

[ANeff] Bug for: RunAsync() throws invalid exception

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/Fixed

Reporter/Name(from Bugbase): Aaron Neff / ()

Created: 04/19/2018

Components: Language, Asynchronous Programming

Versions: 2018

Failure Type: Incorrect w/Workaround

Found In Build/Fixed In Build: 2018.0.0.308164 / 308648

Priority/Frequency: Normal / Very few users will encounter

Locale/System: / Platforms All

Vote Count: 0

Issue: RunAsync() throws invalid exception

Repro:

<cfscript>
  writeDump(runAsync(function(){return 1}, 1000, [1,2,3]).get())
</cfscript>

Actual Result: "coldfusion.compiler.MethodArgumentMismatchException: Parameter validation error for runAsync function. The function allows 3 parameters, but found 4."

Expected Result: "coldfusion.compiler.MethodArgumentMismatchException: Parameter validation error for runAsync function. The function allows 2 parameters, but found 3."

Interestingly, when the 3rd parameter is a simple value, then the function returns a result instead of throwing exception:

<cfscript>
  writeDump(runAsync(function(){return 1}, 1000, "1,2,3").get())
</cfscript>

Actual Result: "1"

Expected Result: "coldfusion.compiler.MethodArgumentMismatchException: Parameter validation error for runAsync function. The function allows 2 parameters, but found 3."

Attachments:

Comments:

Hi Adobe, I had a typo: "Actual Result: "coldfusion.compiler.MethodArgumentMismatchException: Parameter validation error for runAsync function. The function allows 3 parameters, but found 4."" should've been: "Actual Result: "coldfusion.compiler.MethodArgumentMismatchException: Parameter validation error for runAsync function. The function allows 0 parameters, but found 4."" But, anyhow, the issue remains: the error message is wrong. Thanks!, -Aaron
Comment by Aaron N.
27631 | May 01, 2018 05:53:38 PM GMT