[Python-checkins] r69990 - in python/branches/py3k: Doc/c-api/intro.rst Doc/c-api/veryhigh.rst Doc/howto/webservers.rst Doc/library/2to3.rst Doc/library/abc.rst Doc/library/cgi.rst Doc/library/cgitb.rst Doc/library/stdtypes.rst Doc/library/xml.etree.elementtree.rst Doc/whatsnew/2.5.rst Lib/socketserver.py README

benjamin.peterson python-checkins at python.org
Thu Feb 26 04:38:59 CET 2009


Author: benjamin.peterson
Date: Thu Feb 26 04:38:59 2009
New Revision: 69990
Log:
Merged revisions 69803-69805,69840,69901,69905,69907,69924,69927,69987 via svnmerge from 
svn+ssh://pythondev@svn.python.org/python/trunk
........
 r69803 | georg.brandl | 2009年02月20日 01:48:21 -0600 (2009年2月20日) | 1 line
 
 #5327: fix a broken link by joining it.
........
 r69804 | georg.brandl | 2009年02月20日 02:22:21 -0600 (2009年2月20日) | 1 line
 
 At least separate imports from other statements.
........
 r69805 | georg.brandl | 2009年02月20日 02:45:47 -0600 (2009年2月20日) | 2 lines
 
 Fix punctuation.
........
 r69840 | georg.brandl | 2009年02月21日 13:09:40 -0600 (2009年2月21日) | 1 line
 
 #5338, #5339: two types in the API manual.
........
 r69901 | georg.brandl | 2009年02月23日 05:24:46 -0600 (2009年2月23日) | 2 lines
 
 #5349: C++ pure virtuals can also have an implementation.
........
 r69905 | georg.brandl | 2009年02月23日 09:51:27 -0600 (2009年2月23日) | 2 lines
 
 #5352: str.count() counts non-overlapping instances.
........
 r69907 | georg.brandl | 2009年02月23日 12:33:48 -0600 (2009年2月23日) | 1 line
 
 Fix grammar.
........
 r69924 | benjamin.peterson | 2009年02月23日 20:45:35 -0600 (2009年2月23日) | 1 line
 
 update README on running tests
........
 r69927 | neil.schemenauer | 2009年02月23日 22:23:25 -0600 (2009年2月23日) | 1 line
 
 Fix call to os.waitpid, it does not take keyword args.
........
 r69987 | benjamin.peterson | 2009年02月25日 18:30:11 -0600 (2009年2月25日) | 1 line
 
 fix str.format()'s first arg #5371
........
Modified:
 python/branches/py3k/ (props changed)
 python/branches/py3k/Doc/c-api/intro.rst
 python/branches/py3k/Doc/c-api/veryhigh.rst
 python/branches/py3k/Doc/howto/webservers.rst
 python/branches/py3k/Doc/library/2to3.rst
 python/branches/py3k/Doc/library/abc.rst
 python/branches/py3k/Doc/library/cgi.rst
 python/branches/py3k/Doc/library/cgitb.rst
 python/branches/py3k/Doc/library/stdtypes.rst
 python/branches/py3k/Doc/library/xml.etree.elementtree.rst
 python/branches/py3k/Doc/whatsnew/2.5.rst
 python/branches/py3k/Lib/socketserver.py
 python/branches/py3k/README
Modified: python/branches/py3k/Doc/c-api/intro.rst
==============================================================================
--- python/branches/py3k/Doc/c-api/intro.rst	(original)
+++ python/branches/py3k/Doc/c-api/intro.rst	Thu Feb 26 04:38:59 2009
@@ -187,7 +187,7 @@
 the caller is said to *borrow* the reference. Nothing needs to be done for a
 borrowed reference.
 
-Conversely, when a calling function passes it a reference to an object, there
+Conversely, when a calling function passes in a reference to an object, there
 are two possibilities: the function *steals* a reference to the object, or it
 does not. *Stealing a reference* means that when you pass a reference to a
 function, that function assumes that it now owns that reference, and you are not
Modified: python/branches/py3k/Doc/c-api/veryhigh.rst
==============================================================================
--- python/branches/py3k/Doc/c-api/veryhigh.rst	(original)
+++ python/branches/py3k/Doc/c-api/veryhigh.rst	Thu Feb 26 04:38:59 2009
@@ -16,7 +16,7 @@
 :const:`Py_file_input`, and :const:`Py_single_input`. These are described
 following the functions which accept them as parameters.
 
-Note also that several of these functions take :ctype:`FILE\*` parameters. On
+Note also that several of these functions take :ctype:`FILE\*` parameters. One
 particular issue which needs to be handled carefully is that the :ctype:`FILE`
 structure for different C libraries can be different and incompatible. Under
 Windows (at least), it is possible for dynamically linked extensions to actually
Modified: python/branches/py3k/Doc/howto/webservers.rst
==============================================================================
--- python/branches/py3k/Doc/howto/webservers.rst	(original)
+++ python/branches/py3k/Doc/howto/webservers.rst	Thu Feb 26 04:38:59 2009
@@ -99,7 +99,8 @@
 # -*- coding: UTF-8 -*-
 
 # enable debugging
- import cgitb; cgitb.enable()
+ import cgitb
+ cgitb.enable()
 
 print("Content-Type: text/plain;charset=utf-8")
 print()
Modified: python/branches/py3k/Doc/library/2to3.rst
==============================================================================
--- python/branches/py3k/Doc/library/2to3.rst	(original)
+++ python/branches/py3k/Doc/library/2to3.rst	Thu Feb 26 04:38:59 2009
@@ -38,9 +38,9 @@
 $ 2to3 example.py
 
 A diff against the original source file is printed. 2to3 can also write the
-needed modifications right back to the source file. (Of course, a backup of the
-original is also be made unless :option:`-n` is also given.) Writing the
-changes back is enabled with the :option:`-w` flag::
+needed modifications right back to the source file. (A backup of the original
+file is made unless :option:`-n` is also given.) Writing the changes back is
+enabled with the :option:`-w` flag::
 
 $ 2to3 -w example.py
 
Modified: python/branches/py3k/Doc/library/abc.rst
==============================================================================
--- python/branches/py3k/Doc/library/abc.rst	(original)
+++ python/branches/py3k/Doc/library/abc.rst	Thu Feb 26 04:38:59 2009
@@ -150,7 +150,7 @@
 
 .. note::
 
- Unlike C++'s pure virtual functions, or Java abstract methods, these abstract
+ Unlike Java abstract methods, these abstract
 methods may have an implementation. This implementation can be
 called via the :func:`super` mechanism from the class that
 overrides it. This could be useful as an end-point for a
Modified: python/branches/py3k/Doc/library/cgi.rst
==============================================================================
--- python/branches/py3k/Doc/library/cgi.rst	(original)
+++ python/branches/py3k/Doc/library/cgi.rst	Thu Feb 26 04:38:59 2009
@@ -65,16 +65,18 @@
 
 Begin by writing ``import cgi``.
 
-When you write a new script, consider adding the line::
+When you write a new script, consider adding these lines::
 
- import cgitb; cgitb.enable()
+ import cgitb
+ cgitb.enable()
 
 This activates a special exception handler that will display detailed reports in
 the Web browser if any errors occur. If you'd rather not show the guts of your
 program to users of your script, you can have the reports saved to files
-instead, with a line like this::
+instead, with code like this::
 
- import cgitb; cgitb.enable(display=0, logdir="/tmp")
+ import cgitb
+ cgitb.enable(display=0, logdir="/tmp")
 
 It's very helpful to use this feature during script development. The reports
 produced by :mod:`cgitb` provide information that can save you a lot of time in
@@ -445,9 +447,10 @@
 
 Fortunately, once you have managed to get your script to execute *some* code,
 you can easily send tracebacks to the Web browser using the :mod:`cgitb` module.
-If you haven't done so already, just add the line::
+If you haven't done so already, just add the lines::
 
- import cgitb; cgitb.enable()
+ import cgitb
+ cgitb.enable()
 
 to the top of your script. Then try running it again; when a problem occurs,
 you should see a detailed report that will likely make apparent the cause of the
Modified: python/branches/py3k/Doc/library/cgitb.rst
==============================================================================
--- python/branches/py3k/Doc/library/cgitb.rst	(original)
+++ python/branches/py3k/Doc/library/cgitb.rst	Thu Feb 26 04:38:59 2009
@@ -24,9 +24,10 @@
 functions, to help you debug the problem. Optionally, you can save this
 information to a file instead of sending it to the browser.
 
-To enable this feature, simply add one line to the top of your CGI script::
+To enable this feature, simply add this to the top of your CGI script::
 
- import cgitb; cgitb.enable()
+ import cgitb
+ cgitb.enable()
 
 The options to the :func:`enable` function control whether the report is
 displayed in the browser and whether the report is logged to a file for later
Modified: python/branches/py3k/Doc/library/stdtypes.rst
==============================================================================
--- python/branches/py3k/Doc/library/stdtypes.rst	(original)
+++ python/branches/py3k/Doc/library/stdtypes.rst	Thu Feb 26 04:38:59 2009
@@ -793,9 +793,9 @@
 
 .. method:: str.count(sub[, start[, end]])
 
- Return the number of occurrences of substring *sub* in the range [*start*,
- *end*]. Optional arguments *start* and *end* are interpreted as in slice
- notation.
+ Return the number of non-overlapping occurrences of substring *sub* in the
+ range [*start*, *end*]. Optional arguments *start* and *end* are
+ interpreted as in slice notation.
 
 
 .. method:: str.encode([encoding[, errors]])
@@ -835,7 +835,7 @@
 found.
 
 
-.. method:: str.format(format_string, *args, **kwargs)
+.. method:: str.format(*args, **kwargs)
 
 Perform a string formatting operation. The *format_string* argument can
 contain literal text or replacement fields delimited by braces ``{}``. Each
Modified: python/branches/py3k/Doc/library/xml.etree.elementtree.rst
==============================================================================
--- python/branches/py3k/Doc/library/xml.etree.elementtree.rst	(original)
+++ python/branches/py3k/Doc/library/xml.etree.elementtree.rst	Thu Feb 26 04:38:59 2009
@@ -529,5 +529,5 @@
 .. [#] The encoding string included in XML output should conform to the
 appropriate standards. For example, "UTF-8" is valid, but "UTF8" is
 not. See http://www.w3.org/TR/2006/REC-xml11-20060816/#NT-EncodingDecl
- and http://www.iana.org/assignments/character-sets .
+ and http://www.iana.org/assignments/character-sets.
 
Modified: python/branches/py3k/Doc/whatsnew/2.5.rst
==============================================================================
--- python/branches/py3k/Doc/whatsnew/2.5.rst	(original)
+++ python/branches/py3k/Doc/whatsnew/2.5.rst	Thu Feb 26 04:38:59 2009
@@ -1761,8 +1761,8 @@
 included.
 
 The rest of this section will provide a brief overview of using ElementTree.
-Full documentation for ElementTree is available at http://effbot.org/zone
-/element-index.htm.
+Full documentation for ElementTree is available at
+http://effbot.org/zone/element-index.htm.
 
 ElementTree represents an XML document as a tree of element nodes. The text
 content of the document is stored as the :attr:`.text` and :attr:`.tail`
Modified: python/branches/py3k/Lib/socketserver.py
==============================================================================
--- python/branches/py3k/Lib/socketserver.py	(original)
+++ python/branches/py3k/Lib/socketserver.py	Thu Feb 26 04:38:59 2009
@@ -487,7 +487,7 @@
 # libraries that expect to be able to wait for their own
 # children.
 try:
- pid, status = os.waitpid(0, options=0)
+ pid, status = os.waitpid(0, 0)
 except os.error:
 pid = None
 if pid not in self.active_children: continue
Modified: python/branches/py3k/README
==============================================================================
--- python/branches/py3k/README	(original)
+++ python/branches/py3k/README	Thu Feb 26 04:38:59 2009
@@ -88,6 +88,33 @@
 used, and backported versions of certain key Python 3.x features.
 
 
+Testing
+-------
+
+To test the interpreter, type "make test" in the top-level directory.
+This runs the test set twice (once with no compiled files, once with
+the compiled files left by the previous test run). The test set
+produces some output. You can generally ignore the messages about
+skipped tests due to optional features which can't be imported.
+If a message is printed about a failed test or a traceback or core
+dump is produced, something is wrong. On some Linux systems (those
+that are not yet using glibc 6), test_strftime fails due to a
+non-standard implementation of strftime() in the C library. Please
+ignore this, or upgrade to glibc version 6.
+
+By default, tests are prevented from overusing resources like disk space and
+memory. To enable these tests, run "make testall".
+
+IMPORTANT: If the tests fail and you decide to mail a bug report,
+*don't* include the output of "make test". It is useless. Run the
+failing test manually, as follows:
+
+ ./python Lib/test/regrtest.py -v test_whatever
+
+(substituting the top of the source tree for '.' if you built in a
+different directory). This runs the test in verbose mode.
+
+
 Installing multiple versions
 ----------------------------
 


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /