Zend certified PHP/Magento developer

Error when switch composer 1 to composer 2

PHP Fatal error: Declaration of MagentoComposerRootUpdatePluginPluginCommandsOverrideRequireCommand::execute(SymfonyComponentConsoleInputInputInterface $input, SymfonyComponentConsoleOutputOutputInterface $output) must be compatible with ComposerCommandRequireCommand::execute(SymfonyComponentConsoleInputInputInterface $input, SymfonyComponentConsoleOutputOutputInterface $output)

i am using magento 2.4.3-p1 and composer 1, now when i update composer to 2 and run composer -v it gives me the above error