Catch exceptions when the composer.json can't be created