Open DominicLavery opened 4 days ago
🤖 According to the primer, this change has no effect on the checked open source code. 🤖🎉
This comment was generated for commit ff64dd84af8ee9afd0a345d248054bddfc73b0b4
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 95.80%. Comparing base (
68cb5b3
) to head (ab7b61b
).
🚨 Try these New Features:
🤖 According to the primer, this change has no effect on the checked open source code. 🤖🎉
This comment was generated for commit ab7b61b0ea4134c577bc221ec1eae80c98210459
Type of Changes
Description
In containers running on cgroupv2 systems
_query_cpu
currently returnsNone
. This results insched_getaffinity
being used, which will normally return all installed CPUs of the host. This can result in crashes with the error:The changes here use the CPU quota in v2 systems.
max 100000
is the default value, and will continue to result in the hosts CPU count being used.cpu.weight
(the replacement of cpu shares from v1) could also be used, but as it's impact on CPU scheduling is relative to the rest of the cgroup hierarchy it isn't possible to get an accurate value on all systems where pylint may be run. Whereas this method is reliable on any container with a CPU quota