PyUtils: Don't assume that sys.stdout has a name attribute.
In particular, it won't if we're being imported by something running from doctest.
Fixes test failure in D3PDMakerCoreComps.
In particular, it won't if we're being imported by something running from doctest.
Fixes test failure in D3PDMakerCoreComps.