cpython: ce5ef48b5140 (original) (raw)

--- a/Doc/distributing/index.rst +++ b/Doc/distributing/index.rst @@ -35,7 +35,7 @@ Key terms repository of open source licensed packages made available for use by other Python users

How do I...? @@ -160,11 +160,11 @@ Python Packaging User Guide for more inf .. seealso:: `Python Packaging User Guide: Binary Extensions

.. other topics: Once the Development & Deployment part of PPUG is fleshed out, some of those sections should be linked from new questions here (most notably, we should have a question about avoiding depending on PyPI that links to

--- a/Doc/distutils/apiref.rst +++ b/Doc/distutils/apiref.rst @@ -1822,7 +1822,7 @@ Subclasses of :class:Command must defi Builds a Windows Installer_ (.msi) binary package.

--- a/Doc/extending/extending.rst +++ b/Doc/extending/extending.rst @@ -27,7 +27,7 @@ your system setup; details are given in avoid writing C extensions and preserve portability to other implementations. For example, if your use case is calling C library functions or system calls, you should consider using the :mod:ctypes module or the `cffi

--- a/Doc/extending/index.rst +++ b/Doc/extending/index.rst @@ -32,7 +32,7 @@ approaches to creating C and C++ extensi .. seealso::

--- a/Doc/faq/design.rst +++ b/Doc/faq/design.rst @@ -370,7 +370,7 @@ Practical answer: Cython <http://cython.org/>_ and Pyrex <http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/> compile a modified version of Python with optional annotations into C -extensions. Weave <http://docs.scipy.org/doc/scipy-dev/reference/tutorial/weave.html> makes it easy to +extensions. Weave <https://scipy.github.io/devdocs/tutorial/weave.html>_ makes it easy to intermingle Python and C code in various ways to increase performance. Nuitka <http://www.nuitka.net/>_ is an up-and-coming compiler of Python into C++ code, aiming to support the full Python language.

--- a/Doc/faq/extending.rst +++ b/Doc/faq/extending.rst @@ -50,10 +50,10 @@ to learn Python's C API. If you need to interface to some C or C++ library for which no Python extension currently exists, you can try wrapping the library's data types and functions with a tool such as SWIG <http://www.swig.org>. SIP[](#l6.6) -<http://www.riverbankcomputing.co.uk/software/sip/intro>, CXX[](#l6.7) +<https://riverbankcomputing.com/software/sip/intro>, CXX[](#l6.8) <http://cxx.sourceforge.net/> Boost[](#l6.9) <http://www.boost.org/libs/python/doc/index.html>, or Weave[](#l6.10) -<http://docs.scipy.org/doc/scipy-dev/reference/tutorial/weave.html> are also +https://scipy.github.io/devdocs/tutorial/weave.html`_ are also alternatives for wrapping C++ libraries.

--- a/Doc/faq/general.rst +++ b/Doc/faq/general.rst @@ -159,7 +159,7 @@ How do I obtain a copy of the Python sou -------------------------------------------- The latest Python source distribution is always available from python.org, at -https://www.python.org/download/. The latest development sources can be obtained +https://www.python.org/downloads/. The latest development sources can be obtained via anonymous Mercurial access at https://hg.python.org/cpython.[](#l7.9) The source distribution is a gzipped tar file containing the complete C source, @@ -218,7 +218,7 @@ can be found at https://www.python.org/c[](#l7.12) How do I get a beta test version of Python? ------------------------------------------- -Alpha and beta releases are available from https://www.python.org/download/. All +Alpha and beta releases are available from https://www.python.org/downloads/. All releases are announced on the comp.lang.python and comp.lang.python.announce newsgroups and on the Python home page at https://www.python.org/; an RSS feed of news is available. @@ -273,7 +273,7 @@ The Python project's infrastructure is l www.python.org <https://www.python.org>_ is graciously hosted by Rackspace[](#l7.22) <http://www.rackspace.com>, with CDN caching provided by Fastly[](#l7.23) <https://www.fastly.com>. Upfront Systems[](#l7.24) -<http://www.upfrontsystems.co.za>_ hosts bugs.python.org[](#l7.25) +<http://www.upfrontsystems.co.za/>_ hosts bugs.python.org[](#l7.26) <https://bugs.python.org>. Many other Python services like the Wiki[](#l7.27) <https://wiki.python.org> are hosted by Oregon State[](#l7.28) University Open Source Lab <https://osuosl.org>. @@ -284,7 +284,7 @@ Why is it called Python? When he began implementing Python, Guido van Rossum was also reading the published scripts from "Monty Python's Flying Circus"[](#l7.33) -<http://en.wikipedia.org/wiki/Monty_Python>__, a BBC comedy series from the 1970s. Van Rossum +https://en.wikipedia.org/wiki/Monty_Python__, a BBC comedy series from the 1970s. Van Rossum[](#l7.35) thought he needed a name that was short, unique, and slightly mysterious, so he[](#l7.36) decided to call the language Python.[](#l7.37) [](#l7.38) @@ -313,7 +313,7 @@ guaranteed that interfaces will remain t[](#l7.39) releases.[](#l7.40) [](#l7.41) The latest stable releases can always be found on the Python download page -https://www.python.org/download/_. There are two recommended production-ready[](#l7.43) +<https://www.python.org/downloads/>. There are two recommended production-ready versions at this point in time, because at the moment there are two branches of stable releases: 2.x and 3.x. Python 3.x may be less useful than 2.x, since currently there is more third party software available for Python 2 than for @@ -345,7 +345,7 @@ different companies and organizations. High-profile Python projects include the Mailman mailing list manager[](#l7.49) <http://www.list.org>_ and the Zope application server[](#l7.50) <http://www.zope.org>. Several Linux distributions, most notably Red Hat[](#l7.51) -<http://www.redhat.com>, have written part or all of their installer and +https://www.redhat.com`_, have written part or all of their installer and system administration software in Python. Companies that use Python internally include Google, Yahoo, and Lucasfilm Ltd.

--- a/Doc/faq/gui.rst +++ b/Doc/faq/gui.rst @@ -29,7 +29,7 @@ Tkinter Standard builds of Python include an object-oriented interface to the Tcl/Tk widget set, called :ref:tkinter <Tkinter>. This is probably the easiest to install (since it comes included with most -binary distributions <https://www.python.org/download/>_ of Python) and use. +binary distributions <https://www.python.org/downloads/>_ of Python) and use. For more info about Tk, including pointers to the source, see the Tcl/Tk home page <http://www.tcl.tk>. Tcl/Tk is fully portable to the Mac OS X, Windows, and Unix platforms. @@ -58,19 +58,19 @@ Qt --- There are bindings available for the Qt toolkit (using either PyQt[](#l8.15) -<http://www.riverbankcomputing.co.uk/software/pyqt/intro> or PySide[](#l8.16) -<http://www.pyside.org/>) and for KDE (PyKDE <https://techbase.kde.org/Development/Languages/Python>__). +https://riverbankcomputing.com/software/pyqt/intro_ or PySide +https://wiki.qt.io/PySide_) and for KDE (PyKDE https://techbase.kde.org/Development/Languages/Python__).[](#l8.19) PyQt is currently more mature than PySide, but you must buy a PyQt license from[](#l8.20) -Riverbank Computing http://www.riverbankcomputing.co.uk/software/pyqt/license_[](#l8.21) +Riverbank Computing https://www.riverbankcomputing.com/commercial/license-faq_[](#l8.22) if you want to write proprietary applications. PySide is free for all applications.[](#l8.23) [](#l8.24) Qt 4.5 upwards is licensed under the LGPL license; also, commercial licenses[](#l8.25) -are available from The Qt Company http://www.qt.io/licensing/_.[](#l8.26) +are available from The Qt Company https://www.qt.io/licensing/_.[](#l8.27) [](#l8.28) Gtk+[](#l8.29) ----[](#l8.30) [](#l8.31) -The GObject introspection bindings https://live.gnome.org/PyGObject_[](#l8.32) +The GObject introspection bindings https://wiki.gnome.org/Projects/PyGObject_[](#l8.33) for Python allow you to write GTK+ 3 applications. There is also a[](#l8.34) Python GTK+ 3 Tutorial http://python-gtk-3-tutorial.readthedocs.org/en/latest/`.

--- a/Doc/faq/library.rst +++ b/Doc/faq/library.rst @@ -619,7 +619,7 @@ For Win32, POSIX (Linux, BSD, etc.), Jyt For Unix, see a Usenet post by Mitch Chapman:

Why doesn't closing sys.stdout (stdin, stderr) really close it?

--- a/Doc/faq/programming.rst +++ b/Doc/faq/programming.rst @@ -63,7 +63,7 @@ PyChecker is a static analysis tool that warns about code complexity and style. You can get PyChecker from http://pychecker.sourceforge.net/.[](#l10.5) -Pylint <http://www.logilab.org/projects/pylint>_ is another tool that checks +Pylint <http://www.pylint.org/>_ is another tool that checks if a module satisfies a coding standard, and also makes it possible to write plug-ins to add a custom feature. In addition to the bug checking that PyChecker performs, Pylint offers some additional features such as checking line

--- a/Doc/howto/curses.rst +++ b/Doc/howto/curses.rst @@ -545,7 +545,7 @@ learn more about submitting patches to P a lengthy tutorial for C programmers.

--- a/Doc/howto/functional.rst +++ b/Doc/howto/functional.rst @@ -332,7 +332,7 @@ substring. List comprehensions and generator expressions (short form: "listcomps" and "genexps") are a concise notation for such operations, borrowed from the -functional programming language Haskell (http://www.haskell.org/). You can strip +functional programming language Haskell (https://www.haskell.org/). You can strip all the whitespace from a stream of strings with the following code:: line_list = [' line 1\n', 'line 2 \n', ...] @@ -716,7 +716,7 @@ returns them in a tuple:: It doesn't construct an in-memory list and exhaust all the input iterators before returning; instead tuples are constructed and returned only if they're requested. (The technical term for this behaviour is lazy evaluation[](#l12.15) -<http://en.wikipedia.org/wiki/Lazy_evaluation>.) +https://en.wikipedia.org/wiki/Lazy_evaluation`.) This iterator is intended to be used with iterables that are all of the same length. If the iterables are of different lengths, the resulting stream will be @@ -1199,7 +1199,7 @@ General Structure and Interpretation of Computer Programs, by Harold Abelson and Gerald Jay Sussman with Julie Sussman. Full text at -http://mitpress.mit.edu/sicp/. In this classic textbook of computer science, +https://mitpress.mit.edu/sicp/. In this classic textbook of computer science, chapters 2 and 3 discuss the use of sequences and streams to organize the data flow inside a program. The book uses Scheme for its examples, but many of the design approaches described in these chapters are applicable to functional-style @@ -1208,12 +1208,12 @@ Python code. http://www.defmacro.org/ramblings/fp.html: A general introduction to functional programming that uses Java examples and has a lengthy historical introduction. -http://en.wikipedia.org/wiki/Functional_programming: General Wikipedia entry +https://en.wikipedia.org/wiki/Functional_programming: General Wikipedia entry describing functional programming. -http://en.wikipedia.org/wiki/Coroutine: Entry for coroutines. +https://en.wikipedia.org/wiki/Coroutine: Entry for coroutines. -http://en.wikipedia.org/wiki/Currying: Entry for the concept of currying. +https://en.wikipedia.org/wiki/Currying: Entry for the concept of currying. Python-specific ---------------

--- a/Doc/howto/logging-cookbook.rst +++ b/Doc/howto/logging-cookbook.rst @@ -1316,7 +1316,7 @@ An example dictionary-based configuratio ----------------------------------------- Below is an example of a logging configuration dictionary - it's taken from -the documentation on the Django project <https://docs.djangoproject.com/en/1.3/topics/logging/#configuring-logging>. +the documentation on the Django project <https://docs.djangoproject.com/en/1.4/topics/logging/#configuring-logging>. This dictionary is passed to :func:~config.dictConfig to put the configuration into effect:: LOGGING = {

--- a/Doc/howto/logging.rst +++ b/Doc/howto/logging.rst @@ -310,7 +310,7 @@ favourite beverage and carry on. If your logging needs are simple, then use the above examples to incorporate logging into your own scripts, and if you run into problems or don't understand something, please post a question on the comp.lang.python Usenet -group (available at http://groups.google.com/group/comp.lang.python) and you +group (available at https://groups.google.com/group/comp.lang.python) and you should receive help before too long. Still here? You can carry on reading the next few sections, which provide a

--- a/Doc/howto/sorting.rst +++ b/Doc/howto/sorting.rst @@ -127,7 +127,7 @@ Sort Stability and Complex Sorts ================================ Sorts are guaranteed to be stable[](#l15.6) -<http://en.wikipedia.org/wiki/Sorting_algorithm#Stability>_. That means that +https://en.wikipedia.org/wiki/Sorting_algorithm#Stability_\. That means that[](#l15.8) when multiple records have the same key, their original order is preserved.[](#l15.9) [](#l15.10) >>> data = [('red', 1), ('blue', 1), ('red', 2), ('blue', 2)][](#l15.11) @@ -145,7 +145,7 @@ ascending *age*, do the *age* sort first[](#l15.12) >>> sorted(s, key=attrgetter('grade'), reverse=True) # now sort on primary key, descending[](#l15.13) [('dave', 'B', 10), ('jane', 'B', 12), ('john', 'A', 15)][](#l15.14) [](#l15.15) -The Timsort http://en.wikipedia.org/wiki/Timsort_ algorithm used in Python[](#l15.16) +The Timsort https://en.wikipedia.org/wiki/Timsort_ algorithm used in Python[](#l15.17) does multiple sorts efficiently because it can take advantage of any ordering[](#l15.18) already present in a dataset.[](#l15.19) [](#l15.20) @@ -184,7 +184,7 @@ decorated list, but including it gives t[](#l15.21) directly.[](#l15.22) [](#l15.23) Another name for this idiom is[](#l15.24) -Schwartzian transform http://en.wikipedia.org/wiki/Schwartzian_transform_\,[](#l15.25) +Schwartzian transform https://en.wikipedia.org/wiki/Schwartzian_transform`_, after Randal L. Schwartz, who popularized it among Perl programmers. Now that Python sorting provides key-functions, this technique is not often needed.

--- a/Doc/howto/unicode.rst +++ b/Doc/howto/unicode.rst @@ -73,7 +73,7 @@ revision of Unicode. precise historical details aren't necessary for understanding how to use Unicode effectively, but if you're curious, consult the Unicode consortium site listed in the References or -the Wikipedia entry for Unicode <http://en.wikipedia.org/wiki/Unicode#History> +the Wikipedia entry for Unicode <https://en.wikipedia.org/wiki/Unicode#History> for more information.) @@ -223,8 +223,8 @@ If this introduction didn't make things reading this alternate article before continuing. Wikipedia entries are often helpful; see the entries for "character encoding[](#l16.15) -<http://en.wikipedia.org/wiki/Character_encoding>" and UTF-8[](#l16.16) -<http://en.wikipedia.org/wiki/UTF-8>, for example. +https://en.wikipedia.org/wiki/Character_encoding_" and UTF-8 +https://en.wikipedia.org/wiki/UTF-8`_, for example. Python's Unicode Support

--- a/Doc/howto/webservers.rst +++ b/Doc/howto/webservers.rst @@ -267,7 +267,7 @@ Setting up FastCGI Each web server requires a specific module.

A really great WSGI feature is middleware. Middleware is a layer around your program which can add various functionality to it. There is quite a bit of -middleware <http://www.wsgi.org/en/latest/libraries.html>_ already +middleware <https://wsgi.readthedocs.org/en/latest/libraries.html>_ already available. For example, instead of writing your own session management (HTTP is a stateless protocol, so to associate multiple HTTP requests with a single user your application must create and manage such state via a session), you can @@ -379,7 +379,7 @@ WSGI Servers The code that is used to connect to various low level gateways like CGI or mod_python is called a WSGI server. One of these servers is flup, which supports FastCGI and SCGI, as well as AJP[](#l17.44) -<http://en.wikipedia.org/wiki/Apache_JServ_Protocol>_. Some of these servers +https://en.wikipedia.org/wiki/Apache_JServ_Protocol_. Some of these servers[](#l17.46) are written in Python, as ``flup`` is, but there also exist others which are[](#l17.47) written in C and can be used as drop-in replacements.[](#l17.48) [](#l17.49) @@ -390,8 +390,8 @@ compared with other web technologies.[](#l17.50) .. seealso::[](#l17.51) [](#l17.52) A good overview of WSGI-related code can be found in the WSGI homepage

One of the most widely used wiki software packages is MoinMoin[](#l17.64) -<http://moinmo.in/>_. It was created in 2000, so it predates WSGI by about +https://moinmo.in/_. It was created in 2000, so it predates WSGI by about[](#l17.66) three years. Older versions needed separate code to run on CGI, mod_python,[](#l17.67) FastCGI and standalone.[](#l17.68) [](#l17.69) @@ -460,7 +460,7 @@ maintainable web sites.[](#l17.70) .. seealso::[](#l17.71) [](#l17.72) The English Wikipedia has an article about the Model-View-Controller pattern

@@ -543,10 +543,10 @@ module, and which uses only one file. I smaller sites SQLite is just enough. Relational databases are queried using a language called SQL[](#l17.82) -<http://en.wikipedia.org/wiki/SQL>. Python programmers in general do not +https://en.wikipedia.org/wiki/SQL_. Python programmers in general do not[](#l17.84) like SQL too much, as they prefer to work with objects. It is possible to save[](#l17.85) Python objects into a database using a technology called ORM -http://en.wikipedia.org/wiki/Object-relational_mapping_ (Object Relational[](#l17.87) +<https://en.wikipedia.org/wiki/Object-relational_mapping> (Object Relational Mapping). ORM translates all object-oriented access into SQL code under the hood, so the developer does not need to think about it. Most frameworks_ use ORMs, and it works quite well. @@ -579,13 +579,13 @@ alternate storage mechanism. helps with choosing a method for saving data * SQLAlchemy <http://www.sqlalchemy.org/>_, the most powerful OR-Mapper

* SQLObject <http://www.sqlobject.org/>, another popular OR-Mapper * ZODB <https://launchpad.net/zodb> and `Durus

@@ -671,10 +671,10 @@ experience. TurboGears gives the user f example the ORM and template engine can be changed to use packages different from those used by default. -The documentation can be found in the TurboGears wiki[](#l17.112) -<http://docs.turbogears.org/>, where links to screencasts can be found. +The documentation can be found in the TurboGears documentation[](#l17.114) +<https://turbogears.readthedocs.org/>, where links to screencasts can be found. TurboGears has also an active user community which can respond to most related -questions. There is also a TurboGears book <http://turbogearsbook.com/> +questions. There is also a TurboGears book <http://turbogears.org/1.0/docs/TGBooks.html> published, which is a good starting point. The newest version of TurboGears, version 2.0, moves even further in direction

--- a/Doc/installing/index.rst +++ b/Doc/installing/index.rst @@ -48,7 +48,7 @@ Key terms repository of open source licensed packages made available for use by other Python users

How do I ...? @@ -123,8 +123,8 @@ User Guide. .. seealso::

.. installing-per-user-installation: @@ -143,13 +143,13 @@ A number of scientific Python packages h aren't currently easy to install using pip directly. At this point in time, it will often be easier for users to install these packages by other means[](#l18.35) -<https://packaging.python.org/en/latest/science.html>__ +https://packaging.python.org/en/latest/science/__[](#l18.37) rather than attempting to install them with ``pip``.[](#l18.38) [](#l18.39) .. seealso::[](#l18.40) [](#l18.41) Python Packaging User Guide: Installing Scientific Packages

... work with multiple versions of Python installed in parallel? @@ -179,7 +179,7 @@ switch:: Once the Development & Deployment part of PPUG is fleshed out, some of those sections should be linked from new questions here (most notably, we should have a question about avoiding depending on PyPI that links to

Common installation issues @@ -212,11 +212,11 @@ as users are more regularly able to inst than needing to build them themselves. Some of the solutions for installing scientific software[](#l18.60) -<https://packaging.python.org/en/latest/science.html>__ +https://packaging.python.org/en/latest/science/__[](#l18.62) that is not yet available as pre-built ``wheel`` files may also help with[](#l18.63) obtaining other binary extensions without needing to build them locally.[](#l18.64) [](#l18.65) .. seealso::[](#l18.66) [](#l18.67) Python Packaging User Guide: Binary Extensions

--- a/Doc/library/asyncio-eventloops.rst +++ b/Doc/library/asyncio-eventloops.rst @@ -41,7 +41,7 @@ asyncio currently provides two implement On Windows, only sockets are supported (ex: pipes are not supported): see the `MSDN documentation of select

.. class:: ProactorEventLoop @@ -53,7 +53,7 @@ asyncio currently provides two implement .. seealso:: `MSDN documentation on I/O Completion Ports

Example to use a :class:ProactorEventLoop on Windows:: @@ -107,7 +107,7 @@ Common limits of Windows event loops: The resolution of the monotonic clock on Windows is usually around 15.6 msec. The best resolution is 0.5 msec. The resolution depends on the hardware (availability of HPET[](#l19.24) -<http://en.wikipedia.org/wiki/High_Precision_Event_Timer>_) and on the Windows +https://en.wikipedia.org/wiki/High_Precision_Event_Timer_) and on the Windows[](#l19.26) configuration. See :ref:asyncio delayed calls `. .. versionchanged:: 3.5

--- a/Doc/library/asyncio-subprocess.rst +++ b/Doc/library/asyncio-subprocess.rst @@ -51,7 +51,7 @@ Create a subprocess: high-level API usin It is the application's responsibility to ensure that all whitespace and metacharacters are quoted appropriately to avoid `shell injection

--- a/Doc/library/collections.rst +++ b/Doc/library/collections.rst @@ -374,12 +374,12 @@ or subtracting from an empty counter. .. seealso::

--- a/Doc/library/dbm.rst +++ b/Doc/library/dbm.rst @@ -7,7 +7,7 @@ :mod:dbm is a generic interface to variants of the DBM database --- :mod:dbm.gnu or :mod:dbm.ndbm. If none of these modules is installed, the slow-but-simple implementation in module :mod:dbm.dumb will be used. There -is a third party interface <http://www.jcea.es/programacion/pybsddb.htm>_ to +is a third party interface <https://www.jcea.es/programacion/pybsddb.htm>_ to the Oracle Berkeley DB.

--- a/Doc/library/decimal.rst +++ b/Doc/library/decimal.rst @@ -109,9 +109,6 @@ reset them before monitoring a calculati * IBM's General Decimal Arithmetic Specification, The General Decimal Arithmetic[](#l23.4) Specification <http://speleotrove.com/decimal/decarith.html>_.

- .. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

--- a/Doc/library/email.generator.rst +++ b/Doc/library/email.generator.rst @@ -43,7 +43,7 @@ Here are the public methods of the :clas followed by a space at the beginning of the line. This is the only guaranteed portable way to avoid having such lines be mistaken for a Unix mailbox format envelope header separator (see `WHY THE CONTENT-LENGTH FORMAT IS BAD

@@ -123,7 +123,7 @@ formatted string representation of a mes i.e. From followed by a space at the beginning of the line. This is the only guaranteed portable way to avoid having such lines be mistaken for a Unix mailbox format envelope header separator (see `WHY THE CONTENT-LENGTH

--- a/Doc/library/functions.rst +++ b/Doc/library/functions.rst @@ -1418,7 +1418,7 @@ are always available. They are listed h For practical suggestions on how to design cooperative classes using :func:super, see `guide to using super()

.. _func-tuple:

--- a/Doc/library/functools.rst +++ b/Doc/library/functools.rst @@ -73,7 +73,7 @@ The :mod:functools module defines the bypassing the cache, or for rewrapping the function with a different cache. An `LRU (least recently used) cache

Example of efficiently computing

--- a/Doc/library/heapq.rst +++ b/Doc/library/heapq.rst @@ -132,7 +132,7 @@ the iterable into an actual heap. Basic Examples -------------- -A heapsort <http://en.wikipedia.org/wiki/Heapsort>_ can be implemented by +A heapsort <https://en.wikipedia.org/wiki/Heapsort>_ can be implemented by pushing all values onto a heap and then popping off the smallest values one at a time:: @@ -163,7 +163,7 @@ Heap elements can be tuples. This is us Priority Queue Implementation Notes ----------------------------------- -A priority queue <http://en.wikipedia.org/wiki/Priority_queue>_ is common use +A priority queue <https://en.wikipedia.org/wiki/Priority_queue>_ is common use for a heap, and it presents several implementation challenges:

--- a/Doc/library/http.client.rst +++ b/Doc/library/http.client.rst @@ -21,7 +21,7 @@ HTTPS protocols. It is normally not use .. seealso::

--- a/Doc/library/itertools.rst +++ b/Doc/library/itertools.rst @@ -117,7 +117,7 @@ loops that truncate the stream. :func:min for a running minimum, :func:max for a running maximum, or :func:operator.mul for a running product. Amortization tables can be built by accumulating interest and applying payments. First-order

--- a/Doc/library/json.rst +++ b/Doc/library/json.rst @@ -10,7 +10,7 @@ :rfc:7159 (which obsoletes :rfc:4627) and by ECMA-404 <http://www.ecma-international.org/publications/standards/Ecma-404.htm>, is a lightweight data interchange format inspired by -JavaScript <http://en.wikipedia.org/wiki/JavaScript> object literal syntax +JavaScript <https://en.wikipedia.org/wiki/JavaScript>_ object literal syntax (although it is not a strict subset of JavaScript [#rfc-errata]_ ). :mod:json exposes an API familiar to users of the standard library

--- a/Doc/library/logging.rst +++ b/Doc/library/logging.rst @@ -1246,7 +1246,7 @@ with the :mod:warnings module. The proposal which described this feature for inclusion in the Python standard library.

--- a/Doc/library/mailbox.rst +++ b/Doc/library/mailbox.rst @@ -484,7 +484,7 @@ Supported mailbox formats are Maildir, m mbox man page from tin <http://www.tin.org/bin/man.cgi?section=5&topic=mbox>_ Another specification of the format, with details on locking.

--- a/Doc/library/math.rst +++ b/Doc/library/math.rst @@ -97,7 +97,7 @@ Number-theoretic and representation func For further discussion and two alternative approaches, see the `ASPN cookbook recipes for accurate floating point summation

.. function:: gcd(a, b) @@ -204,7 +204,7 @@ Power and logarithmic functions Return e**x - 1. For small floats x, the subtraction in exp(x) - 1 can result in a `significant loss of precision

-Hyperbolic functions <http://en.wikipedia.org/wiki/Hyperbolic_function> +Hyperbolic functions <https://en.wikipedia.org/wiki/Hyperbolic_function> are analogs of trigonometric functions that are based on hyperbolas instead of circles. @@ -371,12 +371,12 @@ Special functions .. function:: erf(x)

@@ -388,17 +388,17 @@ Special functions .. function:: erfc(x) Return the complementary error function at x. The `complementary error

.. function:: gamma(x)

--- a/Doc/library/msilib.rst +++ b/Doc/library/msilib.rst @@ -120,9 +120,9 @@ structures. .. seealso::

.. _database-objects: @@ -151,9 +151,9 @@ Database Objects .. seealso::

.. _view-objects: @@ -199,11 +199,11 @@ View Objects .. seealso::

.. _summary-objects: @@ -243,10 +243,10 @@ Summary Information Objects .. seealso::

.. _record-objects: @@ -297,11 +297,11 @@ Record Objects .. seealso::

.. _msi-errors: @@ -393,10 +393,10 @@ Directory Objects .. seealso::

.. _features: @@ -421,7 +421,7 @@ Features .. seealso::

.. _msi-gui: @@ -516,13 +516,13 @@ for installing Python packages. .. seealso::

.. _msi-tables:

--- a/Doc/library/os.rst +++ b/Doc/library/os.rst @@ -894,7 +894,7 @@ The following constants are options for :func:~os.open function. They can be combined using the bitwise OR operator |. Some of them are not available on all platforms. For descriptions of their availability and use, consult the :manpage:open(2) manual page on Unix -or the MSDN <http://msdn.microsoft.com/en-us/library/z0kc8e3z.aspx>_ on Windows. +or the MSDN <https://msdn.microsoft.com/en-us/library/z0kc8e3z.aspx>_ on Windows. .. data:: O_RDONLY @@ -1907,9 +1907,9 @@ features: and readdir() <http://pubs.opengroup.org/onlinepubs/009695399/functions/readdir_r.html>_ functions. On Windows, it uses the Win32

.. versionadded:: 3.5

--- a/Doc/library/othergui.rst +++ b/Doc/library/othergui.rst @@ -8,33 +8,33 @@ available for Python: .. seealso::

PyGTK <http://www.pygtk.org/>_ provides bindings for an older version of the library, GTK+ 2. It provides an object oriented interface that is slightly higher level than the C one. There are also bindings to

PyGTK, PyQt, and wxPython, all have a modern look and feel and more

--- a/Doc/library/random.rst +++ b/Doc/library/random.rst @@ -267,7 +267,7 @@ Alternative Generator: `Complementary-Multiply-with-Carry recipe

--- a/Doc/library/re.rst +++ b/Doc/library/re.rst @@ -1389,7 +1389,7 @@ functionally identical: Writing a Tokenizer ^^^^^^^^^^^^^^^^^^^ -A tokenizer or scanner <http://en.wikipedia.org/wiki/Lexical_analysis> +A tokenizer or scanner <https://en.wikipedia.org/wiki/Lexical_analysis> analyzes a string to categorize groups of characters. This is a useful first step in writing a compiler or interpreter.

--- a/Doc/library/shelve.rst +++ b/Doc/library/shelve.rst @@ -76,7 +76,7 @@ Two additional methods are supported: .. seealso::

@@ -137,7 +137,7 @@ Restrictions A subclass of :class:Shelf which exposes :meth:first, :meth:!next, :meth:previous, :meth:last and :meth:set_location which are available in the third-party :mod:bsddb module from `pybsddb

--- a/Doc/library/socket.rst +++ b/Doc/library/socket.rst @@ -983,7 +983,7 @@ to sockets. The :meth:ioctl method is a limited interface to the WSAIoctl system interface. Please refer to the `Win32 documentation

--- a/Doc/library/ssl.rst +++ b/Doc/library/ssl.rst @@ -206,7 +206,7 @@ instead. The ciphers parameter sets the available ciphers for this SSL object. It should be a string in the `OpenSSL cipher list format

@@ -1212,7 +1212,7 @@ to speed up repeated connections from th Set the available ciphers for sockets created with this context. It should be a string in the `OpenSSL cipher list format

@@ -2019,7 +2019,7 @@ enabled when negotiating a SSL session i :meth:SSLContext.set_ciphers method. Starting from Python 3.2.3, the ssl module disables certain weak ciphers by default, but you may want to further restrict the cipher choice. Be sure to read OpenSSL's documentation -about the cipher list format <http://www.openssl.org/docs/apps/ciphers.html#CIPHER_LIST_FORMAT>. +about the cipher list format <http://www.openssl.org/docs/apps/ciphers.html#CIPHER-LIST-FORMAT>. If you want to check which ciphers are enabled by a given cipher list, use the openssl ciphers command on your system. @@ -2040,25 +2040,25 @@ successful call of :func:~ssl.RAND_add Class :class:socket.socket Documentation of underlying :mod:socket class

IANA TLS: Transport Layer Security (TLS) Parameters <http://www.iana.org/assignments/tls-parameters/tls-parameters.xml>_

--- a/Doc/library/stat.rst +++ b/Doc/library/stat.rst @@ -403,7 +403,7 @@ See the *BSD or Mac OS systems man page On Windows, the following file attribute constants are available for use when testing bits in the st_file_attributes member returned by :func:os.stat. See the Windows API documentation[](#l42.6) -<http://msdn.microsoft.com/en-us/library/windows/desktop/gg258117.aspx> +https://msdn.microsoft.com/en-us/library/windows/desktop/gg258117.aspx` for more detail on the meaning of these constants. .. data:: FILE_ATTRIBUTE_ARCHIVE

--- a/Doc/library/subprocess.rst +++ b/Doc/library/subprocess.rst @@ -475,7 +475,7 @@ functions. execute. On Windows, in order to run a side-by-side assembly_ the specified env must include a valid :envvar:SystemRoot.

When using shell=True, the :func:shlex.quote function can be @@ -721,7 +721,7 @@ on Windows. .. class:: STARTUPINFO() Partial support of the Windows

--- a/Doc/library/test.rst +++ b/Doc/library/test.rst @@ -619,7 +619,7 @@ The :mod:test.support module defines t are expected to crash a subprocess. On Windows, it disables Windows Error Reporting dialogs using

--- a/Doc/library/tkinter.rst +++ b/Doc/library/tkinter.rst @@ -31,13 +31,13 @@ this should open a window demonstrating Tcl/Tk manual <http://www.tcl.tk/man/tcl8.5/>_ Official manual for the latest tcl/tk version.

--- a/Doc/library/unittest.mock-examples.rst +++ b/Doc/library/unittest.mock-examples.rst @@ -549,7 +549,7 @@ Calls to the date constructor are record An alternative way of dealing with mocking dates, or other builtin classes, is discussed in this blog entry[](#l46.6) -<http://www.williamjohnbert.com/2011/07/how-to-unit-testing-in-django-with-mocking-and-patching/>. +http://williambert.online/2011/07/how-to-unit-testing-in-django-with-mocking-and-patching/_.[](#l46.8) [](#l46.9) [](#l46.10) Mocking a Generator Method[](#l46.11) @@ -1251,7 +1251,7 @@ With a bit of tweaking you could have th[](#l46.12) :exc:AssertionErrordirectly and provide a more useful failure message.[](#l46.13) [](#l46.14) As of version 1.5, the Python testing libraryPyHamcrest -https://pypi.python.org/pypi/PyHamcrest_ provides similar functionality,[](#l46.16) +<https://pyhamcrest.readthedocs.org/> provides similar functionality, that may be useful here, in the form of its equality matcher (hamcrest.library.integration.match_equality[](#l46.19) -<http://pyhamcrest.readthedocs.org/en/stable/integration/#module-hamcrest.library.integration.match_equality>). +https://pyhamcrest.readthedocs.org/en/release-1.8/integration/#module-hamcrest.library.integration.match_equality`).

--- a/Doc/library/urllib.request.rst +++ b/Doc/library/urllib.request.rst @@ -14,7 +14,7 @@ authentication, redirections, cookies an .. seealso::

--- a/Doc/library/winreg.rst +++ b/Doc/library/winreg.rst @@ -134,7 +134,7 @@ This module offers the following functio The :func:DeleteKeyEx function is implemented with the RegDeleteKeyEx Windows API function, which is specific to 64-bit versions of Windows. See the `RegDeleteKeyEx documentation

key is an already open key, or one of the predefined :ref:HKEY_* constants <hkey-constants>. @@ -268,7 +268,7 @@ This module offers the following functio A call to :func:LoadKey fails if the calling process does not have the :const:SE_RESTORE_PRIVILEGE privilege. Note that privileges are different from permissions -- see the `RegLoadKey documentation

For more information, see Registry Key Security and Access[](#l48.33) -<http://msdn.microsoft.com/en-us/library/ms724878%28v=VS.85%29.aspx>. +https://msdn.microsoft.com/en-us/library/ms724878%28v=VS.85%29.aspx__.[](#l48.35) [](#l48.36) .. data:: KEY_ALL_ACCESS[](#l48.37) [](#l48.38) @@ -602,7 +602,7 @@ 64-bit Specific[](#l48.39) ***************[](#l48.40) [](#l48.41) For more information, see Accessing an Alternate Registry View -http://msdn.microsoft.com/en-us/library/aa384129(v=VS.85).aspx__.[](#l48.43) +<https://msdn.microsoft.com/en-us/library/aa384129(v=VS.85).aspx>. .. data:: KEY_WOW64_64KEY @@ -621,7 +621,7 @@ Value Types +++++++++++ For more information, see Registry Value Types[](#l48.51) -<http://msdn.microsoft.com/en-us/library/ms724884%28v=VS.85%29.aspx>. +https://msdn.microsoft.com/en-us/library/ms724884%28v=VS.85%29.aspx`. .. data:: REG_BINARY

--- a/Doc/library/wsgiref.rst +++ b/Doc/library/wsgiref.rst @@ -24,8 +24,8 @@ for implementing WSGI servers, a demo HT and a validation tool that checks WSGI servers and applications for conformance to the WSGI specification (:pep:3333). -See http://www.wsgi.org for more information about WSGI, and links to tutorials -and other resources. +See https://wsgi.readthedocs.org/ for more information about WSGI, and links to +tutorials and other resources. .. XXX If you're just trying to write a web application...

--- a/Doc/library/xml.rst +++ b/Doc/library/xml.rst @@ -62,7 +62,7 @@ kind sax etr billion laughs Yes Yes Yes Yes Yes quadratic blowup Yes Yes Yes Yes Yes external entity expansion Yes No (1) No (2) Yes No (3) -DTD retrieval Yes No No Yes No +DTD_ retrieval Yes No No Yes No decompression bomb No No No No Yes ========================= ======== ========= ========= ======== ========= @@ -92,7 +92,7 @@ external entity expansion also point to external resources or local files. The XML parser accesses the resource and embeds the content into the XML document. -DTD retrieval +DTD_ retrieval Some XML libraries like Python's :mod:xml.dom.pulldom retrieve document type definitions from remote or local locations. The feature has similar implications as the external entity expansion issue. @@ -128,6 +128,6 @@ Python because they break backward compa .. _defusedxml: https://pypi.python.org/pypi/defusedxml/[](#l50.23) .. _defusedexpat: https://pypi.python.org/pypi/defusedexpat/[](#l50.24) -.. _Billion Laughs: http://en.wikipedia.org/wiki/Billion_laughs[](#l50.25) -.. _ZIP bomb: http://en.wikipedia.org/wiki/Zip_bomb[](#l50.26) -.. _DTD: http://en.wikipedia.org/wiki/Document_Type_Definition[](#l50.27) +.. _Billion Laughs: https://en.wikipedia.org/wiki/Billion_laughs[](#l50.28) +.. _ZIP bomb: https://en.wikipedia.org/wiki/Zip_bomb[](#l50.29) +.. _DTD: https://en.wikipedia.org/wiki/Document_type_definition[](#l50.30)

--- a/Doc/library/xmlrpc.client.rst +++ b/Doc/library/xmlrpc.client.rst @@ -142,7 +142,7 @@ between conformable Python objects and X XML-RPC Introspection <http://xmlrpc-c.sourceforge.net/introspection.html>_ Describes the XML-RPC protocol extension for introspection.

--- a/Doc/library/zipfile.rst +++ b/Doc/library/zipfile.rst @@ -13,8 +13,7 @@ The ZIP file format is a common archive and compression standard. This module provides tools to create, read, write, append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as -defined in PKZIP Application Note[](#l52.7) -<http://www.pkware.com/documents/casestudies/APPNOTE.TXT>. +defined in PKZIP Application Note. This module does not currently handle multi-disk ZIP files. It can handle ZIP files that use the ZIP64 extensions @@ -115,7 +114,7 @@ The module defines the following items: .. seealso::

@@ -511,8 +510,7 @@ Instances have the following attributes: .. attribute:: ZipInfo.extra

@@ -574,3 +572,5 @@ Instances have the following attributes: .. attribute:: ZipInfo.file_size Size of the uncompressed file. + +.. _PKZIP Application Note: https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT[](#l52.37)

--- a/Doc/library/zipimport.rst +++ b/Doc/library/zipimport.rst @@ -30,7 +30,7 @@ ZIP archives with an archive comment are .. seealso::

--- a/Doc/using/mac.rst +++ b/Doc/using/mac.rst @@ -153,7 +153,7 @@ Mac OS X. Packages and documentation are PyQt is another popular cross-platform GUI toolkit that runs natively on Mac OS X. More information can be found at -http://www.riverbankcomputing.co.uk/software/pyqt/intro.[](#l54.7) +https://riverbankcomputing.com/software/pyqt/intro.[](#l54.8) Distributing Python Applications on the Mac

--- a/Doc/using/unix.rst +++ b/Doc/using/unix.rst @@ -26,11 +26,11 @@ following links: .. seealso::

If you want to compile CPython yourself, first thing you should do is get the -source <https://www.python.org/download/source/>. You can download either the +source <https://www.python.org/downloads/source/>. You can download either the latest release's source or just grab a fresh clone[](#l55.24) <https://docs.python.org/devguide/setup.html#getting-the-source-code>_. (If you want to contribute patches, you will need a clone.)

--- a/Doc/using/windows.rst +++ b/Doc/using/windows.rst @@ -251,12 +251,12 @@ Check :pep:11 for details on all unsup release/python>_, Maintainer releases http://www.tishler.net/jason/software/python/_)[](#l56.5) [](#l56.6) -See Python for Windows https://www.python.org/download/windows/_[](#l56.7) +See Python for Windows https://www.python.org/downloads/windows/`_ for detailed information about platforms with pre-compiled installers. .. seealso::

@@ -279,10 +279,10 @@ Besides the standard CPython distributio additional functionality. The following is a list of popular versions and their key features: -ActivePython <http://www.activestate.com/activepython/> +ActivePython <https://www.activestate.com/activepython/> Installer with multi-platform compatibility, documentation, PyWin32 -Anaconda <http://www.continuum.io/downloads/> +Anaconda <https://www.continuum.io/downloads/> Popular scientific modules (such as numpy, scipy and pandas) and the conda package manager. @@ -352,16 +352,16 @@ System variables, you need non-restricte .. seealso::

--- a/Doc/whatsnew/2.0.rst +++ b/Doc/whatsnew/2.0.rst @@ -130,7 +130,7 @@ Guidelines": Read the rest of PEP 1 for the details of the PEP editorial process, style, and format. PEPs are kept in the Python CVS tree on SourceForge, though they're not part of the Python 2.0 distribution, and are also available in HTML form from -https://www.python.org/peps/. As of September 2000, there are 25 PEPS, ranging +https://www.python.org/dev/peps/. As of September 2000, there are 25 PEPS, ranging from PEP 201, "Lockstep Iteration", to PEP 225, "Elementwise/Objectwise Operators". @@ -337,7 +337,7 @@ comprehension below is a syntax error, w [ (x,y) for x in seq1 for y in seq2] The idea of list comprehensions originally comes from the functional programming -language Haskell (http://www.haskell.org). Greg Ewing argued most effectively +language Haskell (https://www.haskell.org). Greg Ewing argued most effectively for adding them to Python and wrote the initial list comprehension patch, which was then discussed for a seemingly endless time on the python-dev mailing list and kept up-to-date by Skip Montanaro.

--- a/Doc/whatsnew/2.1.rst +++ b/Doc/whatsnew/2.1.rst @@ -562,7 +562,7 @@ You can start creating packages containi using Python 2.1, since a new release of the Distutils will be made for users of earlier Python versions. Version 1.0.2 of the Distutils includes the changes described in PEP 241, as well as various bugfixes and enhancements. It will be -available from the Distutils SIG at https://www.python.org/sigs/distutils-sig/.[](#l58.7) +available from the Distutils SIG at https://www.python.org/community/sigs/current/distutils-sig/.[](#l58.8) .. seealso::

--- a/Doc/whatsnew/2.3.rst +++ b/Doc/whatsnew/2.3.rst @@ -1080,9 +1080,9 @@ Here are all of the changes that Python hierarchy. Classic classes are unaffected by this change. Python 2.2 originally used a topological sort of a class's ancestors, but 2.3 now uses the C3 algorithm as described in the paper `"A Monotonic Superclass Linearization

--- a/Doc/whatsnew/2.4.rst +++ b/Doc/whatsnew/2.4.rst @@ -337,7 +337,7 @@ returned. wrote patches implementing function decorators, but the one that was actually checked in was patch #979728, written by Mark Russell.

.. ====================================================================== @@ -687,7 +687,7 @@ includes a quick-start tutorial and a re The article uses Fortran code to illustrate many of the problems that floating- point inaccuracy can cause.

The code for these functions came from the GLib library -(http://library.gnome.org/devel/glib/stable/), whose developers kindly +(https://developer.gnome.org/glib/stable/), whose developers kindly relicensed the relevant functions and donated them to the Python Software Foundation. The :mod:locale module can now change the numeric locale, letting extensions such as GTK+ produce the correct results.

--- a/Doc/whatsnew/2.5.rst +++ b/Doc/whatsnew/2.5.rst @@ -330,7 +330,7 @@ statement, only the from ... import :pep:328 - Imports: Multi-Line and Absolute/Relative PEP written by Aahz; implemented by Thomas Wouters.

.. ====================================================================== @@ -547,7 +547,7 @@ exhausted. Earlier versions of these features were proposed in :pep:288 by Raymond Hettinger and :pep:325 by Samuele Pedroni.

--- a/Doc/whatsnew/2.6.rst +++ b/Doc/whatsnew/2.6.rst @@ -153,8 +153,8 @@ The infrastructure committee of the Pyth therefore posted a call for issue trackers, asking volunteers to set up different products and import some of the bugs and patches from SourceForge. Four different trackers were examined: Jira[](#l62.6) -<http://www.atlassian.com/software/jira/>, -Launchpad <http://www.launchpad.net>, +https://www.atlassian.com/software/jira/__,[](#l62.9) +Launchpad https://www.launchpad.net__,[](#l62.10) Roundup http://roundup.sourceforge.net/__, and[](#l62.11) Trac http://trac.edgewall.org/`__. The committee eventually settled on Jira @@ -217,7 +217,7 @@ the time required to finish the job. During the 2.6 development cycle, Georg Brandl put a lot of effort into building a new toolchain for processing the documentation. The resulting package is called Sphinx, and is available from -http://sphinx.pocoo.org/.[](#l62.18) +http://sphinx-doc.org/.[](#l62.19) Sphinx concentrates on HTML output, producing attractively styled and modern HTML; printed output is still supported through conversion to @@ -1796,7 +1796,7 @@ changes, or look through the Subversion

--- a/Doc/whatsnew/2.7.rst +++ b/Doc/whatsnew/2.7.rst @@ -1029,7 +1029,7 @@ changes, or look through the Subversion

--- a/Doc/whatsnew/3.0.rst +++ b/Doc/whatsnew/3.0.rst @@ -565,7 +565,7 @@ review: core standard library has proved over time to be a particular burden for the core developers due to testing instability and Berkeley DB's release schedule. However, the package is alive and well,

--- a/Doc/whatsnew/3.2.rst +++ b/Doc/whatsnew/3.2.rst @@ -845,9 +845,9 @@ collections

--- a/Doc/whatsnew/3.3.rst +++ b/Doc/whatsnew/3.3.rst @@ -1884,13 +1884,13 @@ socket Heiko Wundram)

--- a/Doc/whatsnew/3.4.rst +++ b/Doc/whatsnew/3.4.rst @@ -144,7 +144,7 @@ Security improvements: all of the parent's inheritable handles, only the necessary ones.

--- a/Doc/whatsnew/3.5.rst +++ b/Doc/whatsnew/3.5.rst @@ -2169,7 +2169,7 @@ for details.) The :c:member:PyTypeObject.tp_finalize slot is now part of the stable ABI. Windows builds now require Microsoft Visual C++ 14.0, which -is available as part of Visual Studio 2015 <http://www.visualstudio.com>. +is available as part of Visual Studio 2015 <https://www.visualstudio.com/>. Extension modules now include a platform information tag in their filename on some platforms (the tag is optional, and CPython will import extensions without

--- a/Misc/NEWS +++ b/Misc/NEWS @@ -7411,7 +7411,7 @@ Library