Re: docstrings style question

2008-01-10 Thread Russ P.
On Jan 9, 11:51 pm, Fredrik Lundh [EMAIL PROTECTED] wrote: Steve Brown wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST): Temperature Sense Test I don't like the duplicated

Re: docstrings style question

2008-01-10 Thread Jeroen Ruigrok van der Werven
-On [20080110 06:51], Steve Brown ([EMAIL PROTECTED]) wrote: I don't like the duplicated information: But the comment is attractive, I find it unattractive to be honest. and the docstring self.__doc__ is already in use in the test log. I've read that all modules and classes should have

RE: docstrings style question

2008-01-10 Thread Ryan Ginstrom
On Behalf Of Steve Brown What do you think? I think that comments are for maintainers, and docstrings are for users. Some of the things I use comments for: * Visually separate classes (using a syntax-highlighting editor) * Explain algorithm choices * Explain bug fixes so I don't later fix

Re: docstrings style question

2008-01-10 Thread Martin Marcher
Russ P. wrote: On Jan 9, 9:47 pm, Steve Brown [EMAIL PROTECTED] wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST): Temperature Sense Test I don't like the duplicated information: But the

Re: docstrings style question

2008-01-10 Thread Steve Brown
Russ P. [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Jan 9, 11:51 pm, Fredrik Lundh [EMAIL PROTECTED] wrote: Steve Brown wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class

Re: docstrings style question

2008-01-10 Thread Neil Cerutti
On Jan 10, 2008 12:47 AM, Steve Brown [EMAIL PROTECTED] wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST): Temperature Sense Test I don't like the duplicated information: But the comment

Re: docstrings style question

2008-01-10 Thread Steve Brown
Neil Cerutti [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Jan 10, 2008 12:47 AM, Steve Brown [EMAIL PROTECTED] wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST):

Re: docstrings style question

2008-01-10 Thread Steve Brown
What I'm trying to do with the tests is pare them back so that the code explicitly and concisely documents the tests. It is important that the comments and doc strings NOT contain information about how Temperature Sense works because that is outside the scope of the test. More generally,

Re: docstrings style question

2008-01-10 Thread Steven D'Aprano
On Fri, 11 Jan 2008 13:09:26 +1100, Steve Brown wrote: What I'm trying to do with the tests is pare them back so that the code explicitly and concisely documents the tests. Yes, this is good. It is important that the comments and doc strings NOT contain information about how Temperature

docstrings style question

2008-01-09 Thread Steve Brown
I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST): Temperature Sense Test I don't like the duplicated information: But the comment is attractive, and the docstring self.__doc__ is already in use in the

Re: docstrings style question

2008-01-09 Thread Fredrik Lundh
Steve Brown wrote: I've got a series of modules which look like this: # # # Temperature Sense Test # # class Test3(ar_test.AR_TEST): Temperature Sense Test I don't like the duplicated information: But the comment is attractive, and the docstring