You can upgrade selenium to the newest version and use BiDi as this comment did.
however the line
chrome_options.add_argument("--remote-debugging-pipe")
disables CDP. but luckily i dont need the CDP