Race _is_ a spectrum but genetic differences themselves are distinct (SNPs). It's trivial to train a classifier to distinguish race from genetic data, hence, I'd argue they are distinct groups.
You can draw an analogy to colours in the rainbow: a rainbow is a spectrum but we can still draw lines that demarcate colours. Colour definitions are fuzzy at the edges but this doesn't mean coarse colour labels are not distinct.