Omkaar
b6d5d5b60a
gh-98561: Fix a typo in typing (GH-98562)
2022-10-23 22:05:08 +08:00
C.A.M. Gerlach
8f30267ab4
gh-95913: Copyedit & xref FrameInfo in Whatsnew inspect section ( #98304 )
2022-10-22 20:12:04 +01:00
Clément Robert
327fc1c6fa
[Enum docs]: fix order of arguments to isinstance() ( #98542 )
2022-10-22 12:29:00 +01:00
Stanley
d9407b174c
gh-51511: Note that codecs.open()'s encoding parameter affects automatic conversion to binary mode ( #94370 )
2022-10-21 16:01:05 -07:00
Ethan Furman
3e95ffc7ae
gh-98298: [Enum] document ReprEnum, global_enum, and show_flag_values (GH-98455)
...
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-21 15:36:41 -07:00
Noam Cohen
a371a7e03e
gh-95023: Added os.setns and os.unshare functions ( #95046 )
...
Added os.setns and os.unshare to easily switch between namespaces
on Linux.
Co-authored-by: Christian Heimes <christian@python.org>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Victor Stinner <vstinner@python.org>
2022-10-20 11:08:54 +02:00
Phil Elson
1a6bacb31f
[doc] Refresh the venv introduction documentation, and correct the statement about VIRTUAL_ENV (GH-98350)
...
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-19 15:49:34 +01:00
Raymond Hettinger
a53f637368
Fix markup indentation (GH-98424)
...
Fix markup
2022-10-18 20:14:41 -05:00
Raymond Hettinger
f4ead4874b
General improvements to the itertools docs (GH-98408)
2022-10-18 14:09:34 -05:00
Julien Palard
2eb503e4dd
Doc: Found some remaining default roles. (GH-98392)
2022-10-18 15:46:18 +02:00
Julien Palard
0bbea545e3
Doc: missing underscore in hyperlink. (GH-98391)
2022-10-18 15:28:19 +02:00
Raymond Hettinger
de3ece769a
GH-98363: Add itertools.batched() (GH-98364)
2022-10-17 18:53:45 -05:00
Raymond Hettinger
70732d8a4c
Move random selection recipes from itertools.rst to random.rst (GH-98369)
2022-10-17 17:30:49 -05:00
Victor Stinner
1863302d61
gh-97669: Create Tools/build/ directory ( #97963 )
...
Create Tools/build/ directory. Move the following scripts from
Tools/scripts/ to Tools/build/:
* check_extension_modules.py
* deepfreeze.py
* freeze_modules.py
* generate_global_objects.py
* generate_levenshtein_examples.py
* generate_opcode_h.py
* generate_re_casefix.py
* generate_sre_constants.py
* generate_stdlib_module_names.py
* generate_token.py
* parse_html5_entities.py
* smelly.py
* stable_abi.py
* umarshal.py
* update_file.py
* verify_ensurepip_wheels.py
Update references to these scripts.
2022-10-17 12:01:00 +02:00
Joannah Nanjekye
5c9302d03a
gh-85525: Remove extra row in doc ( #98337 )
...
* remove extra row
* 📜 🤖 Added by blurb_it.
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2022-10-16 13:43:31 -04:00
Stanley
79fd6ccdbe
gh-85299: Add note warning about entry point guard for asyncio example ( #93457 )
2022-10-16 10:04:43 -07:00
Vinay Sajip
f6b1e4048d
gh-98307: Add docstring and documentation for SysLogHandler.createSocket (GH-98319)
...
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-16 09:15:46 +01:00
Kumar Aditya
660f10248b
GH-94597: Deprecate child watcher getters and setters ( #98215 )
...
This is the next step for deprecating child watchers.
Until we've removed the API completely we have to use it, so this PR is mostly suppressing a lot of warnings when using the API internally.
Once the child watcher API is totally removed, the two child watcher implementations we actually use and need (Pidfd and Thread) will be turned into internal helpers.
2022-10-15 16:09:30 -07:00
Raymond Hettinger
3a639bbeac
Improve speed. Reduce auxiliary memory to 16.6% of the main array. (GH-98294)
2022-10-15 16:05:28 -05:00
Simon Legner
02389658a4
docs(typing): harmonize "See PEP x for more details" ( #97927 )
2022-10-15 12:17:51 -07:00
Raymond Hettinger
f4370318d6
Faster sieve() recipe ( #98287 )
2022-10-15 12:43:58 -05:00
Joannah Nanjekye
bf786e6901
gh-85455: Add missing doc strings and improve docs ( #21573 )
...
* Add missing doc strings and improve docs
* Use imperative form
* Modify docstring wording
2022-10-15 09:31:06 -04:00
Joannah Nanjekye
05c042e707
gh-85525: Indicate supported sound header formats ( #21575 )
...
* Indicate supported sound header formats
* modify file names
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-15 09:30:05 -04:00
Julien Palard
3c4cbd177f
gh-91485: Doc: Using Python syntax to document builtin Python functions. (GH-96579)
2022-10-15 12:19:35 +02:00
Shantanu
c39a0c3354
gh-65046: Link to logging cookbook from asyncio docs ( #98207 )
2022-10-11 21:42:57 -07:00
Stanley
3b33c2010a
Formatting fixes in contextlib docs ( #98111 )
2022-10-11 20:56:32 -07:00
Shantanu
ed6344eed0
gh-96130: Rephrase use of "typecheck" verb for clarity ( #98144 )
...
I'm sympathetic to the issue report, especially in case this helps
clarify to new users that Python itself does not do type checking at runtime
2022-10-11 19:37:58 -07:00
Stanley
f0a680007f
gh-71616: Add note to warn against general translation of saxutils.escape() ( #93450 )
...
* Add note to warn against general translation of saxutils.escape()
* Use more direct wording
2022-10-11 05:27:49 -04:00
Vinay Sajip
6a757da080
gh-88452: Add a warning about non-portability of environments. (GH-98155)
2022-10-10 19:27:52 +01:00
Stanley
187e853690
gh-83940: os docs: Improve wording for getenv/getenvb ( #98113 )
2022-10-10 06:43:01 -07:00
Stanley
281a3f18cc
gh-56133: copyreg docs: Clarify function/constructor parameter ( #95497 )
2022-10-09 17:51:02 -07:00
JasonYZ
6b485629d2
gh-97822: Fix http.server documentation reference to test() function ( #98027 )
...
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-10-07 21:46:23 -07:00
Stanley
0f498f1a95
gh-57179: Add note on symlinks for os.walk ( #94799 )
2022-10-07 15:51:50 -07:00
Stanley
5eaf4d6101
gh-61105: Add default param, note on using cookiejar subclass ( #95427 )
2022-10-07 15:21:13 -07:00
Stanley
eed80458e8
gh-91708: Revert params note in urllib.parse.urlparse table ( #96699 )
...
Revert params note in urllib.parse.urlparse table
2022-10-07 12:19:36 -07:00
Stanley
676d8ef380
gh-65496: Correct wording on csv's skipinitialspace argument ( #96170 )
2022-10-07 11:15:34 -07:00
Stanley
4a74e6ab38
gh-64921: Clarify wording for open()'s newline arg ( #96171 )
2022-10-07 11:12:08 -07:00
Victor Stinner
002252c4ad
gh-97669: Move difflib examples to Doc/includes/ ( #97964 )
...
Remove diff.py and ndiff.py scripts of Tools/scripts/: move them to
Doc/includes/.
* diff.py and ndiff.py files are no longer executable. Remove also
their shebang ("#!/usr/bin/env python3").
* Remove the -profile command from ndiff.py to simply the code.
* Remove ndiff.py copyright and history command. The Python
documentation examples are distributed under the "Zero Clause BSD
License".
2022-10-07 10:57:48 -07:00
Christopher Chianelli
6592a62ec2
gh-71316: Update dis documentation to include changes to jump arguments (GH-95798)
2022-10-07 14:54:21 +01:00
Raymond Hettinger
e500cc0451
Misc updates to the itertools recipes and tests (GH-98018)
2022-10-07 03:37:21 -05:00
Julien Palard
66cc46b2e4
Doc: sphinx-lint finds two other default roles. (GH-98019)
2022-10-07 09:10:51 +02:00
Hugo van Kemenade
fa2d43e518
Docs: Fix backtick errors found by sphinx-lint ( #97998 )
...
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2022-10-06 18:01:30 -07:00
Nikita Sobolev
27025e158c
gh-97850: Remove deprecated functions from `importlib.utils` ( #97898 )
...
* gh-97850: Remove deprecated functions from `importlib.utils`
* Rebase and remove `set_package` from diff
2022-10-06 17:57:10 -07:00
Guido van Rossum
09de8d7aaf
GH-90985: Revert "Deprecate passing a message into cancel()" ( #97999 )
...
Reason: we were too hasty in deprecating this.
We shouldn't deprecate it before we have a replacement.
2022-10-06 17:30:27 -07:00
Brett Cannon
e1c4d56fdd
gh-65961: Do not rely solely on `__cached__` (GH-97990)
...
Make sure `__spec__.cached` (at minimum) can be used.
2022-10-06 15:40:22 -07:00
Jason R. Coombs
8af04cdef2
gh-97781: Apply changes from importlib_metadata 5. (GH-97785)
...
* gh-97781: Apply changes from importlib_metadata 5.
* Apply changes from upstream
* Apply changes from upstream.
2022-10-06 15:25:24 -04:00
180909
0d68879104
gh-95691: Doc BufferedWriter and BufferedReader ( #95703 )
2022-10-05 16:57:42 -07:00
Guido van Rossum
74ea204634
GH-88968: Add notes about socket ownership transfers ( #97936 )
2022-10-05 16:42:01 -07:00
Brett Cannon
c206e53bb7
gh-65961: Raise `DeprecationWarning` when `__package__` differs from `__spec__.parent` ( #97879 )
...
Also remove `importlib.util.set_package()` which was already slated for removal.
Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
2022-10-05 15:00:45 -07:00
Simon Legner
2016bc54a2
docs(typing): add "see PEP 675" to LiteralString ( #97926 )
2022-10-05 13:08:07 -07:00
Adam Turner
0031e62973
gh-93738: Documentation C syntax (:c:type:<C type> -> :c:expr:<C type>) ( #97768 )
...
:c:type:`<C type>` -> :c:expr:`<C type>`
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2022-10-05 11:01:14 -07:00
180909
d6062d1170
GH-95172 Make the same version `versionadded` oneline ( #95172 )
...
* Make the same version versionadded oneline
* Format versionadded for enum.rst
* Format versionadded
A single line versionadded was reading better.
Co-authored-by: Senthil Kumaran <senthil@python.org>
2022-10-05 10:52:59 -07:00
Serhiy Storchaka
e3ef400be7
gh-74696: Pass root_dir to custom archivers which support it (GH-94251)
...
Co-authored-by: Éric <merwok@netwok.org>
2022-10-05 12:48:59 +03:00
Jia Junjie
4b83cd0b22
gh-97661: Improve accuracy of sqlite3.Cursor.fetchone docs ( #97662 )
...
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-10-05 10:47:54 +02:00
Guido van Rossum
8079bef56f
GH-96704: Add {Task,Handle}.get_context(), use it in call_exception_handler() ( #96756 )
...
Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
2022-10-04 23:49:10 -07:00
Athos Ribeiro
0ceafa7fa4
Add re.VERBOSE flag documentation example ( #97678 )
...
The current re.VERBOSE documentation example leaves space for ambiguous
interpretation. One may read that spaces within the `(?:` token are
spaces inside the non-capturing group (such as `(?: )`). This patch
removes the ambiguity by including examples after the statement.
2022-10-04 17:39:42 -07:00
Adam Turner
a0f5599aac
gh-93738: Documentation C syntax (Use `c:struct`) ( #97772 )
...
Use `c:struct`
2022-10-04 16:26:14 -07:00
Adam Turner
0bf6a617ed
gh-93738: Documentation C syntax (:c:type:`PyObject` -> :c:expr:`PyObject`) ( #97776 )
...
:c:type:`PyObject` -> :c:expr:`PyObject`
2022-10-04 16:13:03 -07:00
cousteau
ff28d8926d
gh-88355: Fix backslashes in AF_PIPE ( #96543 )
...
Fix backslashes in AF_PIPE (#88355 )
The correct syntax for AF_PIPE addresses is `\\.\pipe\blahblah`, not `\.\pipe{blahblah}`, but the syntax markup messed up the backslashes.
2022-10-04 15:54:03 -07:00
Ev2geny
743453a554
gh-58451: Add optional delete_on_close parameter to NamedTemporaryFile (GH-97015)
2022-10-04 23:37:33 +01:00
Daniel Giger
7acb93f0d4
gh-96448: fix documentation for _thread.lock.acquire ( #96449 )
...
* fix documentation for _thread.lock.acquire
* update formatting of _thread.lock.acquire() doc
2022-10-04 15:18:04 -07:00
Inada Naoki
87679a6e60
gh-90301: Doc: Add references to PEP 686 ( #96816 )
...
Doc: Add references to PEP 686.
2022-10-04 15:04:44 -07:00
Kumar Aditya
53503ff60e
GH-82604: fix docs about configuring selector ( #97755 )
2022-10-04 09:45:37 -07:00
Rohan Shah
d053c47bfd
Minor grammar changes to http.client docs ( #96221 )
...
Minor grammar changes
2022-10-03 16:19:39 -07:00
Géry Ogam
0c91a12511
Update http.client.rst ( #24803 )
...
* Update http.client.rst
* Apply suggestions from code review
Co-authored-by: Éric <merwok@netwok.org>
* Update http.client.rst
Co-authored-by: Éric <merwok@netwok.org>
Co-authored-by: Senthil Kumaran <senthil@python.org>
2022-10-03 16:18:36 -07:00
Ivan Kapeykin
d78aa4e11a
multiprocessing docs: Remove extra option ELLIPSIS from section with code ( #96625 )
2022-10-03 15:41:08 -07:00
Boris Verkhovskiy
0ea8b925d0
Document that MozillaCookieJar works for curl's cookie files ( #91852 )
...
MozillaCookieJar works for curl's cookies
2022-10-03 15:07:54 -07:00
Victor Stinner
64fe343717
gh-97681: Remove Tools/demo/ directory ( #97682 )
...
Remove the Tools/demo/ directory which contained old demo scripts. A
copy can be found in the old-demos project:
https://github.com/gvanrossum/old-demos
Remove the following old demo scripts:
* beer.py
* eiffel.py
* hanoi.py
* life.py
* markov.py
* mcast.py
* queens.py
* redemo.py
* rpython.py
* rpythond.py
* sortvisu.py
* spreadsheet.py
* vector.py
Changes:
* Remove a reference to the redemo.py script in the regex howto
documentation.
* Remove a reference to the removed Tools/demo/ directory in the
curses documentation.
* Update PC/layout/ to remove the reference to Tools/demo/ directory.
2022-10-03 17:09:02 +02:00
annonm
e6f9ec5c03
Fix typo in unittest docs ( #97742 )
2022-10-03 06:35:40 -07:00
Kumar Aditya
9151bbefea
GH-85447: Clarify docs about awaiting future multiple times ( #97738 )
2022-10-02 15:16:51 -07:00
Gregory P. Smith
8baef8ae36
gh-95588: Drop the safety claim from `ast.literal_eval` docs. ( #95919 )
...
It was never really safe and this claim conflicts directly with the big warning in the docs about it being able to crash the interpreter.
2022-10-01 17:55:40 -07:00
Will Hawkins
bd7d0e875e
Fix capitalization of Unix in documentation ( #96913 )
2022-10-01 16:41:06 -07:00
Łukasz Langa
f00645d5db
gh-90908: Document asyncio.Task.cancelling() and asyncio.Task.uncancel() ( #95253 )
...
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
2022-10-01 10:42:36 -07:00
Gregory P. Smith
b05dd79649
gh-87597: Document TimeoutExpired.stdout & .stderr types ( #97685 )
...
This documents the behavior that has always been the case since timeout
support was introduced in Python 3.3.
2022-09-30 10:45:47 -07:00
Jeff Allen
9a11ed8e50
gh-96397: Document that attributes need not be identifiers ( #96454 )
...
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-09-29 16:02:27 -07:00
Stanley
c759944f16
gh-52597: Add position-only markers for os functions ( #94735 )
2022-09-28 18:06:50 -07:00
Kumar Aditya
575a253b5c
GH-82448: Add thread timeout for loop.shutdown_default_executor ( #97561 )
...
Co-authored-by: Kyle Stanley <aeros167@gmail.com>
2022-09-28 10:39:42 -07:00
Kumar Aditya
9a404b173e
fixup policy docs ( #97618 )
2022-09-28 10:34:49 -07:00
C.A.M. Gerlach
cc0f3a10f0
gh-96377: Update asyncio policy doc intro paras to be clear and accurate ( #97603 )
...
Also fix up some cross-references in the asyncio docs.
2022-09-27 16:47:14 -07:00
Serhiy Storchaka
dd53b79de0
gh-96959: Update more HTTP links (GH-97536)
...
Use HTTPS for documents which are available by both HTTP and HTTPS
links, but there is no redirection from HTTP to HTTPS or vice versa.
2022-09-27 14:08:11 +03:00
Kumar Aditya
d68c37c0d0
GH-65046: Fix docs about logging in `asyncio` ( #97559 )
...
Explain that logging should not use network I/O.
2022-09-26 15:27:15 -07:00
Serhiy Storchaka
db39050396
gh-96959: Update HTTP links which are redirected to HTTPS (GH-96961)
2022-09-24 14:38:53 +03:00
Steve Dower
a4ac14faa5
gh-77171: Fixes SubFormat check to compare the entire value. Add docs (GH-97509)
2022-09-23 16:08:21 +01:00
Harry
ec403536f1
include OrderedDict import in TimeBoundedLRU example (GH-96962)
2022-09-22 10:58:19 -05:00
partev
b4f5f07d07
Doc: fix link redirect (GH-96606)
...
"Hyperbolic_function" -> "Hyperbolic_functions"
2022-09-21 21:47:46 +02:00
Vinay Sajip
6ad47b41a6
gh-96727: Document restrictions on Handler.emit() with respect to locking. (GH-96948)
2022-09-20 09:40:06 +01:00
Gregory P. Smith
34de67c094
gh-96512: Update int_max_str docs to say 3.11 ( #96942 )
...
It was unknown if it'd be before 3.11.0 when creating the original
changes. It's in 3.11rc2, so 3.11 it is.
2022-09-19 16:43:11 -07:00
Shantanu
5b3a2569f4
gh-96917: link to typing.readthedocs.io from typing.rst ( #96921 )
...
See the discussion at https://github.com/python/cpython/issues/91533
2022-09-19 12:09:41 -07:00
Raymond Hettinger
bbc24b2bd5
GH-96851: Add link to FAQ entry for caching method calls. (GH-96902)
2022-09-18 16:36:20 -05:00
partev
2d1a2d902a
fix various typos in random module's documentation (GH-96912)
2022-09-18 14:35:22 -07:00
Scott Main
810ae51787
gh-94787: [doc] Add to argparse doc an example of a mutually-exclusive group nested in an argument group (GH-94807)
2022-09-18 09:05:43 +01:00
Raymond Hettinger
670007abb4
Clarify that the expression is regular math notation, not Python. ( #96903 )
2022-09-17 21:09:39 -05:00
Raymond Hettinger
78359b1d45
Simplify sieve() recipe. Add edge case tests. (GH-96892)
2022-09-17 11:31:04 -05:00
Victor Stinner
e841ffc915
gh-95778: Mention sys.set_int_max_str_digits() in error message ( #96874 )
...
When ValueError is raised if an integer is larger than the limit,
mention sys.set_int_max_str_digits() in the error message.
2022-09-16 20:04:37 +02:00
Erlend E. Aasland
16c33a9676
gh-96810: Clarify for which statements sqlite3 implicitly opens transactions ( #96832 )
2022-09-15 23:11:52 +02:00
Raymond Hettinger
8dc9b3fbc1
Itertools sieve() recipe ( #96813 )
2022-09-13 21:10:47 -05:00
Benjamin Peterson
fd1e477f53
closes gh-96734: Update to Unicode 15.0.0. (GH-96809)
2022-09-13 15:45:12 -07:00
Alex Waygood
bf5fd49252
gh-95778: Fix `sys.set_int_max_str_digits()` parameter name ( #96798 )
...
Discovered in https://github.com/python/typeshed/pull/8733
2022-09-13 08:22:50 -07:00
Erlend E. Aasland
49cceeb5c9
gh-96702: Order methods before attrs in sqlite3.Connection docs ( #96703 )
2022-09-13 10:28:57 +02:00
zhanpon
53a54b781d
gh-96706: [doc] Don't recomment deprecated use of get_event_loop() in examples ( #96707 )
2022-09-11 12:56:30 -07:00