1. 26 Sep, 2001 6 commits
    • Barry Warsaw's avatar
      __init__(): Arguments major renamed to maintype and minor renamed to · 76fac8ed
      Barry Warsaw authored
          subtype for consistency with the rest of the package.
      76fac8ed
    • Barry Warsaw's avatar
      Updated docstrings. Also, · 57758e3a
      Barry Warsaw authored
      typed_subpart_iterator(): Arguments major renamed to maintype and
          minor renamed to subtype for consistency with the rest of the
          package.
      57758e3a
    • Barry Warsaw's avatar
      Image.py and class Image => MIMEImage.py and MIMEImage · 3dd978df
      Barry Warsaw authored
      Text.py and class Text => MIMEText.py and MIMEText
      
      MessageRFC822.py and class MessageRFC822 => MIMEMessage.py and MIMEMessage
      
      These are renamed so as to be more consistent; these are MIME specific
      derived classes for when creating the object model out of whole cloth.
      3dd978df
    • Barry Warsaw's avatar
      In class Generator: · b384e017
      Barry Warsaw authored
          _handle_text(): If the payload is None, then just return (i.e. don't
      	write anything).  Subparts of message/delivery-status types
      	will have this property since they are just blocks of headers.
      
      	Also, when raising the TypeError, include the type of the
      	payload in the error message.
      
          _handle_multipart(), _handle_message(): When creating a clone of self,
      	pass in our _mangle_from_ and maxheaderlen flags so the clone
      	has the same behavior.
      
          _handle_message_delivery_status(): New method to do the proper
      	printing of message/delivery-status type messages.  These have
      	to be handled differently than other message/* types because
      	their payloads are subparts containing just blocks of headers.
      
      In class DecodedGenerator:
      
          _dispatch(): Skip over multipart/* messages since we don't care
              about them, and don't want the non-text format to appear in
              the printed results.
      b384e017
    • Barry Warsaw's avatar
      cosmetic · 6f70c419
      Barry Warsaw authored
      6f70c419
    • Barry Warsaw's avatar
      The email package documentation, currently organized the way I think · 5e634638
      Barry Warsaw authored
      Fred prefers.  I'm not sure I like this organization, so it may change.
      5e634638
  2. 25 Sep, 2001 25 commits
  3. 24 Sep, 2001 9 commits
    • Tim Peters's avatar
      + Text-mode (but not yet GUI mode) pydoc now produces useful stuff for · f4aad8eb
      Tim Peters authored
        properties:  the docstring (if any) is displayed, and the getter, setter
        and deleter (if any) functions are named.  All that is shown indented
        after the property name.
      
      + Text-mode pydoc class display now draws a horizontal line between
        class attribute groups (similar to GUI mode -- while visually more
        intrusive in text mode, it's still an improvement).
      f4aad8eb
    • Tim Peters's avatar
      Make properties discoverable from Python: · 66c1a525
      Tim Peters authored
      - property() now takes 4 keyword arguments:  fget, fset, fdel, doc.
        Note that the real purpose of the 'f' prefix is to make fdel fit in
        ('del' is a keyword, so can't used as a keyword argument name).
      
      - These map to visible readonly attributes 'fget', 'fset', 'fdel',
        and '__doc__' in the property object.
      
      - fget/fset/fdel weren't discoverable from Python before.
      
      - __doc__ is new, and allows to associate a docstring with a property.
      66c1a525
    • Fred Drake's avatar
      Added several new tests to check the behavior with respect to doctype · 30c48491
      Fred Drake authored
      declarations and weird markup that we used to accept & ignore that recent
      versions raised an exception for; the original behavior has been restored
      and augmented (the user can decide what to do if they care; the default is
      to ignore it as done in early versions).
      30c48491
    • Fred Drake's avatar
      Adapt to use the test_main() approach. · e822049e
      Fred Drake authored
      e822049e
    • Fred Drake's avatar
      Re-factor the SGMLParser class to use the new markupbase.ParserBase class. · a3bae336
      Fred Drake authored
      Use a new internal method, error(), consistently to raise parse errors;
      the new base class also uses this.
      Adjust the parse_comment() method to return the new offset into the buffer
      instead of the number of characters scanned; this was the only helper
      method that did it this way, so we have better consistency now.  Required
      to share the new base class.
      This fixes SF bug #448482 and #453706.
      a3bae336
    • Fred Drake's avatar
      Re-factor the HTMLParser class to use the new markupbase.ParserBase class. · bfc8fea1
      Fred Drake authored
      Use a new internal method, error(), consistently to raise parse errors;
      the new base class also uses this.
      bfc8fea1
    • Fred Drake's avatar
      Be consistent about the string module. · 1cffd5cc
      Fred Drake authored
      1cffd5cc
    • Fred Drake's avatar
      New base class for the SGMLParser and HTMLParser classes from the sgmllib · 68f8a806
      Fred Drake authored
      and HTMLParser modules (and indirectly for the htmllib.HTMLParser class).
      
      This has all the support for scanning over DOCTYPE declarations; it warrants
      having a base class since this is a fair amount of tedious code (since it's
      fairly strict), and should be in a separate module to avoid compiling many
      REs that are not used (which would happen if this were placed in either then
      sgmllib or HTMLParser module).
      68f8a806
    • Thomas Wouters's avatar
      Don't swap the arguments to PyFrame_BlockSetup when recreating the recently · 1ee64221
      Thomas Wouters authored
      popped frame-block. What an embarrassing bug! Especially for Jeremy, since
      he accepted the patch :-)
      
      This fixes SF bugs #463359 and #462937, and possibly other, *very* obscure
      bugs with very deeply nested loops that continue the loop and then break out
      of it or raise an exception.
      1ee64221