automated unit test generation

2013-09-28 Thread skunkwerk
Hi, I've been working on an open source project to auto-generate unit tests for web apps based on traces collected from the web server and static code analysis. I've got an alpha version online at www.splintera.com, and the source is at https://github.com/splintera/python-django-client.

Re: UnpicklingError: NEWOBJ class argument isn't a type object

2013-07-08 Thread skunkwerk
On Monday, July 8, 2013 12:45:55 AM UTC-7, Peter Otten wrote: skunkwerk wrote: Hi, I'm using a custom pickler that replaces any un-pickleable objects (such as sockets or files) with a string representation of them, based on the code from Shane Hathaway here: http

UnpicklingError: NEWOBJ class argument isn't a type object

2013-07-07 Thread skunkwerk
Hi, I'm using a custom pickler that replaces any un-pickleable objects (such as sockets or files) with a string representation of them, based on the code from Shane Hathaway here: http://stackoverflow.com/questions/4080688/python-pickling-a-dict-with-some-unpicklable-items It works most of

settrace doesn't trace builtin functions

2013-06-30 Thread skunkwerk
Hi, I've been using the settrace function to write a tracer for my program, which is working great except that it doesn't seem to work for built-in functions, like open('filename.txt'). This doesn't seem to be documented, so I'm not sure if I'm doing something wrong or that's the expected

multiprocessing pipes with custom pickler

2013-06-18 Thread skunkwerk
Hi, I need inter-process communication in Python, and was looking at the documentation here: http://docs.python.org/2/library/multiprocessing.html I am using a custom pickler, though, in order to deal with some objects that are not serialize-able through the built-in pickler. Is there any

collecting variable assignments through settrace

2013-06-18 Thread skunkwerk
Hi, I'm writing a custom profiler that uses sys.settrace. I was wondering if there was any way of tracing the assignments of variables inside a function as its executed, without looking at locals() at every single line and comparing them to see if anything has changed. Sort of like xdebug's

Re: lots of futex_wait calls

2008-06-10 Thread skunkwerk
On Jun 6, 10:03 am, André Malo [EMAIL PROTECTED] wrote: skunkwerkwrote: I've got a python program written for the django web framework that starts about 100 threads. When I start the server, it sometimes eats up 100% of the CPU for a good minute or so... though none of the threads are

lots of futex_wait calls

2008-06-06 Thread skunkwerk
I've got a python program written for the django web framework that starts about 100 threads. When I start the server, it sometimes eats up 100% of the CPU for a good minute or so... though none of the threads are CPU-intensive doing a strace on the program, i found lots of calls like this:

Re: threading - race condition?

2008-05-12 Thread skunkwerk
On May 11, 1:55 pm, Dennis Lee Bieber [EMAIL PROTECTED] wrote: On Sun, 11 May 2008 09:16:25 -0700 (PDT),skunkwerk [EMAIL PROTECTED] declaimed the following in comp.lang.python: the only issue i have now is that it takes a long time for 100 threads to initialize that connection (5 minutes

Re: threading - race condition?

2008-05-12 Thread skunkwerk
On May 12, 1:40 am, Rhamphoryncus [EMAIL PROTECTED] wrote: On May 11, 10:16 am,skunkwerk[EMAIL PROTECTED] wrote: On May 10, 1:31 pm, Dennis Lee Bieber [EMAIL PROTECTED] wrote: On Fri, 9 May 2008 08:40:38 -0700 (PDT),skunkwerk[EMAIL PROTECTED] declaimed the following

Re: threading - race condition?

2008-05-12 Thread skunkwerk
On May 11, 9:10 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Sun, 11 May 2008 13:16:25 -0300,skunkwerk[EMAIL PROTECTED] escribió: the only issue i have now is that it takes a long time for 100 threads to initialize that connection (5 minutes) - and as i'm doing this on a webserver any

Re: threading - race condition?

2008-05-11 Thread skunkwerk
On May 10, 1:31 pm, Dennis Lee Bieber [EMAIL PROTECTED] wrote: On Fri, 9 May 2008 08:40:38 -0700 (PDT),skunkwerk[EMAIL PROTECTED] declaimed the following in comp.lang.python:         Coming in late... On May 9, 12:12 am, John Nagle [EMAIL PROTECTED] wrote: skunkwerkwrote: i've

Re: threading - race condition?

2008-05-09 Thread skunkwerk
On May 9, 12:12 am, John Nagle [EMAIL PROTECTED] wrote: skunkwerk wrote: i'm getting the wrong output for the 'title' attributes for this data.  the queue holds a data structure (item name, position, and list to store results in).  each thread takes in an item name and queries a database

threading - race condition?

2008-05-08 Thread skunkwerk
i'm getting the wrong output for the 'title' attributes for this data. the queue holds a data structure (item name, position, and list to store results in). each thread takes in an item name and queries a database for various attributes. from the debug statements the item names are being

Re: threading - race condition?

2008-05-08 Thread skunkwerk
On May 8, 4:54 pm, [EMAIL PROTECTED] wrote: On May 8, 5:45 pm, skunkwerk [EMAIL PROTECTED] wrote: i'm getting the wrong output for the 'title' attributes for this data. the queue holds a data structure (item name, position, and list to store results in). each thread takes in an item

Re: logger output

2008-05-06 Thread skunkwerk
On May 5, 3:44 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Mon, 05 May 2008 13:02:12 -0300,skunkwerk[EMAIL PROTECTED] escribió: On May 4, 10:40 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Mon, 05 May 2008 00:33:12 -0300,skunkwerk[EMAIL PROTECTED] escribió: i'm redirecting

Re: logger output

2008-05-05 Thread skunkwerk
On May 4, 10:40 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Mon, 05 May 2008 00:33:12 -0300,skunkwerk[EMAIL PROTECTED] escribió: i'm redirecting the stdout stderr of my python program to a log. Tests i've done on a simple program with print statements, etc. work fine. however

logger output

2008-05-04 Thread skunkwerk
i'm redirecting the stdout stderr of my python program to a log. Tests i've done on a simple program with print statements, etc. work fine. however, in my actual program i get weird output like this: 2008-05-04 20:20:44,790 DEBUG Grabbing message from queue, if any 2008-05-04 20:20:44,790 DEBUG

Re: subprocess.popen function with quotes

2008-04-13 Thread skunkwerk
On Mar 26, 10:33 pm, skunkwerk [EMAIL PROTECTED] wrote: On Mar 26, 8:05 am, Jeffrey Froman [EMAIL PROTECTED] wrote: skunkwerkwrote: p = subprocess.Popen(['rename','-vn','s/(.*)\.htm$/ model.html/','*.htm'],stdout=subprocess.PIPE,stderr=subprocess.PIPE) print p.communicate()[0] i

Re: popen pipe limit

2008-04-09 Thread skunkwerk
On Apr 7, 6:17 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Mon, 07 Apr 2008 20:52:54 -0300,skunkwerk[EMAIL PROTECTED]   escribió: I'm getting errors when reading from/writing to pipes that are fairly large in size.  To bypass this, I wanted to redirect output to a file

popen pipe limit

2008-04-07 Thread skunkwerk
I'm getting errors when reading from/writing to pipes that are fairly large in size. To bypass this, I wanted to redirect output to a file in the subprocess.Popen function, but couldn't get it to work (even after setting Shell=True). I tried adding ,temp.sql after the password field but

Re: subprocess.popen function with quotes

2008-03-26 Thread skunkwerk
On Mar 25, 11:04 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008 02:15:28 -0300, skunkwerk [EMAIL PROTECTED]   escribió: On Mar 25, 9:25 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008 00:39:05 -0300, skunkwerk [EMAIL PROTECTED]   escribió

Re: subprocess.popen function with quotes

2008-03-26 Thread skunkwerk
On Mar 26, 6:44 am, skunkwerk [EMAIL PROTECTED] wrote: On Mar 25, 11:04 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008 02:15:28 -0300, skunkwerk [EMAIL PROTECTED]   escribió: On Mar 25, 9:25 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008

Re: subprocess.popen function with quotes

2008-03-26 Thread skunkwerk
On Mar 26, 8:05 am, Jeffrey Froman [EMAIL PROTECTED] wrote: skunkwerk wrote: p = subprocess.Popen(['rename','-vn','s/(.*)\.htm$/ model.html/','*.htm'],stdout=subprocess.PIPE,stderr=subprocess.PIPE) print p.communicate()[0] i change to print p.communicate()[1] in case the output is blank

subprocess.popen function with quotes

2008-03-25 Thread skunkwerk
Hi, i'm trying to call subprocess.popen on the 'rename' function in linux. When I run the command from the shell, like so: rename -vn 's/\.htm$/\.html/' *.htm it works fine... however when I try to do it in python like so: p = subprocess.Popen([rename,-vn,'s/\.htm$/

Re: subprocess.popen function with quotes

2008-03-25 Thread skunkwerk
also, i've tried the Shell=True parameter for Popen, but that didn't seem to make a difference On Mar 25, 8:31 pm, skunkwerk [EMAIL PROTECTED] wrote: Hi, i'm trying to call subprocess.popen on the 'rename' function in linux. When I run the command from the shell, like so: rename -vn 's

Re: subprocess.popen function with quotes

2008-03-25 Thread skunkwerk
On Mar 25, 9:25 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008 00:39:05 -0300, skunkwerk [EMAIL PROTECTED]   escribió:    i'm trying to call subprocess.popen on the 'rename' function in linux.  When I run the command from the shell, like so: rename -vn 's/\.htm