Fixed #19125 -- The startproject command should validate the name earlier

Thanks Łukasz Rekucki for the report and the patch.