PyDocs

Nav

Python Runtime Services

set_threshold

gc

function
  • set_threshold(threshold0[, threshold1[, threshold2]])
set_threshold(threshold0, [threshold1, [threshold2]])
Set the collection thresholds (the collection frequency).

Setting 'threshold0' to zero disables collection.
Changed in 3.14, 3.14.5
  • 3.14: threshold2 is ignored
  • 3.14.5: threshold2 is restored to match Python 3.13 behavior.
0 Examples
No examples for gc/set_threshold.
See Also
No see-alsos for gc/set_threshold
0 Notes
No notes for set_threshold