The bot script detects which operating system it is and runs the necessary commands. Currently, the script works well with Ubuntu but fails for MacOS. A fix for this issue resolves this bug