Improved error NameError message by passing in the whole constant name

Improved NameError message so it clearly shows the full constant name that Lotus is looking for.