Open
Description
Painless adds additional variables into scripts based on getter present in the script context. For example, in IngestScript the getCtx()
method provides for the ctx
variable. Although the variable is backed by a getter and so there is clearly no assignment possible, painless does not reject overwriting the local ctx
variable. To a user it appears assignment to ctx works, but in practice the change is a noop. We should block such assignment with a clear error message.