internal/lsp/cache: don't invalidate metadata for new invalid imports
internal/lsp/cache: don't invalidate metadata for new invalid imports

Our metadata reloading model makes typing out import paths manually
very slow. We can avoid some of the slowness by not invalidating
metadata when a new import path is obviously invalid.

Updates golang/go#35877

Change-Id: Ifcf9ebaac0b146a2098ef8d411fa85fefa7ba6ca
Reviewed-on: https://go-review.googlesource.com/c/tools/+/251086
Run-TryBot: Rebecca Stambler <d7cf11e5f299d88ea8348366a9fc4f7c335c3afa@golang.org>
TryBot-Result: Gobot Gobot <66cb808b70d30c07676d5e946fee83fd561249e5@golang.org>
Reviewed-by: Danish Dua <c3f873b0e0003806921a546abe8deee80b20ea99@google.com>
Reviewed-by: Robert Findley <9179eee875d1ee628c37fb47d7e749e855ffd21f@google.com>

golang/tools,golang/tools,golang/tools,golang/tools,golang/tools