Update How can I create a vector layer in PyQGIS from a table without geom column?.md