New submission from Stefan Behnel stefan_ml@behnel.de:
The documentation of the PyContextVar C-API is unclear in a couple of places.
- It's not clear whether PyContextVar_Get() always returns an owned reference also for default values or only if a value was found. - It's not explicit that "optional" actually means "pass an object reference or NULL". - The return value of PyContextVar_Set() is not explained.
---------- assignee: docs@python components: Documentation messages: 392128 nosy: docs@python, scoder priority: normal severity: normal status: open title: Improve documentation of PyContextVar C-API type: enhancement versions: Python 3.10, Python 3.11, Python 3.8, Python 3.9
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Change by Stefan Behnel stefan_ml@behnel.de:
---------- keywords: +patch pull_requests: +24362 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25671
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
miss-islington mariatta.wijaya+miss-islington@gmail.com added the comment:
New changeset 4c49be766897968e509c41397e0e624c25b1675d by scoder in branch 'master': bpo-43959: clarify the documentation of the PyContextVar C-API (GH-25671) https://github.com/python/cpython/commit/4c49be766897968e509c41397e0e624c25b...
---------- nosy: +miss-islington
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Change by miss-islington mariatta.wijaya+miss-islington@gmail.com:
---------- pull_requests: +24379 pull_request: https://github.com/python/cpython/pull/25689
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Change by miss-islington mariatta.wijaya+miss-islington@gmail.com:
---------- pull_requests: +24380 pull_request: https://github.com/python/cpython/pull/25690
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Stefan Behnel stefan_ml@behnel.de added the comment:
New changeset fdb11897d7c8f9e6bdf96fcef802f784ef90f726 by Miss Islington (bot) in branch '3.9': bpo-43959: clarify the documentation of the PyContextVar C-API (GH-25671) (GH-25689) https://github.com/python/cpython/commit/fdb11897d7c8f9e6bdf96fcef802f784ef9...
----------
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Stefan Behnel stefan_ml@behnel.de added the comment:
New changeset ff7266efd0ef6b42dad30c9c0d210f843cc44f39 by Miss Islington (bot) in branch '3.8': bpo-43959: clarify the documentation of the PyContextVar C-API (GH-25671) (GH-25690) https://github.com/python/cpython/commit/ff7266efd0ef6b42dad30c9c0d210f843cc...
----------
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________
Change by Stefan Behnel stefan_ml@behnel.de:
---------- resolution: -> fixed stage: patch review -> resolved status: open -> closed
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue43959 _______________________________________