Update from 3.8.13 to 4.0 Errors

I’m following the 4.0 Migration Guide steps to move an application from 3.18.13 to 4.*.

This command, composer require --update-with-dependencies “cakephp/cakephp:4.0.*”
failed with the following errors:

Problem 1
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.11, 3.8.12, 3.8.13, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.9.0, 3.9.0-RC1, 3.9.0-RC2, 3.9.1, 3.9.2, 3.x-dev] but these conflict with your requirements or minimum-stability.
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.11, 3.8.12, 3.8.13, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.9.0, 3.9.0-RC1, 3.9.0-RC2, 3.9.1, 3.9.2, 3.x-dev] but these conflict with your requirements or minimum-stability.
- cakephp/bake 1.12.0 requires cakephp/cakephp ^3.8.0 -> satisfiable by cakephp/cakephp[3.8.0, 3.8.0-RC1, 3.8.0-RC2, 3.8.0-RC3, 3.8.0-beta1, 3.8.1, 3.8.10, 3.8.11, 3.8.12, 3.8.13, 3.8.2, 3.8.3, 3.8.4, 3.8.5, 3.8.6, 3.8.7, 3.8.8, 3.8.9, 3.9.0, 3.9.0-RC1, 3.9.0-RC2, 3.9.1, 3.9.2, 3.x-dev] but these conflict with your requirements or minimum-stability.
- Installation request for cakephp/bake (locked at 1.12.0, required as ^1.9.0) -> satisfiable by cakephp/bake[1.12.0].

How do I resolve this?

Thanks

You can first update composer.json with dependency versions as seen in https://github.com/cakephp/app/blob/master/composer.json and then run composer update --with-dependencies.