Commit Graph

22462 Commits

Author SHA1 Message Date
Steve Dower 9eb3d54639
bpo-37834: Normalise handling of reparse points on Windows (GH-15370)
bpo-37834: Normalise handling of reparse points on Windows
* ntpath.realpath() and nt.stat() will traverse all supported reparse points (previously was mixed)
* nt.lstat() will let the OS traverse reparse points that are not name surrogates (previously would not traverse any reparse point)
* nt.[l]stat() will only set S_IFLNK for symlinks (previous behaviour)
* nt.readlink() will read destinations for symlinks and junction points only

bpo-1311: os.path.exists('nul') now returns True on Windows
* nt.stat('nul').st_mode is now S_IFCHR (previously was an error)
2019-08-21 15:52:42 -07:00
Miss Islington (bot) c30c869e8d
bpo-9949: Enable symlink traversal for ntpath.realpath (GH-15287)
(cherry picked from commit 75e064962e)

Co-authored-by: Steve Dower <steve.dower@python.org>
2019-08-21 14:09:33 -07:00
Miss Islington (bot) 349d897e0f Update asyncio.ensure_future() documentation (GH-15347) (GH-15364)
Added back mention that ensure_future actually scheduled obj. This documentation just mentions what ensure_future returns, so I did not realize that ensure_future also schedules obj.
(cherry picked from commit 092911d5c0)

Co-authored-by: Roger Iyengar <ri@rogeriyengar.com>
2019-08-21 13:20:49 -04:00
Miss Islington (bot) c777dec6f4
bpo-37823: Fix open() link in telnetlib doc (GH-15281)
Fixed wrong link to Telnet.open() method in telnetlib documentation.
(cherry picked from commit e0b6117e27)

Co-authored-by: Michael Anckaert <michael.anckaert@sinax.be>
2019-08-21 04:38:04 -07:00
Miss Islington (bot) 9aa0ab1a97
Remove 'unstable' warning for Windows Store package in docs (GH-15334)
(cherry picked from commit cf9360e524)

Co-authored-by: Steve Dower <steve.dower@python.org>
2019-08-19 10:14:31 -07:00
Greg Price 8c1c426a63 bpo-36502: Correct documentation of str.isspace() (GH-15019) (GH-15296)
The documented definition was much broader than the real one:
there are tons of characters with general category "Other",
and we don't (and shouldn't) treat most of them as whitespace.

Rewrite the definition to agree with the comment on
_PyUnicode_IsWhitespace, and with the logic in makeunicodedata.py,
which is what generates that function and so ultimately governs.

Add suitable breadcrumbs so that a reader who wants to pin down
exactly what this definition means (what's a "bidirectional class"
of "B"?) can do so.  The `unicodedata` module documentation is an
appropriate central place for our references to Unicode's own copious
documentation, so point there.

Also add to the isspace() test a thorough check that the
implementation agrees with the intended definition.
2019-08-19 10:53:22 +01:00
Miss Islington (bot) 7309cca147
[3.8] fix link to time function from time_ns doc (GH-15285) (GH-15321)
Because mod, func, class, etc all share one namespace, :func:time creates a link to the time module doc page rather than the time.time function.
(cherry picked from commit 1b1d0514ad)


Co-authored-by: Éric Araujo <merwok@netwok.org>

Automerge-Triggered-By: @merwok
2019-08-17 13:51:57 -07:00
Miss Islington (bot) f991912146
bpo-37256: Wording in Request class docs (GH-14792)
* bpo-37256: Wording in Request class docs

* 📜🤖 Added by blurb_it.

* Update Misc/NEWS.d/next/Documentation/2019-07-16-14-48-12.bpo-37256.qJTrBb.rst

Co-Authored-By: Kyle Stanley <aeros167@gmail.com>
(cherry picked from commit 38c7199beb)

Co-authored-by: Ngalim Siregar <ngalim.siregar@gmail.com>
2019-08-16 01:27:35 -07:00
Miss Islington (bot) dbe4c286ce
bpo-37775: Update compileall doc for invalidation_mode parameter (GH-15148)
(cherry picked from commit 68e495df90)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
2019-08-14 15:22:02 -07:00
Miss Islington (bot) 6ad902a088
bpo-37814: Document the empty tuple type annotation syntax (GH-15208)
https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814
(cherry picked from commit 8a784af750)

Co-authored-by: Josh Holland <anowlcalledjosh@gmail.com>
2019-08-13 12:12:55 -07:00
Raymond Hettinger 9bedb8c9e6
bpo-37759: Second round of edits to Whatsnew 3.8 (GH-15204) (GH-15240)
(cherry picked from commit 66a34d35e4)
2019-08-12 18:02:58 -07:00
Miss Islington (bot) 2f087e279b Fix docs for assert_called and assert_called_once (GH-15219)
(cherry picked from commit f9590edfea)

Co-authored-by: Ismail S <ismail-s@users.noreply.github.com>
2019-08-12 09:19:47 +01:00
Miss Islington (bot) 5ba1cb0393 bpo-37819: Add Fraction.as_integer_ratio() (GH-15212) (GH-15215)
(cherry picked from commit f03b4c8a48)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-08-11 15:02:23 -07:00
Serhiy Storchaka 4c5b6bac24 [3.8] bpo-32912: Revert SyntaxWarning on invalid escape sequences (GH-15142)
* bpo-32912: Revert warnings for invalid escape sequences.

DeprecationWarning will continue to be emitted for invalid escape sequences in string and bytes literals in 3.8 just as it did in 3.7.

SyntaxWarning may be emitted in the future. But per mailing list discussion, we don't yet know when because we haven't settled on how to do so in a non-disruptive manner.
2019-08-09 15:34:22 -07:00
Miss Islington (bot) 5925b7d555 bpo-35892: Add usage note to mode() (GH-15122) (GH-15176)
(cherry picked from commit e43e7ed364)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-08-08 01:36:55 -07:00
Miss Islington (bot) 1a3a40c1cb bpo-37004: Documented asymmetry of string arguments in difflib.SequenceMatcher for ratio method (GH-13482) (#15157)
https://bugs.python.org/issue37004
(cherry picked from commit e9cbcd0018)

Co-authored-by: sweeneyde <36520290+sweeneyde@users.noreply.github.com>
2019-08-07 11:39:14 -04:00
Miss Islington (bot) 9341dcb4b9 bpo-37646: Document that eval() cannot access nested scopes (GH-15117) (GH-15155)
(cherry picked from commit 610a4823cc)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-08-06 18:07:59 -07:00
Miss Islington (bot) ef0b81927a
Improve signal documentation (GH-14274)
* add a missing ``.. availability::`` reST explicit markup;
* more consistent "see man page" sentences.
(cherry picked from commit cfebfef2de)

Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
2019-08-06 14:53:27 -07:00
Miss Islington (bot) 26f91db5ba bpo-37759: First round of major edits to Whatsnew 3.8 (GH-15127) (GH-15139)
(cherry picked from commit 4f9ffc9d1a)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-08-05 15:22:13 -07:00
Miss Islington (bot) 9c95fc752c
bpo-37748: Re-order the Run menu. (GH-15115)
Put the most common choice, Run Module, at the top.
(cherry picked from commit 14070299cd)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-08-04 14:04:49 -07:00
Miss Islington (bot) fc6e3bc1cd Update itertools docs (GH-15114) (GH-15118)
* Remove suggestion that is less relevant now that global lookups are much faster
* Add link for installing the recipes
(cherry picked from commit adf02b36b3)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-08-04 13:52:59 -07:00
Miss Islington (bot) dd5f8abb54
bpo-37730: Fix usage of NotImplemented instead of NotImplementedError in docs. (GH-15062)
(cherry picked from commit ed5e8e06cb)

Co-authored-by: David H <dheiberg@mozilla.com>
2019-08-04 06:43:30 -07:00
Miss Islington (bot) dde944f9df
bpo-37685: Fixed comparisons of datetime.timedelta and datetime.timezone. (GH-14996)
There was a discrepancy between the Python and C implementations.

Add singletons ALWAYS_EQ, LARGEST and SMALLEST in test.support
to test mixed type comparison.
(cherry picked from commit 17e52649c0)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2019-08-04 03:01:55 -07:00
Miss Islington (bot) 375f35be06 bpo-36487: Make C-API docs clear about what the main interpreter is. (gh-15080)
(cherry picked from commit 854d0a4b98) (gh-12666)

Co-authored-by: Joannah Nanjekye <33177550+nanjekyejoannah@users.noreply.github.com>
2019-08-02 11:49:38 -06:00
Miss Islington (bot) dcc53ebbff bpo-37726: Prefer argparse over getopt in stdlib tutorial (GH-15052) (#15070)
(cherry picked from commit 2491134029)

Co-authored-by: mental <m3nta1@yahoo.com>
2019-08-01 07:34:57 -07:00
Miss Islington (bot) 29a3a33d99
bpo-34101: Add doc of PyBuffer_GetPointer (GH-14994)
(cherry picked from commit 1b29af83bc)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
2019-07-31 08:04:31 -07:00
Miss Islington (bot) d8b914a30b
bpo-37085: Expose SocketCAN bcm_msg_head flags (GH-13646)
Expose the CAN_BCM SocketCAN constants used in the bcm_msg_head struct
flags (provided by <linux/can/bcm.h>) under the socket library.

This adds the following constants with a CAN_BCM prefix:

  * SETTIMER
  * STARTTIMER
  * TX_COUNTEVT
  * TX_ANNOUNCE
  * TX_CP_CAN_ID
  * RX_FILTER_ID
  * RX_CHECK_DLC
  * RX_NO_AUTOTIMER
  * RX_ANNOUNCE_RESUME
  * TX_RESET_MULTI_IDX
  * RX_RTR_FRAME
  * CAN_FD_FRAME

The CAN_FD_FRAME flag was introduced in the 4.8 kernel, while the other
ones were present since SocketCAN drivers were mainlined in 2.6.25. As
such, it is probably unnecessary to guard against these constants being
missing.
(cherry picked from commit 31c4fd2a10)

Co-authored-by: karl ding <karlding@users.noreply.github.com>
2019-07-31 02:10:38 -07:00
Miss Islington (bot) 9b9cac4e5d Refined Qt GUI example in the logging cookbook. (GH-15045) (GH-15046)
(cherry picked from commit 472eced677)
2019-07-31 07:58:46 +01:00
Miss Islington (bot) 9e044ddefd
bpo-33821: Update IDLE section of What's New 3.7 (GH-15036)
* bpo-33821: Update IDLE section of What's New 3.7

* Fix roles.
(cherry picked from commit 5982b7201b)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-30 22:23:05 -07:00
Miss Islington (bot) c7236b498f
bpo-33822: Add IDLE section of What's New 3.8 (GH-15035)
* bpo-33822: Add IDLE section of What's New 3.8

* Fix role.
(cherry picked from commit a72ca90eb9)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-30 22:16:45 -07:00
Miss Islington (bot) 7026737d77
bpo-36084: Add threading Native ID information to What's New documentation (GH-14845)
(cherry picked from commit 84846b0187)

Co-authored-by: Jake Tesler <jake.tesler@gmail.com>
2019-07-30 14:49:23 -07:00
Miss Islington (bot) 69372eea08
Remove trailing .0 from version changed note (GH-14987)
(cherry picked from commit 17a058ed6f)

Co-authored-by: Nick Coghlan <ncoghlan@gmail.com>
2019-07-28 04:48:26 -07:00
Miss Islington (bot) 76821bab9c bpo-37691: Let math.dist() accept sequences and iterables for coordinates (GH-14975) (GH-14984)
(cherry picked from commit 6b5f1b496f)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-07-27 14:26:58 -07:00
Miss Islington (bot) d38fa58695 Add Qt GUI example to the logging cookbook. (GH-14978) (GH-14979)
(cherry picked from commit 1ed915e8ae)
2019-07-27 14:04:13 +01:00
Miss Islington (bot) 06e8fc95d1
bpo-32910: Remove implementation detail in venv documentation. (GH-14968)
(cherry picked from commit 91e4957509)

Co-authored-by: Derek Keeler <d3r3kk@users.noreply.github.com>
2019-07-26 15:04:28 -07:00
Steve Dower 886e66d111
bpo-35524: Update Windows installer image in docs (GH-14966) 2019-07-26 13:39:51 -07:00
Miss Islington (bot) c594c274e9
Swap 'if' branches so content matches to condition in importlib example (GH-14947)
Prior to this change the guard on an 'elif' used an assignment expression whose value was used in a later 'else' block, causing some confusion for people.

(Discussion on Twitter: https://twitter.com/brettsky/status/1153861041068994566.)

Automerge-Triggered-By: @brettcannon
(cherry picked from commit 544fa15ea1)

Co-authored-by: Tzu-ping Chung <uranusjr@gmail.com>
2019-07-25 10:27:59 -07:00
Miss Islington (bot) 6367391646 [3.8] bpo-34160: explain how to deal with attribute order in ElementTree (GH-14867) (GH-14935)
* Fix the formatting in the documentation of the tostring() functions.

* bpo-34160: Document that the tostring() and tostringlist() functions also preserve the attribute order now.

* bpo-34160: Add an explanation of how users should deal with the attribute order.
(cherry picked from commit a3697db010)

Co-authored-by: Stefan Behnel <stefan_ml@behnel.de>
2019-07-24 20:32:56 +02:00
Miss Islington (bot) eb62274ed6
[3.8] Touch up venv docs (GH-14922) (GH-14923)
(cherry picked from commit 2f224a077a)


Co-authored-by: Brett Cannon <54418+brettcannon@users.noreply.github.com>

Automerge-Triggered-By: @brettcannon
2019-07-24 10:14:53 -07:00
Miss Islington (bot) 1da6a313dd
bpo-17535: IDLE editor line numbers (GH-14030)
(cherry picked from commit 7123ea009b)

Co-authored-by: Tal Einat <taleinat@gmail.com>
2019-07-23 06:04:13 -07:00
Miss Islington (bot) 5b398520a8 Update logging cookbook to show multiple worker processes using the concurrent.futures module. (GH-14905) (GH-14906)
(cherry picked from commit d309352c6f)
2019-07-22 13:25:46 +01:00
Kyle Stanley 24b5b360fa [3.8] Fix typos in docs, comments and test assert messages (GH-14872). (#14900)
(cherry picked from commit 96e12d5f4f)

Co-authored-by: Min ho Kim <minho42@gmail.com>
2019-07-21 22:48:45 -04:00
Miss Islington (bot) 0104841d12 Add examples to elucidate the formulas (GH-14898) (GH-14899)
(cherry picked from commit b530a4460b)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-07-21 16:39:08 -07:00
Miss Islington (bot) 8f501647ca
Bpo-37644: update suspicious.csv for distutils/examples (GH-14885)
(cherry picked from commit 22f0483d44)

Co-authored-by: Ned Deily <nad@python.org>
2019-07-21 11:08:57 -07:00
Miss Islington (bot) a50a6225a0 bpo-37624: Document weight assumptions for random.choices() (GH-14855) (GH-14858)
(cherry picked from commit 8dbe563aa6)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2019-07-19 02:17:21 -07:00
Miss Islington (bot) 840352455d
bpo-37610: improve Using Python doc wrt Editors & IDE (GH-14850)
Move the Editors and IDE section out of the Unix section, to its own section.

https://bugs.python.org/issue37610
(cherry picked from commit 8f040b7a9f)

Co-authored-by: aldwinaldwin <aldwinaldwin@users.noreply.github.com>
2019-07-18 18:31:41 -07:00
Miss Islington (bot) 35d36dacd4
Docs: Correct formatting of a multiline code block (GH-13806)
(cherry picked from commit bd26a4466b)

Co-authored-by: Joseph Fox-Rabinovitz <madphysicist@users.noreply.github.com>
2019-07-17 01:32:53 -07:00
Miss Islington (bot) 86742d4ce8
Replace backquote with command substitution in subprocess doc example (GH-13941)
Replace backquotes with POSIXy command substitution in example.
(cherry picked from commit 6a61714cde)

Co-authored-by: David Jones <drj@pobox.com>
2019-07-16 08:05:39 -07:00
Miss Islington (bot) 1ff4c42774
bpo-37284: Add note to sys.implementation doc (GH-14328)
Add a brief note to indicate that any new required attributes must go through the PEP process.

https://bugs.python.org/issue37284
(cherry picked from commit 52693c10e8)

Co-authored-by: Giovanni Cappellotto <gcappellotto@fb.com>
2019-07-15 07:45:12 -07:00
Miss Islington (bot) 7a430109b9 bpo-37590: Remove redundant docs of PyEval_EvalFrameEx (GH-14765)
(cherry picked from commit 40d2226a69)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
2019-07-14 10:53:18 +02:00