Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #45941

Re: Debugging parallel nose tests?

From Roy Smith <roy@panix.com>
Newsgroups comp.lang.python
Subject Re: Debugging parallel nose tests?
Date 2013-05-24 23:09 -0400
Organization PANIX Public Access Internet and UNIX, NYC
Message-ID <roy-9BA181.23091824052013@news.panix.com> (permalink)
References <roy-1CC2EA.09092123052013@news.panix.com>

Show all headers | View raw


In article <roy-1CC2EA.09092123052013@news.panix.com>,
 Roy Smith <roy@panix.com> wrote:

> Is there some way to make nose print a report of how it partitioned the 
> tests across the various processes?

I never found such a feature, but I did figure out a way to do what I 
needed.  We use a system of unique id's to track HTTP requests through 
our system.  All you need do is add a X-Unique-Request-ID header and any 
of our server processes will log that.  So, I just had my test suite add:

X-Unique-Request-ID: name-of-test.process-id

to each HTTP request.  That got me what I was looking for (to know what 
tests were grouped into the same process).

> We're using:
> 
> nosetests --process-timeout=60 --processes=40 test_api.py

It turned out, the answer was purely a timing issue.  We had some tests 
that called out to facebook.  Those were (intermittently) so slow they 
caused the 60 second timeout to be exceeded.  The solution there was to 
pull the facebook tests out to their own suite (which we'll run in 
single-process mode).

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Debugging parallel nose tests? Roy Smith <roy@panix.com> - 2013-05-23 09:09 -0400
  Re: Debugging parallel nose tests? Dave Angel <davea@davea.name> - 2013-05-23 14:31 -0400
    Re: Debugging parallel nose tests? Roy Smith <roy@panix.com> - 2013-05-23 21:44 -0400
  Re: Debugging parallel nose tests? Roy Smith <roy@panix.com> - 2013-05-24 23:09 -0400

csiph-web