Started working with Python, which is extremely easy and a joy to work in. It also has great libraries and tools you can use. So, also started using CherryPy to power the XML API I am working on. While debugging it throws out a lot of messages on stdout, of which the access messages I don’t want. Googling and playing around I found this quick way to disable the access logging in stdout:

    import logging
    import cherrypy

    cherrypy.log.screen = False
    cherrypy.log.error_file = ""
    cherrypy.log.error_log.addHandler(logging.StreamHandler())
Categorieën: GeekstuffSnack

0 reacties

Geef een reactie

Avatar plaatshouder

Het e-mailadres wordt niet gepubliceerd. Vereiste velden zijn gemarkeerd met *

Deze site gebruikt Akismet om spam te verminderen. Bekijk hoe je reactie-gegevens worden verwerkt.