At this status, there is an Odoo errorthat have its source here:
If you delete from code lines from 103 to 137, then there is no error at all, and it works and do the res.config.settings tasks on new company.
res.config.settings
The error was solved.
The MR is ready to be merged to main.