your particular case has been warning since july of 2020 with a message similar to this:
$ pre-commit run flake8 --all-files
[WARNING] normalizing pre-commit configuration to a top-level map. support for top level list will be removed in a future version. run: `pre-commit migrate-config` to automatically fix this.
flake8...................................................................Passed
fortunately, even if you've already upgrade to pre-commit 3.0 (which drops support for this format) you can still run pre-commit migrate-config
which will update your configuration to a supported format:
$ pre-commit migrate-config
Configuration has been migrated.
$ pre-commit run flake8 --all-files
flake8...................................................................Passed
disclaimer: I authored pre-commit