473,757 Members | 8,085 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What documentation "standard" to use

I'm confused of how I should document my code, I've always liked being able
to document my code directly in my source file and then to use some tool to
extract the documentation to some other format.

My problem with Python is that there are so many tools and formats ... I
don't know which one I should use. I've tried to figure out if there is one
that is the "de-facto standard" but ...

Could someone advice me on what format/tool I should use?

Oct 5 '05 #1
2 1754
On Oct 05, Kalle Anke wrote:
I'm confused of how I should document my code, I've always liked being
able to document my code directly in my source file and then to use
some tool to extract the documentation to some other format. My problem with Python is that there are so many tools and formats ...
I don't know which one I should use. I've tried to figure out if there
is one that is the "de-facto standard" but ...


You don't need to do any marking up to use pydoc -- just put your
comments in the right place so that they become docstrings. Just try
"pydoc pydoc" for more info. It is distributed with Python, and
generates nicely colored html or opens your PAGER.

Or you could install epydoc <http://epydoc.sourcefo rge.net/>, which has
similar features (and more). It supports "reStructuredTe xt"
<http://docutils.source forge.net/rst.html> and it's own markup (epytext,
I think). RST is the de-facto Python markup, AFAICT. You'll need
something like "__docforma t__ = 'restructuredte xt'" in your modules.
RST is great for non-Python-source code, too.

Those are the two I am aware of.

--
Micah Elliott
<md*@micah.elli ott.name>
Oct 5 '05 #2
This is, as far as I'm concerned, one of the great weaknesses of
Python. (One of a
relatively few, to be honest--I'm still an enthusiast after all!)

There are numerous docstring-oriented tools; in my opinion, none of
them are satisfactory,
because docstrings only apply to certain entities, and there are many
other entities one
might wish to document.

Fred Lundh pointed out just a day or two ago a program of his called
PythonDoc where
documentation is put into comments, and from the brief look I had at
it, I may start
using it, it looks pretty nice.

ReStructuredTex t (now called ReST, I believe) looks like it's finally
become a quite
good text markup language, and if there were a non-docstring system
that used it, I
think that also would be good.

But what I'd really like is for Guido et al to declare a standard
documentation system and
include in the standard Python distro. That way we would have _some_
standard, and
people could concentrate their energy on improving it, rather than on
continually
coming up with their own, non-interoperable, solutions.

Cheers,
Ken

On 5-Oct-05, at 3:26 PM, Kalle Anke wrote:
I'm confused of how I should document my code, I've always liked
being able
to document my code directly in my source file and then to use some
tool to
extract the documentation to some other format.

My problem with Python is that there are so many tools and
formats ... I
don't know which one I should use. I've tried to figure out if
there is one
that is the "de-facto standard" but ...

Could someone advice me on what format/tool I should use?

--
http://mail.python.org/mailman/listinfo/python-list


Oct 6 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

38
3892
by: Jack Klein | last post by:
Many people, including me, like having hard copy books at hand, along with electronic editions. When I first heard of this book several months ago, I pre-ordered a copy. It arrived from Bookpool today. The book is an impressive hard cover, printed in large and very readable type. The first section is the rationale, about 212 pages with its own
4
3751
by: Luke Wu | last post by:
I am just wondering what the following terms usually mean: 1) "Standard C" 2) "K&R C" 3) "ANSI C" I am pretty sure "ANSI C" usually refers to the C89 standard, but what
5
1459
by: VB Programmer | last post by:
If you want to store custom tables in ASP.NET 2.0, such as Products, Companies, Shopping Carts, etc... where is the standard place to put the tables? I want to link it to the user/membership tables. BUT, is it "ok" or the standard practice to go ahead and use the ASPNETDB.mdf to store your own tables?
5
4527
by: funkyj | last post by:
I love pexpect because it means I may never have to use expect again (I don't do any heavy expect lifting -- I just need simple tty control)! As a python advocate I find it embarassing how difficult it is do the following in python (without pexpect): - logon to a remote system using ssh - do an 'ls' and exit the remote shell - print the output from the remote shell session.
6
18964
by: Steph. | last post by:
Hi ! How can I play "standard system sounds" in C# ? ( "standard system sounds" = The kind of sound you hear when you use MessageBox.Show() ) Thanks ! steph.
3
2624
by: sbaird | last post by:
Aloha from Hawaii, I'm beating my head on the wall here. I have a recruiting contact managment database I'm trying to create. Managers (there ar 14 of them) have to make a certain number of recruiting calls per week, and so many of them have to result in at least an appointment. However, the "week" is Wednesday, 12:01pm to the following Wednesday, 12:00noon. So here are my questions... 1) Is there a way to change the standard week...
2
1529
by: Royt | last post by:
Have a look at this site: http://blogs.msdn.com/vcblog/archive/2007/11/05/iso-c-standard-update.aspx C is a mature language used everywhere, it doesn't belong to any commercial company, should it be updated frequently? C99 is not widely adopted till now, what's about the future of "C1x". And who knows more about the new generation standard...
0
9298
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9906
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9885
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8737
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5172
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5329
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3829
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3399
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2698
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.