[Twisted-web] web2 log patch

Ralf Schmitt ralf at brainbot.com
Fri Jan 20 17:48:33 MST 2006

glyph at divmod.com schrieb:
>> I've added a patch for sending new style classes via pb at the end of 
>> 2003.
> ... with no unit tests
Come on. I added a simple test program. If someone told me to write unit 
tests for it, I would have done it. But there has just been
no reaction for 10 months.

Do the twisted developers only start fixing bugs if the bug reporter 
writes a unit test revealing that bug?

>> 10 months later this has been assigned, in march 2005 db3l asks why 
>> this patch hasn't been applied (he's using it successfully).
> ... with no unit tests
>> In April things start to fly: tests are being written,
> Here's the causality:
> "In April, unit tests are written, and things start to fly."
> I won't promise that all patches in the tracker will be applied 
> immediately, even with appropriate tests - after all, review takes 
> some work too, and as I keep repeating, we are short on manpower - but 
> they certainly rot less in the tracker than they would if they were 
> just some random mailing list post.  That bug report provided a hub 
> for quite a bit of discussion, patches, etc, whereas the same thing as 
> a mailing list thread might have been resurrected 5 or 6 times with no 
> actual work being done.

> More importantly, if the peanut gallery ever decides to start going 
> through the tracker and fixing things rather than trolling the various 
> lists, the presence of your bug report there will give them some meat 
> to work on.  The last thing a contributor who is strapped for time 
> wants to do is come to a project and read every message in the last 6 
> years of archives in reverse-date order, looking for something to work 
> on.
I'm not trolling. Reporting bugs is also a form of contribution, people 
spent time on doing it, even sent a patch, and get ignored.
[http://twistedmatrix.com/bugs/issue392]. And you start insulting them 
(btw. what is peanut gallery?), instead of being glad that they
give back their feedback?

>> However, my test program still doesn't work.
> You almost certainly would have had a better experience if you had 
> submitted it in the form of a unit test.
My experience was fine. We were already using the patched version. But, 
to repeat myself:
I would have written unit tests if someone told me to do it.

>> So, maybe you should check your "formalities" that speed up the 
>> development process. I guess they aren't working that good.
> http://www.gamesfromwithin.com/articles/0503/000078.html
> """
> Here's the interesting part, though: I claim that once you're 
> comfortable with TDD and you've applied it to a large amount of code, 
> your development speed will actually be faster than it would be 
> without TDD. So not only you get all the other benefits, but things 
> will go faster and more smoothly. How's that possible?
> """
> All you are looking at is the speed to apply your one patch - 
> Twisted's overall development speed includes the time taken to fix the 
> bugs introduced by such patches.  It may not contain any - but, 
> without tests, how do we know?
I look at the speed of fixing bugs. And in this particular case it took 
18 months or so to fix it.
I have added other bug reports, without getting any reaction.

IMHO, having working code without tests is better than having buggy code 
without tests (well, one might argue that it's the same...).

>> It doesn't make sense for everyone to manage their own patched 
>> twisted, fixing the same bugs...
> You're right about that.  Like Divmod, anyone maintaining a local fork 
> because they depend on bugfixes should submit those bugfixes, with 
> tests, to the Twisted project **first**.
I admit that it's nice for the twisted developers to have bug reports in 
the form of failing unit tests. But you can't expect everyone
to write them.

> Finally, this policy isn't going to change.  For every minor 
> inconvenience it has caused you, it has saved Twisted contributors 
> days or weeks of work.  Whining about it just convinces me that people 
> who don't write tests are whiners who produce buggy code, and who 
> should therefore be ignored.  Is this the image you are trying to 
> project?
I'm not whining (actually I write unit tests at work). We use twisted at 
our company and appreciate the work that has gone into it.
But one thinks about saving that work of reporting bugs, when they just 
aren't dealt with.

- Ralf

More information about the Twisted-web mailing list