]> granicus.if.org Git - python/commitdiff
Remove duplication.
authorEzio Melotti <ezio.melotti@gmail.com>
Wed, 19 Oct 2011 07:39:35 +0000 (10:39 +0300)
committerEzio Melotti <ezio.melotti@gmail.com>
Wed, 19 Oct 2011 07:39:35 +0000 (10:39 +0300)
29 files changed:
Demo/threads/sync.py
Demo/tix/tixwidgets.py
Doc/c-api/exceptions.rst
Doc/distutils/apiref.rst
Doc/howto/logging-cookbook.rst
Doc/howto/pyporting.rst
Doc/howto/webservers.rst
Doc/library/collections.rst
Doc/library/ctypes.rst
Doc/library/email.message.rst
Doc/library/email.mime.rst
Doc/library/httplib.rst
Doc/library/mailbox.rst
Doc/library/multiprocessing.rst
Doc/library/sqlite3.rst
Doc/library/stdtypes.rst
Doc/library/string.rst
Doc/library/ttk.rst
Doc/reference/compound_stmts.rst
Doc/whatsnew/2.4.rst
Lib/cookielib.py
Lib/lib-tk/Tix.py
Lib/lib-tk/turtle.py
Lib/msilib/schema.py
Lib/multiprocessing/__init__.py
Lib/rfc822.py
Lib/sched.py
Lib/test/test_urlparse.py
Lib/test/test_xmlrpc.py

index 843767ac7ae4fb8cfa5129563f74a44dda10a984..a344abea80d8efee84cd896ad8c9ff08c2649c50 100644 (file)
 #      intervening.  If there are other threads waiting to write, they
 #      are allowed to proceed only if the current thread calls
 #      .read_out; threads waiting to read are only allowed to proceed
-#      if there are are no threads waiting to write.  (This is a
+#      if there are no threads waiting to write.  (This is a
 #      weakness of the interface!)
 
 import thread
index de2e22e7eb63e8d97efba2112bc491c55b84d397..3cf34b76640c16078fe05fd9a26bd7dd5b835055 100644 (file)
@@ -659,7 +659,7 @@ Hi,
 I have implemented a new image type called "compound". It allows you
 to glue together a bunch of bitmaps, images and text strings together
 to form a bigger image. Then you can use this image with widgets that
-support the -image option. For example, you can display a text string string
+support the -image option. For example, you can display a text string
 together with a bitmap, at the same time, inside a TK button widget.
 """)
     list.pack(expand=1, fill=Tix.BOTH, padx=4, pady=6)
index a0011458bac9ccddd057f55ac28e302bf4832ac0..beedfbe1a45c348ae85725039ab552ed1badc3ee 100644 (file)
@@ -475,7 +475,7 @@ recursion depth automatically).
 
    Marks a point where a recursive C-level call is about to be performed.
 
-   If :const:`USE_STACKCHECK` is defined, this function checks if the the OS
+   If :const:`USE_STACKCHECK` is defined, this function checks if the OS
    stack overflowed using :cfunc:`PyOS_CheckStack`.  In this is the case, it
    sets a :exc:`MemoryError` and returns a nonzero value.
 
index eae9078843da00f7bd0547994dfe713c071667c4..c394eee8eabe424981a325417958dccf4f3472c1 100644 (file)
@@ -1741,7 +1741,7 @@ Subclasses of :class:`Command` must define the following methods.
    Set final values for all the options that this command supports. This is
    always called as late as possible, ie.  after any option assignments from the
    command-line or from other commands have been done.  Thus, this is the place
-   to to code option dependencies: if *foo* depends on *bar*, then it is safe to
+   to code option dependencies: if *foo* depends on *bar*, then it is safe to
    set *foo* from *bar* as long as *foo* still has the same value it was
    assigned in :meth:`initialize_options`.
 
index ad9f666d937e5252d087d2888a9ffd345d90f548..b1f5c7cf4a97b48b14e1c0d9fee0b8c93c8094b7 100644 (file)
@@ -679,6 +679,6 @@ and each time it reaches the size limit it is renamed with the suffix
 ``.1``. Each of the existing backup files is renamed to increment the suffix
 (``.1`` becomes ``.2``, etc.)  and the ``.6`` file is erased.
 
-Obviously this example sets the log length much much too small as an extreme
+Obviously this example sets the log length much too small as an extreme
 example.  You would want to set *maxBytes* to an appropriate value.
 
index 124ef33ae4b52c8c98cd8808557f0b4f1e7caa32..309f3f7a3a74b483a2438ea76fe688deeb3e25b2 100644 (file)
@@ -328,7 +328,7 @@ the bytes/string dichotomy. Because Python 2 allowed the ``str`` type to hold
 textual data, people have over the years been rather loose in their delineation
 of what ``str`` instances held text compared to bytes. In Python 3 you cannot
 be so care-free anymore and need to properly handle the difference. The key
-handling this issue to to make sure that **every** string literal in your
+handling this issue to make sure that **every** string literal in your
 Python 2 code is either syntactically of functionally marked as either bytes or
 text data. After this is done you then need to make sure your APIs are designed
 to either handle a specific type or made to be properly polymorphic.
index 03853f44abce36a83a38165dbe6ae5bff602a8d3..42cdff81e48cdb4736f0198fe397950f415beb90 100644 (file)
@@ -264,7 +264,7 @@ used for the deployment of WSGI applications.
 
    * `FastCGI, SCGI, and Apache: Background and Future
      <http://www.vmunix.com/mark/blog/archives/2006/01/02/fastcgi-scgi-and-apache-background-and-future/>`_
-     is a discussion on why the concept of FastCGI and SCGI is better that that
+     is a discussion on why the concept of FastCGI and SCGI is better than that
      of mod_python.
 
 
index 90f7e3cccfe276307ac2ba0e68fc2c391ce52724..b315a73990e7558765fd811e611059a7c36c168c 100644 (file)
@@ -188,7 +188,7 @@ counts, but the output will exclude results with counts of zero or less.
    * The multiset methods are designed only for use cases with positive values.
      The inputs may be negative or zero, but only outputs with positive values
      are created.  There are no type restrictions, but the value type needs to
-     support support addition, subtraction, and comparison.
+     support addition, subtraction, and comparison.
 
    * The :meth:`elements` method requires integer counts.  It ignores zero and
      negative counts.
index d94b04e07ec6eecf53e3b4939d64638fa706c78d..1a3e2f5c4c002ce5896cdd8f34fe8d91fcf9b10f 100644 (file)
@@ -2000,7 +2000,7 @@ Utility functions
 
 .. function:: string_at(address[, size])
 
-   This function returns the string starting at memory address address. If size
+   This function returns the string starting at memory address *address*. If size
    is specified, it is used as size, otherwise the string is assumed to be
    zero-terminated.
 
index a570d817f9110e08eebb00e98f546fd5566f8552..77ce99e50f5d2d5fa1a02d815c551ddfece2be5f 100644 (file)
@@ -295,7 +295,7 @@ Here are the methods of the :class:`Message` class:
 
          Content-Disposition: attachment; filename="bud.gif"
 
-      An example with with non-ASCII characters::
+      An example with non-ASCII characters::
 
          msg.add_header('Content-Disposition', 'attachment',
                         filename=('iso-8859-1', '', 'Fußballer.ppt'))
index a092feb5eda1be013425d6e614101292ae3b18a9..78fdc765dbbea4f570b81980998ae17574e9846f 100644 (file)
@@ -196,6 +196,6 @@ Here are the classes:
 
    .. versionchanged:: 2.4
       The previously deprecated *_encoding* argument has been removed.  Content
-      Transfer Encoding now happens happens implicitly based on the *_charset*
+      Transfer Encoding now happens implicitly based on the *_charset*
       argument.
 
index fc26f2428117f41352cb329ac964048be13091a0..58b1bb73947538116d56b5fe61dd4013bd919cb1 100644 (file)
@@ -452,7 +452,7 @@ HTTPConnection Objects
    Set the host and the port for HTTP Connect Tunnelling. Normally used when
    it is required to do HTTPS Conection through a proxy server.
 
-   The headers argument should be a mapping of extra HTTP headers to to sent
+   The headers argument should be a mapping of extra HTTP headers to sent
    with the CONNECT request.
 
    .. versionadded:: 2.7
index 92f37cbdb52cb04daae66e920cd4a322748ab5e7..d51f3405ffcd487051f6296d9be0199e48f1165f 100644 (file)
@@ -765,7 +765,7 @@ Maildir, mbox, MH, Babyl, and MMDF.
    There is no requirement that :class:`Message` instances be used to represent
    messages retrieved using :class:`Mailbox` instances. In some situations, the
    time and memory required to generate :class:`Message` representations might
-   not not acceptable. For such situations, :class:`Mailbox` instances also
+   not be acceptable. For such situations, :class:`Mailbox` instances also
    offer string and file-like representations, and a custom message factory may
    be specified when a :class:`Mailbox` instance is initialized.
 
index 30c4b1031caef32db262ec69e4854b8e3f5adca0..c0c0ae8f433bd76c13221925093bc58eb08f5717 100644 (file)
@@ -1494,7 +1494,7 @@ itself.  This means, for example, that one shared object can contain a second:
       a new shared object -- see documentation for the *method_to_typeid*
       argument of :meth:`BaseManager.register`.
 
-      If an exception is raised by the call, then then is re-raised by
+      If an exception is raised by the call, then is re-raised by
       :meth:`_callmethod`.  If some other exception is raised in the manager's
       process then this is converted into a :exc:`RemoteError` exception and is
       raised by :meth:`_callmethod`.
@@ -1617,7 +1617,7 @@ with the :class:`Pool` class.
 
       The *chunksize* argument is the same as the one used by the :meth:`.map`
       method.  For very long iterables using a large value for *chunksize* can
-      make make the job complete **much** faster than using the default value of
+      make the job complete **much** faster than using the default value of
       ``1``.
 
       Also if *chunksize* is ``1`` then the :meth:`!next` method of the iterator
index 3ef108c00c7568fb1df639036d653cbf9f005507..50a036fb646da61a0116a01183ffb66e7ee4f47b 100644 (file)
@@ -240,7 +240,7 @@ Connection Objects
 .. method:: Connection.commit()
 
    This method commits the current transaction. If you don't call this method,
-   anything you did since the last call to ``commit()`` is not visible from from
+   anything you did since the last call to ``commit()`` is not visible from
    other database connections. If you wonder why you don't see the data you've
    written to the database, please check you didn't forget to call this method.
 
index 30faddbb8f07b13104bb1d9ba3b58e7cc58edb2c..26f200df7fc85b0667cd692f18bab90a79554bcb 100644 (file)
@@ -1311,7 +1311,7 @@ The following methods are present only on unicode objects:
 
    Return ``True`` if there are only decimal characters in S, ``False``
    otherwise. Decimal characters include digit characters, and all characters
-   that that can be used to form decimal-radix numbers, e.g. U+0660,
+   that can be used to form decimal-radix numbers, e.g. U+0660,
    ARABIC-INDIC DIGIT ZERO.
 
 
index 20fcae97739f7764324cef84ac28800a1426839a..67547ad1499b30d3e9eaba80e53a4fa480da212e 100644 (file)
@@ -243,7 +243,7 @@ by a colon ``':'``.  These specify a non-default format for the replacement valu
 
 See also the :ref:`formatspec` section.
 
-The *field_name* itself begins with an *arg_name* that is either either a number or a
+The *field_name* itself begins with an *arg_name* that is either a number or a
 keyword.  If it's a number, it refers to a positional argument, and if it's a keyword,
 it refers to a named keyword argument.  If the numerical arg_names in a format string
 are 0, 1, 2, ... in sequence, they can all be omitted (not just some)
index ebfdede0a2cdf6b4c2ccea112d8afc4463c9501e..6e8ff89d5237e9fb9b2cd83f33654c953125e72f 100644 (file)
@@ -1243,7 +1243,7 @@ option. If the class name of a widget is unknown, use the method
       *layoutspec*, if specified, is expected to be a list or some other
       sequence type (excluding strings), where each item should be a tuple and
       the first item is the layout name and the second item should have the
-      format described described in `Layouts`_.
+      format described in `Layouts`_.
 
       To understand the format, see the following example (it is not
       intended to do anything useful)::
index 7015a7fde8137a42d8db9c921921a9d35a105878..c99b65a707197c243ef0c62406d6a1ad52f06c5a 100644 (file)
@@ -470,7 +470,7 @@ value --- this is a syntactic restriction that is not expressed by the grammar.
 
 **Default parameter values are evaluated when the function definition is
 executed.**  This means that the expression is evaluated once, when the function
-is defined, and that that same "pre-computed" value is used for each call.  This
+is defined, and that the same "pre-computed" value is used for each call.  This
 is especially important to understand when a default parameter is a mutable
 object, such as a list or a dictionary: if the function modifies the object
 (e.g. by appending an item to a list), the default value is in effect modified.
index fadde50184ee05334cb9a7d8026cf7572272da0c..a602f752d8887fa09e4e13b87aaff4437a12d9cc 100644 (file)
@@ -947,7 +947,7 @@ Optimizations
   :meth:`__len__` method.  (Contributed by Raymond Hettinger.)
 
 * The methods :meth:`list.__getitem__`, :meth:`dict.__getitem__`, and
-  :meth:`dict.__contains__` are are now implemented as :class:`method_descriptor`
+  :meth:`dict.__contains__` are now implemented as :class:`method_descriptor`
   objects rather than :class:`wrapper_descriptor` objects.  This form of  access
   doubles their performance and makes them more suitable for use as arguments to
   functionals: ``map(mydict.__getitem__, keylist)``. (Contributed by Raymond
index 5b250905ec5375a28838e80dabee5f7836eaf995..65214df30d1cf95fff95a4931340edfb21954f62 100644 (file)
@@ -1014,7 +1014,7 @@ class DefaultCookiePolicy(CookiePolicy):
                     (not erhn.startswith(".") and
                      not ("."+erhn).endswith(domain))):
                     _debug("   effective request-host %s (even with added "
-                           "initial dot) does not end end with %s",
+                           "initial dot) does not end with %s",
                            erhn, domain)
                     return False
             if (cookie.version > 0 or
index 210b7d23b7eaeedcf9c7ccbb7db8a73f4da01f9f..d474235e8520350a3dd0bae7d31d46bd804d8efb 100644 (file)
@@ -1874,13 +1874,13 @@ class Grid(TixWidget, XView, YView):
         return self.tk.call(self, 'info', 'bbox', x, y)
 
     def move_column(self, from_, to, offset):
-        """Moves the the range of columns from position FROM through TO by
+        """Moves the range of columns from position FROM through TO by
         the distance indicated by OFFSET. For example, move_column(2, 4, 1)
         moves the columns 2,3,4 to columns 3,4,5."""
         self.tk.call(self, 'move', 'column', from_, to, offset)
 
     def move_row(self, from_, to, offset):
-        """Moves the the range of rows from position FROM through TO by
+        """Moves the range of rows from position FROM through TO by
         the distance indicated by OFFSET.
         For example, move_row(2, 4, 1) moves the rows 2,3,4 to rows 3,4,5."""
         self.tk.call(self, 'move', 'row', from_, to, offset)
@@ -1939,7 +1939,7 @@ class Grid(TixWidget, XView, YView):
               pad0 pixels
                      Specifies the paddings to the top of a row.
               pad1 pixels
-                     Specifies the paddings to the the bottom of a row.
+                     Specifies the paddings to the bottom of a row.
               size val
                      Specifies  the height of a row.
                      Val may be: "auto" -- the height of the row  is  set  the
index 4230d6871b809e5dd8b25c260c5d313edfaf685b..e78324e59a98c6465d245c74de283abde30e58a0 100644 (file)
@@ -96,7 +96,7 @@ Roughly it has the following features added:
   docstrings to disc, so it can serve as a template for translations.
 
 Behind the scenes there are some features included with possible
-extensions in in mind. These will be commented and documented elsewhere.
+extensions in mind. These will be commented and documented elsewhere.
 
 """
 
index 51dd1777414cc1a3695408f46bbfed2bc5296078..003f04071c50bb5db534294b3853c4122611fb2c 100644 (file)
@@ -958,7 +958,7 @@ _Validation_records = [
 (u'ServiceInstall',u'StartType',u'N',0,4,None, None, None, None, u'Type of the service',),
 (u'Shortcut',u'Name',u'N',None, None, None, None, u'Filename',None, u'The name of the shortcut to be created.',),
 (u'Shortcut',u'Description',u'Y',None, None, None, None, u'Text',None, u'The description for the shortcut.',),
-(u'Shortcut',u'Component_',u'N',None, None, u'Component',1,u'Identifier',None, u'Foreign key into the Component table denoting the component whose selection gates the the shortcut creation/deletion.',),
+(u'Shortcut',u'Component_',u'N',None, None, u'Component',1,u'Identifier',None, u'Foreign key into the Component table denoting the component whose selection gates the shortcut creation/deletion.',),
 (u'Shortcut',u'Icon_',u'Y',None, None, u'Icon',1,u'Identifier',None, u'Foreign key into the File table denoting the external icon file for the shortcut.',),
 (u'Shortcut',u'IconIndex',u'Y',-32767,32767,None, None, None, None, u'The icon index for the shortcut.',),
 (u'Shortcut',u'Directory_',u'N',None, None, u'Directory',1,u'Identifier',None, u'Foreign key into the Directory table denoting the directory where the shortcut file is created.',),
index 4963293bd9fa714913b6f5bf372ce1fedd812616..2e91e8eb6ebaedf088ccb4e6ee66c661bcc598a4 100644 (file)
@@ -9,7 +9,7 @@
 # wrapper for 'threading'.
 #
 # Try calling `multiprocessing.doc.main()` to read the html
-# documentation in in a webbrowser.
+# documentation in a webbrowser.
 #
 #
 # Copyright (c) 2006-2008, R Oudkerk
index 64cd702cd0c6b7cef1d9e4adf215a69bfd823a3f..3b29a6a5d8d104f6bba4e56c9108fd5b9140e962 100644 (file)
@@ -34,7 +34,7 @@ The optional `seekable' argument is provided as a workaround for certain stdio
 libraries in which tell() discards buffered data before discovering that the
 lseek() system call doesn't work.  For maximum portability, you should set the
 seekable argument to zero to prevent that initial \code{tell} when passing in
-an unseekable object such as a file object created from a socket object.  If
+an unseekable object such as a file object created from a socket object.  If
 it is 1 on entry -- which it is by default -- the tell() method of the open
 file object is called once; if this raises an exception, seekable is reset to
 0.  For other nonzero values of seekable, this test is not made.
index f0da8291fe9ab1da69931710b2240b2c3150c37d..47646a10081143103f6a4070321207d7848d5435 100644 (file)
@@ -88,7 +88,7 @@ class scheduler:
         restarted.
 
         It is legal for both the delay function and the action
-        function to to modify the queue or to raise an exception;
+        function to modify the queue or to raise an exception;
         exceptions are not caught but the scheduler's state remains
         well-defined so run() may be called again.
 
index c690a67e985d6fbc4ed98fef5349fcc43f4662ac..39a897a1a91cead77cbd8f23c4f6b714792357be 100644 (file)
@@ -9,7 +9,7 @@ RFC2396_BASE = "http://a/b/c/d;p?q"
 RFC3986_BASE = 'http://a/b/c/d;p?q'
 SIMPLE_BASE  = 'http://a/b/c/d'
 
-# A list of test cases.  Each test case is a two-tuple that contains
+# A list of test cases.  Each test case is a two-tuple that contains
 # a string with the query and a dictionary with the expected result.
 
 parse_qsl_test_cases = [
index 79100e9a538b56e7268dd9af8194c886f0387a71..c88a1eeaeea301565a80968efc4f7a1a309d337b 100644 (file)
@@ -308,7 +308,7 @@ def http_server(evt, numrequests, requestHandler=None):
         global ADDR, PORT, URL
         ADDR, PORT = serv.socket.getsockname()
         #connect to IP address directly.  This avoids socket.create_connection()
-        #trying to connect to to "localhost" using all address families, which
+        #trying to connect to "localhost" using all address families, which
         #causes slowdown e.g. on vista which supports AF_INET6.  The server listens
         #on AF_INET only.
         URL = "http://%s:%d"%(ADDR, PORT)
@@ -367,7 +367,7 @@ def http_multi_server(evt, numrequests, requestHandler=None):
         global ADDR, PORT, URL
         ADDR, PORT = serv.socket.getsockname()
         #connect to IP address directly.  This avoids socket.create_connection()
-        #trying to connect to to "localhost" using all address families, which
+        #trying to connect to "localhost" using all address families, which
         #causes slowdown e.g. on vista which supports AF_INET6.  The server listens
         #on AF_INET only.
         URL = "http://%s:%d"%(ADDR, PORT)