ARM-software / devlib

Library for interaction with and instrumentation of remote devices.
Apache License 2.0
47 stars 78 forks source link

module/cgroups: Fix move_tasks()/move_all_tasks_to() #592

Closed douglas-raillard-arm closed 2 years ago

douglas-raillard-arm commented 2 years ago

Both move_all_tasks_to() and move_tasks() take a list of grep patterns to exclude.

It turned out that move_all_tasks_to() was calling move_tasks() with a string instead of a list, leading to broken quoting.

Fix that by passing the pattern list to move_tasks() and let move_tasks() add the "-e" option in front of it. Also add a DeprecationWarning in move_tasks() if someone passes a string instead of an iterable of strings.