summaryrefslogtreecommitdiffstats
path: root/Lib/sgmllib.py
Commit message (Collapse)AuthorAgeFilesLines
* bunch more __all__ listsSkip Montanaro2001-02-151-0/+1
| | | | | | also modified check_all function to suppress all warnings since they aren't relevant to what this test is doing (allows quiet checking of regsub, for instance)
* Use ValueError instead of string.atoi.error, since we've switched toEric S. Raymond2001-02-091-1/+1
| | | | int().
* String method conversion.Eric S. Raymond2001-02-091-5/+5
|
* Whitespace normalization.Tim Peters2001-01-151-2/+2
|
* Update the code to better reflect recommended style:Fred Drake2000-12-121-2/+2
| | | | | Use != instead of <> since <> is documented as "obsolescent". Use "is" and "is not" when comparing with None or type objects.
* [Old patch that hadn't been checked in.]Fred Drake2000-06-291-2/+11
| | | | | | | | | | | get_starttag_text(): New method. Return the text of the most recently parsed start tag, from the '<' to the '>' or '/'. Not really useful for structure processing, but requested for Web-related use. May also be useful for being able to re-generate the input from the parse events, but there's no equivalent for end tags. attrfind: Be a little more forgiving of unquoted attribute values.
* typos fixed by Rob HooftJeremy Hylton2000-06-281-1/+1
|
* The third and final doc-string sweep by Ka-Ping Yee.Guido van Rossum2000-02-041-1/+1
| | | | | | | | The attached patches update the standard library so that all modules have docstrings beginning with one-line summaries. A new docstring was added to formatter. The docstring for os.py was updated to mention nt, os2, ce in addition to posix, dos, mac.
* Allow recognition of attributes even if they don't have space in frontFred Drake1999-01-251-1/+1
| | | | | | | of them. I.e., '<a name="foo"href="bar.html">' will now have two attributes recognized. Based on comments from newgroup.
* Patch by Chris Herborth (posted to comp.lang.python)to make it behaveGuido van Rossum1998-08-241-3/+3
| | | | with tags that have - or . in their names.
* Put back the call to report_unbalanced() that was lost whenGuido van Rossum1998-07-071-0/+2
| | | | parse_endtag() was restructured in parse_endtag() and finish_endtag().
* Patch by Lars Marius Garshol:Guido van Rossum1998-05-281-2/+30
| | | | | | | | | - Handle <? processing instructions >. - Allow . and - in entity names. Also fixed an oversight in the previous fix (in one place, [ \t\r\n] was used instead of string.whitespace).
* Fix regexp for attrfind; bug reported by Lars Marius GarsholFred Drake1998-04-161-4/+4
| | | | <larsga@ifi.uio.no>.
* Mass check-in after untabifying all files that need it.Guido van Rossum1998-03-261-275/+275
|
* Although it's hard to be sure, I *think* this is a working conversionGuido van Rossum1997-10-231-67/+67
| | | | | | from regex to re style regular expressions. This should make sgmllib and htmllib threadsafe, so I can now create a threaded version of webchecker...
* (sgmllib.py): Partial acceptance of patch from David LeonardFred Drake1996-12-161-1/+1
| | | | | | | | <leonard@dstc.edu.au>; allows hyphen and period in the middle of attribute names. Still not allowed as first character; as first character these are illegal in the Reference Concrete Syntax, and we've not identified any use of these characters as the first char in an attribute name in deployment on the web.
* Reformatted with 4-space tab stops.Guido van Rossum1996-03-281-286/+406
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow '=' and '~' in unquoted attribute values. Added overridable methods handle_starttag(tag, method, attrs) and handle_endtag(tag, method) so subclasses can decide whether they really want to call the method (e.g. when suppressing some portion of the document). Added support for a number of SGML shortcuts: shorthand full notation <tag>...<>... <tag>...<tag>... <tag>...</> <tag>...</tag> <tag/.../ <tag>...</tag> <tag1<tag2> <tag1><tag2> </tag1</tag2> </tag1></tag2> </tag1<tag2> </tag1><tag2> This required factoring out some common actions and rationalizing the interface to parse_endtag(), so as to make the code more readable. Fixed syntax for &entity and &#char references so the trailing semicolon is optional; removed explicit support for trailing period (which was a TBL mistake in HTML 0.0). Generalized the test program. Tried to speed things up a little. (More to come after the profile results are in.) Fix error recovery: call the end methods popped from the stack instead of the one that triggers. (Plus some complications because of the way HTML extensions are handled in Grail.)
* typos in attrfind regexGuido van Rossum1995-10-061-1/+1
|
* allow _ in attr names (Netscape!)Guido van Rossum1995-09-301-1/+1
|
* fix <!...!> parsing; added verbose option; don't lowercase entityrefsGuido van Rossum1995-09-221-5/+7
|
* support value-less attributes, using regex.group()Guido van Rossum1995-09-011-14/+8
|
* added note about missing featuresGuido van Rossum1995-08-101-0/+2
|
* changed comment parsingGuido van Rossum1995-08-041-13/+14
|
* make reporting unbalanced tags an overridable methodGuido van Rossum1995-06-221-2/+7
|
* remove redundant backslashes; some cosneticsGuido van Rossum1995-03-041-9/+10
|
* added html parser and supporting castGuido van Rossum1995-02-271-0/+321