Move the macro generation code to *after* verifying all required metadata was provided.
Better format the required metadata errors.