cpython/Misc/NEWS.d
Victor Stinner 8fba9523cf
bpo-42398: Fix "make regen-all" race condition (GH-23362)
Fix a race condition in "make regen-all" when make -jN option is used
to run jobs in parallel. The clinic.py script now only use atomic
write to write files. Moveover, generated files are now left
unchanged if the content does not change, to not change the file
modification time.

The "make regen-all" command runs "make clinic" and "make
regen-importlib" targets:

* "make regen-importlib" builds object files (ex: Modules/_weakref.o)
  from source files (ex: Modules/_weakref.c) and clinic files (ex:
  Modules/clinic/_weakref.c.h)
* "make clinic" always rewrites all clinic files
  (ex: Modules/clinic/_weakref.c.h)

Since there is no dependency between "clinic" and "regen-importlib"
Makefile targets, these two targets can be run in parallel. Moreover,
half of clinic.py file writes are not atomic and so there is a race
condition when "make regen-all" runs jobs in parallel using make -jN
option (which can be passed in MAKEFLAGS environment variable).

Fix clinic.py to make all file writes atomic:

* Add write_file() function to ensure that all file writes are
  atomic: write into a temporary file and then use os.replace().
* Moreover, write_file() doesn't recreate or modify the file if the
  content does not change to avoid modifying the file modification
  file.
* Update test_clinic to verify these assertions with a functional
  test.
* Remove Clinic.force attribute which was no longer used, whereas
  Clinic.verify remains useful.
2020-11-18 15:36:27 +01:00
..
next bpo-42398: Fix "make regen-all" race condition (GH-23362) 2020-11-18 15:36:27 +01:00
3.5.0.rst
3.5.0a1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.5.0a2.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.5.0a3.rst bpo-35110: Fix unintentional spaces around hyphens and dashes. (GH-10231) 2018-10-31 02:26:06 +02:00
3.5.0a4.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.5.0b1.rst
3.5.0b2.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.5.0b3.rst bpo-35110: Fix unintentional spaces around hyphens and dashes. (GH-10231) 2018-10-31 02:26:06 +02:00
3.5.0b4.rst bpo-35110: Fix unintentional spaces around hyphens and dashes. (GH-10231) 2018-10-31 02:26:06 +02:00
3.5.0rc1.rst
3.5.0rc2.rst
3.5.0rc3.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.5.0rc4.rst
3.5.1.rst
3.5.1rc1.rst bpo-35110: Fix unintentional spaces around hyphens and dashes. (GH-10231) 2018-10-31 02:26:06 +02:00
3.5.2.rst
3.5.2rc1.rst Fix typos in docs, comments and test assert messages (#14872) 2019-07-21 16:12:33 -04:00
3.5.3.rst
3.5.3rc1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.5.4.rst
3.5.4rc1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.5.5.rst
3.5.5rc1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.6.0.rst
3.6.0a1.rst Fix typos in docs, comments and test assert messages (#14872) 2019-07-21 16:12:33 -04:00
3.6.0a2.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.6.0a3.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.6.0a4.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.6.0b1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.6.0b2.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.6.0b3.rst
3.6.0b4.rst
3.6.0rc1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.6.0rc2.rst
3.6.1.rst
3.6.1rc1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.6.2.rst
3.6.2rc1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.6.2rc2.rst bpo-34906: Doc: Fix typos (2) (GH-9735) 2018-10-06 16:35:53 +02:00
3.6.3.rst
3.6.3rc1.rst Fix typos in docs, comments and test assert messages (#14872) 2019-07-21 16:12:33 -04:00
3.6.4.rst
3.6.4rc1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.6.5.rst
3.6.5rc1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.6.6.rst
3.6.6rc1.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.7.0.rst
3.7.0a1.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.7.0a2.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0a3.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0a4.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0b1.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0b2.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0b3.rst bpo-34906: Doc: Fix typos (2) (GH-9735) 2018-10-06 16:35:53 +02:00
3.7.0b4.rst bpo-32523: Simplifying news entries with multiple paragraphs. (GH-8154) 2019-05-09 21:52:32 +02:00
3.7.0b5.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.7.0rc1.rst bpo-35042: Use the :pep: role where a PEP is specified (#10036) 2018-10-26 15:58:26 -07:00
3.8.0a1.rst Remove duplicated words words (GH-20413) 2020-05-26 01:04:14 -07:00
3.8.0a2.rst Minor edits to news entries (ported from 3.7) (GH-12293) 2019-03-12 12:21:22 -04:00
3.8.0a3.rst IDLE: changelog correction and addition (GH-15042) 2019-07-31 01:35:30 -04:00
3.8.0a4.rst Fix typos mostly in comments, docs and test names (GH-15209) 2019-08-30 16:21:19 -04:00
3.8.0b1.rst Remove duplicated words words (GH-20413) 2020-05-26 01:04:14 -07:00
3.9.0a1.rst bpo-4630: Fix errors in Lib/idlelib/NEWS.txt (GH-21594) 2020-07-23 02:06:26 -04:00
3.9.0a2.rst Correct name of bytecode in change note. (GH-22723) 2020-10-19 13:20:33 +01:00
3.9.0a3.rst Python 3.9.0a3 2020-01-24 22:05:07 +01:00
3.9.0a4.rst Python 3.9.0a4 2020-02-25 22:06:39 +01:00
3.9.0a5.rst bpo-39871: Fix an error in a news entry (GH-21749) 2020-08-07 14:38:48 +09:00
3.9.0a6.rst Python 3.9.0a6 2020-04-27 22:44:04 +02:00
3.9.0b1.rst bpo-34956: edit and format better NEWS item in 3.9.0b1 changelog (GH-20255) 2020-05-20 05:41:26 -04:00
3.10.0a1.rst Delete PyGen_Send (#22663) 2020-10-12 12:10:42 -07:00
3.10.0a2.rst Python 3.10.0a2 2020-11-03 00:02:08 +00:00