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: