# ActorAddressLogFilter appears in Thespian 3.6.1; add it for 3.6.0
import thespian.director
import logging

if not hasattr(thespian.director, 'ActorAddressLogFilter'):
    with open(thespian.director.__file__, 'a') as tdf:
        tdf.write("""

class ActorAddressLogFilter(logging.Filter):
    def filter(self, record):
        if not hasattr(record, 'actorAddress'):
            record.actorAddress = '-not-actor-'
        return True
""")
