I found this on another site:
The Wall Street Journal's stylebook entry on collective nouns advises that with words such as variety, number and total, [and group] a rule of thumb is to use a singular verb when the article the precedes the noun and a plural verb when the article a is used.
So "The number," "the total," and "the variety" have a singular meaning. But "a number," "a total," and "a variety" take a plural verb.
The advice, though, doesn't fit my native patterns. I'd say "a total of ... is..." Which doesn't mean to say I am right, but more so to clarify that what is written about usage isn't necessarily what people actually say or write.
In keeping with that thought, this is what the American Heritage Dictionary has to say about "variety of":
agreement by proximity
. Certain grammatical constructions provide further complications. Sometimes the noun that is adjacent to the verb can exert more influence than the noun that is the grammatical subject. Selecting a verb in a sentence like A variety of styles has been/have been in vogue for the last year
can be tricky. The traditional rules require has been
, but the plural sense of the noun phrase presses for have been
. While 59 percent of the Usage Panel insists on the singular verb in this sentence, 22 percent actually prefer the plural verb and another 19 percent say that either has
is acceptable, meaning that 41 percent find the plural verb with a singular grammatical subject to be acceptable.
Source: § 60. subject and verb agreement. 1. Grammar. The American Heritage Book of English Usage. 1996
There are more sources here:
"a variety" singular plural verb - Google Search