Tom - I updated the driver I'm fiddling with per your wiki, and noticed 
that there's no backward compatibility example for the "In main programs" 
example at the top of the wiki page. Does this look right as a potential 
addition to the wiki ?

Tests out ok on python3 / weewx4 FWIW....

if __name__ == "__main__":
    usage = """%prog [options] [--help]"""

    def main():
        try:
            import logging
            import weeutil.logger
            log = logging.getLogger(__name__)
            weeutil.logger.setup('mydrivername', {} )
        except:
            import syslog
            syslog.openlog('mydrivername', syslog.LOG_PID | syslog.LOG_CONS)



 

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-development/58ba0277-d263-4e88-aa2f-0292482537a6%40googlegroups.com.

Reply via email to