enforce version `:latest` as a symbol

`:latest` has special meaning.  The corresponding string
`'latest'` is disallowed.
Merge pull request #7504 from rolandwalker/enforce_latest_as_symbol

enforce version `:latest` as a symbol