Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Conor Sayres
Hi Guys, Tom nailed it. It seems to be a bug in my text editor from which I was viewing the files (Sublime Text 2). The logging was correct all along. Thanks All! Conor On Oct 16, 2013, at 3:07 PM, Tom Prince wrote: > Conor Sayres writes: > >> I have set up twisted logging to record a

Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Tom Prince
Conor Sayres writes: > I have set up twisted logging to record all communication between our > devices. When we simulate our system with a high frequency log rollover rate > (~5 seconds), many of the logs contain only garbage. Here is an example of a > few lines in a given bad log file: > >

Re: [Twisted-Python] Twisted-Python Digest, Vol 115, Issue 19

2013-10-16 Thread Tom Sheffler
og file will be good or > bad. > > > > > I don't know where those numbers/letters could be coming from. Does your > code (or any libraries you use) ever print to stdout? By default, Twisted > redirects all prints (and any writing to sys.stdout) to the log file. > > &

Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Glyph
On Oct 16, 2013, at 11:19 AM, Christopher Armstrong wrote: > The only other thing I can think of (without having a reproducible example of > the problem in a self-contained executable example) is that some other > program or code is opening the same file and writing garbage to it. Maybe you

Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Christopher Armstrong
On Wed, Oct 16, 2013 at 1:12 PM, Conor Sayres wrote: > > On Oct 16, 2013, at 10:44 AM, Christopher Armstrong < > ra...@twistedmatrix.com> wrote: > > On Wed, Oct 16, 2013 at 12:33 PM, Conor Sayres wrote: > >> Hi All, >> >> I'm working for an astro observatory and we are upgrading our telescope >>

Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Conor Sayres
On Oct 16, 2013, at 10:44 AM, Christopher Armstrong wrote: > On Wed, Oct 16, 2013 at 12:33 PM, Conor Sayres wrote: > Hi All, > > I'm working for an astro observatory and we are upgrading our telescope > control software. We are swapping to twisted under the hood, and I have run > into an i

Re: [Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Christopher Armstrong
On Wed, Oct 16, 2013 at 12:33 PM, Conor Sayres wrote: > Hi All, > > I'm working for an astro observatory and we are upgrading our telescope > control software. We are swapping to twisted under the hood, and I have > run into an issue regarding logging. > > I have set up twisted logging to record

[Twisted-Python] Garbage in logfiles?

2013-10-16 Thread Conor Sayres
Hi All, I'm working for an astro observatory and we are upgrading our telescope control software. We are swapping to twisted under the hood, and I have run into an issue regarding logging. I have set up twisted logging to record all communication between our devices. When we simulate our sys

Re: [Twisted-Python] Setting source address of outgoing datagrams

2013-10-16 Thread Richard Wall
On 16 October 2013 12:47, Itamar Turner-Trauring wrote: > On 10/16/2013 03:36 AM, Maciej Wasilak wrote: >> All in all the problem with using wrong source address can be easilly >> solved with a bit of user attention, however it's hard to find the solution >> that "just works". >> > There's an OS A

Re: [Twisted-Python] Setting source address of outgoing datagrams

2013-10-16 Thread Itamar Turner-Trauring
On 10/16/2013 03:36 AM, Maciej Wasilak wrote: All in all the problem with using wrong source address can be easilly solved with a bit of user attention, however it's hard to find the solution that "just works". There's an OS API (recvmsg?) that lets you get at this information; I believe Tw

Re: [Twisted-Python] Setting source address of outgoing datagrams

2013-10-16 Thread Maciej Wasilak
Itamar, If you pass a specific IP to the interface keyword argument instead of > "::", the UDP port will bind to that specific IP and will only send > datagrams on that IP. You can use netifaces package (e.g. find it on PyPI) > to list all local IPs. So you could do the equivalent of "::" by bindi