The solution is posted in the following github repository:
You should change the footprints.py file with the updated code. To do so you can:
-open the file in the osmnx package paste, delete its contents and copy the updated ones or,
-create a new file and ...
I had the same problems a few months ago. I had polygons in my database with a lot of self-intersections. I used the method of Niklas Aven, but it did not work. I also used other methods.
My method is to remove the self intersection from my polygons. Here is the SQL query i used:
-- Create the new polygons
SELECT ST_GeomFromText(polygone) as geom