I came here because I had the same issue. @joan's answer and package fixes the issue but @joans answer doesn't give some specifics on how to get it working (without looking at the page and/or documentation).
On my installation (Rasbian buster), pigpio comes pre-installed, you just have to enable it:
systemctl enable pigpio
systemctl start pigpio
Here is a ...
If I was going to do this I would use hardware PWM which continues to run after the program exits.
Hardware PWM is available in my Pi.GPIO (which is a superset of RPi.GPIO). It is also available in pigpio
The following modification to your program should work (I have not tested it) and avoid the strange sleep and need to kill processes, although it is rather ...