Commit e2335fd
committed
Document gc.enable_parallel(N) strict re-enable contract in docstring
Phase 5.1.5 changed observable API behaviour: enable_parallel(N)
called while parallel GC is already enabled with a *different* N
now raises RuntimeError instead of silently keeping the old N.
The docstring did not mention this. A user calling enable_parallel
twice in real code would hit the exception with no documented
explanation.
Also document the adaptive worker count introduced in Phase 5.3:
num_workers is the upper bound; the controller dynamically adjusts
the active count per collection between 2 and num_workers via a
biased constrained random walk.
Argument Clinic regenerated (Modules/clinic/gcmodule.c.h).
Verified: docstring visible via gc.enable_parallel.__doc__ after
rebuild; full test suite still green.1 parent 5501b73 commit e2335fd
2 files changed
Lines changed: 27 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
503 | 503 | | |
504 | 504 | | |
505 | 505 | | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
506 | 515 | | |
507 | 516 | | |
508 | 517 | | |
509 | 518 | | |
510 | 519 | | |
511 | | - | |
| 520 | + | |
512 | 521 | | |
513 | 522 | | |
514 | 523 | | |
| |||
636 | 645 | | |
637 | 646 | | |
638 | 647 | | |
639 | | - | |
| 648 | + | |
640 | 649 | | |
641 | 650 | | |
642 | 651 | | |
| |||
699 | 708 | | |
700 | 709 | | |
701 | 710 | | |
702 | | - | |
| 711 | + | |
703 | 712 | | |
704 | 713 | | |
705 | 714 | | |
| |||
790 | 799 | | |
791 | 800 | | |
792 | 801 | | |
793 | | - | |
| 802 | + | |
794 | 803 | | |
795 | 804 | | |
796 | 805 | | |
| |||
0 commit comments