If you cannot work on the marriage or the women is a moron, staying married and cheating makes the most sense because divorce is disruptive to the family life and your bank account.
Warning: PHP Startup: Unable to load dynamic library 'imagick.so' (tried: /usr/local/lib/php/extensions/no-debug-non-zts-20200930/imagick.so (/usr/local/lib/php/extensions/no-debug-non-zts-20200930/imagick.so: cannot open shared object file: No such file or directory), /usr/local/lib/php/extensions/no-debug-non-zts-20200930/imagick.so.so (/usr/local/lib/php/extensions/no-debug-non-zts-20200930/imagick.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0