[Twisted-Python] Task-based documentation started

Tom Davis tom at recursivedream.com
Tue Feb 1 11:53:09 MST 2011


On Tue, Feb 1, 2011 at 12:58 PM, Glyph Lefkowitz <glyph at twistedmatrix.com>wrote:

>
> On Jan 31, 2011, at 11:41 AM, Tom Davis wrote:
>
> Thoughts?
>
>
> Priority #1 for most people who are enthusiastic about documentation is to
> come in and write a ton of additional documentation.  But this is a lot like
> trying to fix a large, broken, untested system by writing a pile of new,
> untested code, because "this time we'll get the design right".  What were
> the problems with the way the previous documentation got written?  How did
> we end up with this mess, and what is going to be done differently this
> time?  Most importantly, *what is the metric by which we will judge this
> new documentation to be better?*
>

Those tutorials aren't new at all; they were taken (often verbatim) from the
"using twisted.web" document. Writing a ton of new documentation really
isn't my goal at all. My goals are threefold:

   1. Reorganize existing documentation in a way that makes it more
   accessible.
   2. Edit existing documentation to conform to a task (howto/tutorial/etc.)
   vs. expanded learning model. (the whole instant gratification thing and all
   that)
   3. Gradually update / replace code listings with "current best practices"
   examples that are tested.

I know you want an actual *layout* for the reorganization. I want to give
that to you, but it requires going through all the documentation and making
sure it fits in the reorganized layout or making sections for it when it
doesn't which is far more time consuming than providing a layout for the
"task" piece, as I did here. I'm basically just saying "How-tos should have
a standard layout with these sections; here's a stub of one such how-to as
incompletely adapted from the current documentation".

I think most of this is a huge misunderstanding as to my goals both in
general and for the particular section critiqued here. Perhaps I should have
completed it before putting it up for review. I just felt it was better to
get *something* out here just in case everybody hated the entire direction
rather than spend a ton of time slicing the current web server docs the way
I personally feel they should fit together in order to properly serve the
audience.


>
> If all that comes out of your efforts is a new, different pile of
> documentation, that's not *entirely* without value; different audiences
> understand things in different ways, so someone might pick it up and
> understand Twisted as a result.  But I very much doubt that's going to move
> us from a general impression of "bad docs" to a general impression of "good
> docs".
>
> More specific criticism:
>
>
>    - "This is a Twisted Task"?  I feel like I'm about to start reading
>    about a Task object or something related to the twisted.internet.task
>    module.  Or maybe that this is an exercise.  A document explaining how to do
>    a task is rarely called a "task" itself.  Mostly they're called "How-To"s,
>    actually.  I understand you're trying to get away from old terminology but
>    this seems awkward and forced.
>
> I just started using this terminology because it seemed common within our
conversations. How-to/tutorial would likely be less confusing.

>
>    - "You should be familiar with Resources"?  That is really broad and
>    wide-ranging and should be a hyperlink to another tutorial.
>
> It was just a placeholder; it should link to a section in the web server
overview docs that talks about Resources. There are other things on that
list, too (Site object, yada yada). Although, like I said, it's merely
incomplete.


>
>    -  Plus, I think that most people interested in these tasks will want
>    to learn about how to get simple tasks done first, before moving on to a
>    more abstract / theoretical understanding of the model behind them.
>
> I completely agree. That's my whole point with starting off using *twistd*,
despite its limitations or whatever.

>
>    - More importantly: this is a very wishy-washy definition of the
>    audience.  Is it for system administrators?  Software developers?  DevOps
>    people?  Graphic designers?  Power users?  What level of experience do they
>    need with Python?  With networking?  With HTTP?
>
> The latter should all be under "Prerequisites" whereas "audience" should
probably be a new howto standard section that's currently overlooked
(perhaps above "Prerequisites"?)

>
>    - "Other configuration options are available"?  This should be a list
>    of links to other documents that might help with some of those options.
>     Documentation which says "and then you could do something else" without
>    telling you what else or why is needlessly confusing.
>
> I agree. There are lots and lots of lines to connect even from such a
simplistic tutorial. I wanted to get feedback on the *layout* rather than
the final web project documentation which should certainly include links to
twistd option docs and probably a half dozen other things I haven't linked
to yet.

>
>    - The WSGI example totally glosses over how you get your code onto
>    sys.path (PYTHONPATH etc), says that 'helloworld' is a module/package (which
>    is it?  why are both options given?).  This is an *extremely* confusing
>    area for newbies, which is why it actually makes a bit of sense to me that
>    the web-in-60-seconds WSGI tutorial starts with a callable defined in the
>    .tac.  Not a good practice in the long term, but it allows the user to
>    immediately get some feedback and have some notion of how things are wired
>    together without having to debug Python's import system first.
>
> Fair enough. This point was also not covered in the official docs, where I
got the instructions from. Regardless, I have no intention of including
how-tos that gloss over *anything; *either they work "out of the box" or are
edited until they do.

>
>    - .rpy scripts are for deployment, not debugging; I was a little
>    concerned seeing that bullet point on the outline.  (See <
>    http://twistedmatrix.com/documents/10.2.0/web/howto/web-in-60/rpy-scripts.html
>    >.)
>
> Huh? The docs you link to claim:

So, while rpy scripts may be useful for testing out ideas, they're not
> recommend for much more than that.


Am I missing something here?

* * *

My hope is that this reply clears up some confusion. However, feel free to
let me know if you think I simply don't have the mindset necessary to
"improve" the documentation in a way that is desirable. I had a hard time
learning Twisted in the beginning and to this day some really helpful
abstractions and just available projects / solved problems elude me.

I think the reason for this is that I think a lot like Jacob <
http://jacobian.org/writing/great-documentation/> when it comes to
documentation and that's the sort of stuff I need to have in order to truly
grok something. Maybe that's what we all want here. Maybe it isn't, though.
And I'd really love to figure out which it is before I drive forward on
this. If we really are on the same page (and I'd certainly like to be),
we've got some hellish communication issues ;)


>
>
> _______________________________________________
> Twisted-Python mailing list
> Twisted-Python at twistedmatrix.com
> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/twisted-python/attachments/20110201/f489659a/attachment.html>


More information about the Twisted-Python mailing list