531
531
If the substrate cannot be made, or does not have the required attributes,
532
532
return None. Otherwise, return the substrate.
538
535
if substrate is not None:
539
536
for attr in required_attrs:
540
537
if getattr(substrate, attr, None) is None: