I committed a fix to github for this error. It was due to uniqid('',true) returning an ID with a decimal point in it and Java didn't like that. uniqid() would probably be good enough, but I chose to wrap it in a str_replace to replace the decimal point with an underscore. The cache $map array key was causing an extra input field on the calculator form, so I added an additional $key check for cache.
(Click to enlarge)
#1968 - Calculatr addon results in error