I had multiple errors that had to do with ui files and qt designer. What solved the problem for me is using the version installed with qgis"Qt Designer with QGIS custom widgets", which is a lighter version but works just fine.