Commit Graph

7612 Commits

Author SHA1 Message Date
Martin Panter 8f26565ba9 Fix spelling (inital), grammar (may translates) in documentation, comments 2016-04-19 04:03:41 +00:00
Paul Moore b5d164cc3f Mention types.SimpleNamespace in collections.namedtuple doc
Issue #26805.
2016-04-19 19:17:16 +01:00
Berker Peksag 1d0489269e Issue #26615: Add missing __qualname__ entry to functools.update_wrapper() docs
Patch by Xiang Zhang.
2016-04-18 21:21:10 +03:00
Berker Peksag 472233ec83 Issue #26615: Add missing __qualname__ entry to functools.update_wrapper() docs
Patch by Xiang Zhang.
2016-04-18 21:20:50 +03:00
Georg Brandl d2be07e1fd #25987: add versionadded to Reversible. 2016-04-18 07:25:54 +02:00
Serhiy Storchaka b6a9c9761c Issue #26778: Fixed "a/an/and" typos in code comment, documentation and error
messages.
2016-04-17 09:39:28 +03:00
Serhiy Storchaka 6a7b3a77b4 Issue #26778: Fixed "a/an/and" typos in code comment and documentation. 2016-04-17 08:32:47 +03:00
Steven D'Aprano 151f5d5971 Fix a few minor typos to secrets documentation. 2016-04-17 13:05:10 +10:00
Steven D'Aprano b2871faa87 Documentation for secrets.py 2016-04-17 01:42:33 +10:00
Martin Panter 8b04a945ef Merge typo fixes from 3.5 2016-04-16 09:29:17 +00:00
Martin Panter 119e502277 Fix typos in code comments and documentation 2016-04-16 09:28:57 +00:00
Martin Panter d3aeb9b797 Issue #26638: Merge link fixes from 3.5 2016-04-16 07:36:08 +00:00
Martin Panter 00ccacc8db Issue #26638: Fix links to some CLI options and section headings
* Disable inappropriate links to Python interpreter options
* Correct link to CLI section in zipapp
* Make CLI section label in timeit less ambiguous
2016-04-16 04:59:38 +00:00
Martin Panter f7ee9c2108 Issue #25314: Merge argparse doc from 3.5 2016-04-16 00:20:21 +00:00
Gregory P. Smith b0c6380640 merge heads 2016-04-15 16:47:32 -07:00
Martin Panter b030991a5f Issue #26535: Correct docs regarding the struct buffer size 2016-04-15 23:03:54 +00:00
Martin Panter cda80940ed Issue #15984: Merge PyUnicode doc from 3.5 2016-04-15 02:27:11 +00:00
Martin Panter 6245cb3c01 Correct “an” → “a” with “Unicode”, “user”, “UTF”, etc
This affects documentation, code comments, and a debugging messages.
2016-04-15 02:14:19 +00:00
Martin Panter 81939db712 Issue #25496: Merge tarfile doc from 3.5 2016-04-13 03:31:33 +00:00
Martin Panter 7f7c605f29 Issue #25496: Document compresslevel defaults to 9, by Hamza T Khan 2016-04-13 03:24:06 +00:00
Martin Panter 0cab9c1eba Issue #26404: Add context manager to socketserver, by Aviv Palivoda 2016-04-13 00:36:52 +00:00
Georg Brandl 2cfa4c7b27 merge with 3.5 2016-04-12 07:52:22 +02:00
Georg Brandl 7ff033bd62 Clarify greedy-qualifier example, avoid HTML. 2016-04-12 07:51:41 +02:00
Victor Stinner 21de67f900 Merge 3.5 2016-04-11 16:23:37 +02:00
Victor Stinner a9901e86ba typing doc: add versionadded 3.5 2016-04-11 16:23:22 +02:00
Berker Peksag 1dc2dda4e3 Add a versionchanged directive to document addition of the new 'namereplace' error handler.
Reported by Robert on docs@p.o.
2016-04-11 13:50:04 +03:00
Berker Peksag 2c57da0e48 Add a versionchanged directive to document addition of the new 'namereplace' error handler.
Reported by Robert on docs@p.o.
2016-04-11 13:49:46 +03:00
Berker Peksag 8e72f503b1 Fix typos in mock and exceptions docs
The default value of __len__ is 0, not 1:

    >>> from unittest.mock import MagicMock
    >>> mock = MagicMock()
    >>> len(mock)
    0

Reported by Alex on docs@p.o.

Remove the remaining VMSError reference. VMS support is gone.
2016-04-11 12:23:25 +03:00
Berker Peksag 8fafc74d45 Fix typos in mock and exceptions docs
The default value of __len__ is 0, not 1:

    >>> from unittest.mock import MagicMock
    >>> mock = MagicMock()
    >>> len(mock)
    0

Reported by Alex on docs@p.o.

Remove the remaining VMSError reference. VMS support is gone.
2016-04-11 12:23:04 +03:00
Martin Panter a29f720493 Issue #14456: Merge signal doc fix from 3.5 2016-04-11 02:45:22 +00:00
Martin Panter 199e3f8b96 Issue #14456: Remove contradiction about blocking signals from bad merge 2016-04-11 02:44:34 +00:00
Martin Panter 50ab1a3694 Issue #26685: Raise OSError if closing a socket fails 2016-04-11 00:38:12 +00:00
Victor Stinner 1edcd50b5d Merge 3.5: fcntl doc 2016-04-09 11:33:53 +02:00
Victor Stinner d0d5154251 Update fcntl doc: replace IOError with OSError
Issue #26716. IOError is a deprecated alias to OSError since Python 3.3.
2016-04-09 11:32:58 +02:00
Martin Panter b4912b8ed3 Issue #25314: Remove confused statement about const argument 2016-04-09 03:49:48 +00:00
Brett Cannon 09455589c7 Issue #26587: Remove an incorrect statement from the docs 2016-04-08 15:06:54 -07:00
Brett Cannon 9e080e0e74 Issue #25609: Introduce contextlib.AbstractContextManager and
typing.ContextManager.
2016-04-08 12:15:27 -07:00
Martin Panter b15c304984 Issue #6953: Merge readline doc from 3.5 2016-04-05 10:17:38 +00:00
Martin Panter 0f7673943a Issue #6953: Rearrange and expand Readline module documentation
* Group functions into six new subsections
* Document the underlying Readline function or variable accessed
* get_history_length() returns the history file limit
* clear_history() is conditionally compiled in
* Clarify zero and one bases for history item indexes
* parse_and_bind() uses its argument directly as an init line
* Change "command line" to "line buffer" for consistency
* read_init_file() also executes the file
* read_history_file() replaces the previous history
* write_history_file() overwrites any existing file
* Differentiate history file lines from history list items, which could be
  multi-line
* Add more information about completion, also addressing Issue #10796
* libedit (Editline) may be used on any platform; detection is OS X specific
2016-04-05 07:37:22 +00:00
Martin Panter c86c91aab0 Merge typo fixes from 3.5 2016-04-05 06:20:32 +00:00
Martin Panter cc71a795df Fix typos in documentation and comments 2016-04-05 06:19:42 +00:00
Guido van Rossum 16ca06b8cb Add collections.Reversible. Patch by Ivan Levkivskyi. Fixes issue #25987. 2016-04-04 10:59:29 -07:00
Berker Peksag 1862bb2769 Issue #26679: Fix description of KEY_PPAGE and KEY_NPAGE constants
Patch by Robert Bachmann and SilentGhost.
2016-04-02 04:48:46 +03:00
Berker Peksag af8363926a Issue #26679: Fix description of KEY_PPAGE and KEY_NPAGE constants
Patch by Robert Bachmann and SilentGhost.
2016-04-02 04:48:27 +03:00
Berker Peksag 40d38e19a1 Issue #26688: Fix module name in mock docs
Patch by Ashley Anderson.
2016-04-02 04:32:26 +03:00
Berker Peksag b31daff1f7 Issue #26688: Fix module name in mock docs
Patch by Ashley Anderson.
2016-04-02 04:32:06 +03:00
Martin Panter 6b6abd4cf1 Issue #26678: Merge datetime doc fixes from 3.5 2016-04-01 23:20:52 +00:00
Martin Panter 16c7cfda7c Issue #26678: Fix indexing of datetime.tzinfo and timezone classes
Also fix links to the “tzinfo” class and attributes.
2016-04-01 21:48:24 +00:00
Serhiy Storchaka 7b1e5a7722 Remove redundant leading zeroes in PEP references. 2016-03-31 15:31:20 +03:00
Serhiy Storchaka e4ba872543 Remove redundant leading zeroes in PEP references. 2016-03-31 15:30:54 +03:00
Berker Peksag fe4c01268c Fix typo in xml.dom.pulldom.rst
Reported by Matthew Cole on docs@p.o.
2016-03-30 16:29:01 +03:00
Berker Peksag 13b3acd13e Fix typo in xml.dom.pulldom.rst
Reported by Matthew Cole on docs@p.o.
2016-03-30 16:28:43 +03:00
Andrew Svetlov 50e648a06d Merge 3.5 2016-03-29 09:39:22 +03:00
Andrew Svetlov 6f57424ae0 Document None as timeout for asyncio.timeout() 2016-03-29 09:39:02 +03:00
Martin Panter eba25880f8 Issue #25314: Merge argparse doc from 3.5 2016-03-28 06:13:52 +00:00
Martin Panter ef4bb1e994 Issue #23804: Merge SSL zero read fix from 3.5 2016-03-28 01:09:13 +00:00
Martin Panter f6b1d66a3c Issue #23804: Fix SSL recv/read(0) to not return 1024 bytes 2016-03-28 00:22:09 +00:00
Berker Peksag f841909f09 Issue #23758: Improve num_params docs of create_{function,aggregate} functions
If you pass -1, the callable can take any number of arguments.

Added tests to verify the behavior.

Initial patch by Cédric Krier.
2016-03-27 22:39:41 +03:00
Berker Peksag fa0f62d6ab Issue #23758: Improve num_params docs of create_{function,aggregate} functions
If you pass -1, the callable can take any number of arguments.

Added tests to verify the behavior.

Initial patch by Cédric Krier.
2016-03-27 22:39:14 +03:00
Berker Peksag b61b0f13b5 Document sqlite3.Cursor.close()
The behaviour of the close method is tested by ClosedCurTests
in Lib/sqlite3/test/dbapi.py.

This is basically a backport of https://github.com/ghaering/pysqlite/issues/73.
2016-03-27 21:51:22 +03:00
Berker Peksag f70fe6f6cf Document sqlite3.Cursor.close()
The behaviour of the close method is tested by ClosedCurTests
in Lib/sqlite3/test/dbapi.py.

This is basically a backport of https://github.com/ghaering/pysqlite/issues/73.
2016-03-27 21:51:02 +03:00
Berker Peksag 598b198ca6 sqlite3 documentation: Connection.iterdump() is a method 2016-03-27 18:46:42 +03:00
Berker Peksag 557a06309c sqlite3 documentation: Connection.iterdump() is a method 2016-03-27 18:46:18 +03:00
Victor Stinner a6d865c128 Issue #25654:
* multiprocessing: open file with closefd=False to avoid ResourceWarning
* _test_multiprocessing: open file with O_EXCL to detect bugs in tests (if a
  previous test forgot to remove TESTFN)
* test_sys_exit(): remove TESTFN after each loop iteration

Initial patch written by Serhiy Storchaka.
2016-03-25 09:29:50 +01:00
Terry Jan Reedy 4c181cf448 Merge with 3.5 2016-03-23 13:37:15 -04:00
Terry Jan Reedy 01a9a958b6 Issue #26525: Change chr example to match change in ord example. 2016-03-23 13:36:52 -04:00
Victor Stinner 404cdc5a92 faulthandler: add Windows exception handler
Issue #23848: On Windows, faulthandler.enable() now also installs an exception
handler to dump the traceback of all Python threads on any Windows exception,
not only on UNIX signals (SIGSEGV, SIGFPE, SIGABRT).
2016-03-23 10:39:17 +01:00
Victor Stinner e19558af1b Add a source parameter to warnings.warn()
Issue #26604:

* Add a new optional source parameter to _warnings.warn() and warnings.warn()
* Modify asyncore, asyncio and _pyio modules to set the source parameter when
  logging a ResourceWarning warning
2016-03-23 00:28:08 +01:00
Victor Stinner e492ae50e2 tracemalloc now supports domains
Issue #26588:

* The _tracemalloc now supports tracing memory allocations of multiple address
  spaces (domains).
* Add domain parameter to tracemalloc_add_trace() and
  tracemalloc_remove_trace().
* tracemalloc_add_trace() now starts by removing the previous trace, if any.
* _tracemalloc._get_traces() now returns a list of (domain, size,
  traceback_frames): the domain is new.
* Add tracemalloc.DomainFilter
* tracemalloc.Filter: add an optional domain parameter to the constructor and a
  domain attribute
* Sublte change: use Py_uintptr_t rather than void* in the traces key.
* Add tracemalloc_config.use_domain, currently hardcoded to 1
2016-03-22 12:58:23 +01:00
Terry Jan Reedy 063d48d9c0 Issue #26525: Change ord example from nu to more easily recognized Euro sign. 2016-03-20 21:18:40 -04:00
Terry Jan Reedy 4902c46bff Issue #15660: Further clarify 0 prefix for width specifier in formats. 2016-03-20 21:05:57 -04:00
Terry Jan Reedy 5decb84454 Merge with 3.5 2016-03-20 21:18:54 -04:00
Terry Jan Reedy 370764a824 Merge with 3.5 2016-03-20 21:06:15 -04:00
Berker Peksag 3c3d7f4b99 Issue #18787: spwd.getspnam() now raises a PermissionError if the user
doesn't have privileges.
2016-03-19 11:44:17 +02:00
Victor Stinner 914cde89d4 On ResourceWarning, log traceback where the object was allocated
Issue #26567:

* Add a new function PyErr_ResourceWarning() function to pass the destroyed
  object
* Add a source attribute to warnings.WarningMessage
* Add warnings._showwarnmsg() which uses tracemalloc to get the traceback where
  source object was allocated.
2016-03-19 01:03:51 +01:00
Brett Cannon 5936313651 Issue #26252: Add an example on how to register a finder 2016-03-18 11:54:22 -07:00
Ezio Melotti 6840632ef2 #26250: merge with 3.5. 2016-03-18 20:11:30 +02:00
Ezio Melotti 62564dbb4b #26250: document the sqlite3.Cursor.connection attribute. Initial patches by Aviv Palivoda and Varpu Rantala. 2016-03-18 20:10:36 +02:00
Serhiy Storchaka ee6471ec90 Fixed a typo. 2016-03-18 14:37:53 +02:00
Serhiy Storchaka 774006232a Fixed a typo. 2016-03-18 14:36:47 +02:00
Berker Peksag b3fe1c488f Issue #26580: Remove outdated reference to ftpmirror
Patch by SilentGhost.
2016-03-18 14:26:29 +02:00
Berker Peksag 42f8548c89 Issue #26580: Remove outdated reference to ftpmirror
Patch by SilentGhost.
2016-03-18 14:26:08 +02:00
Martin Panter ce911c3fed Issue #26499: Fixes to HTTPResponse.readline() and read1(), by Silent Ghost 2016-03-17 06:42:48 +00:00
Martin Panter 32f2eb4941 Issue #21042: Revert Linux find_library() to return just filename
This reverts most of revision 3092cf163eb4. The change worked on x86
architectures, but did not work on ARM, probably due to extra ABI flags in
the ldconfig output.
2016-03-17 07:50:22 +00:00
Martin Panter ec195fba5b Issue #26499: Merge HTTPResponse fix from 3.5 2016-03-17 07:05:34 +00:00
Victor Stinner 8a20851010 Issue #25654:
* multiprocessing: open file with closefd=False to avoid ResourceWarning
* _test_multiprocessing: open file with O_EXCL to detect bugs in tests (if a
  previous test forgot to remove TESTFN)
* test_sys_exit(): remove TESTFN after each loop iteration

Initial patch written by Serhiy Storchaka.
2016-03-25 09:29:50 +01:00
Raymond Hettinger 5f6209a3c6 merge 2016-03-13 00:12:49 -08:00
Raymond Hettinger a503f7092f Minor recipe edit: convert "while 1" to "while True". 2016-03-13 00:12:31 -08:00
Ezio Melotti 0ce835fc7e #25687: merge with 3.5. 2016-03-13 09:40:55 +02:00
Ezio Melotti 8dea74f12a #25687: clarify that errors in tearDown increase the total number of reported errors. Initial patch by HyeSoo Park. 2016-03-13 09:40:09 +02:00
Raymond Hettinger 7dc830e988 merge 2016-03-12 22:58:44 -08:00
Raymond Hettinger 4d02896609 Issue #26548: Minor fix to awkward wording in docs 2016-03-12 22:58:24 -08:00
Steve Dower 6d6b986d90 Issue #23606: Adds note to ctypes documentation regarding cdll.msvcrt. 2016-03-12 08:26:29 -08:00
Steve Dower d669b6bd0a Issue #23606: Adds note to ctypes documentation regarding cdll.msvcrt. 2016-03-12 08:25:22 -08:00
Berker Peksag eb2e02bed4 Issue #26542: Fix markup of code example in difflib documentation
Patch by Dmitry Shachnev.
2016-03-11 23:19:48 +02:00
Victor Stinner 2c2a4e63d7 Add Mock.assert_called()
Issue #26323: Add assert_called() and assert_called_once() methods to
unittest.mock.Mock.
2016-03-11 22:17:48 +01:00
Berker Peksag 82442b7022 Issue #26542: Fix markup of code example in difflib documentation
Patch by Dmitry Shachnev.
2016-03-11 23:20:09 +02:00
Martin Panter b9f3114d42 Issue #21042: Return full path in ctypes.util.find_library() on Linux
Patch by Tamás Bence Gedai.
2016-03-10 01:06:23 +00:00
Serhiy Storchaka 674e2d0ea0 Issue #15068: Got rid of excessive buffering in fileinput.
The bufsize parameter is now deprecated and ignored.
2016-03-08 18:35:19 +02:00
Serhiy Storchaka cc2dbc5844 Issue #15068: Got rid of excessive buffering in the fileinput module.
The bufsize parameter is no longer used.
2016-03-08 18:28:36 +02:00