Closed bucherrolf closed 7 years ago
Do you want to log lightning data only or everything that currently goes to stdout? The demo script was setup to demonstrate the library, so I didn't put a lot of thought into extending it for other uses, though I do have another project that pushes lighting data over the web.
You might consider replacing the print statements with logging statements and use Python's logging facility if that meets your needs.
logging facility is the key. Many thanks for the link.. I guess this will help to solve my needs.
Has anyone found the right code for redirecting the "demo.py" script to a file. I'm looping around with writng to stdout stdin ev. piping or simply > to file.. I tested this with open("blitze.dat", "w") as f: sys.stdout = f for global redirecting the print. But the file is not open for printing
Any help would be appreciated