This is probably caused by this PR, the result of a three day test session pihole -g now uses a temporary database, to build the new gravity table. The content of the existing database is than copied over, the temporary database than becomes the live one.
I assume @DL6ER did NOT copy over all the tables, or the copy process has a bug.
I also wonder what happens if users are using the web interface, while pihole -g is running. should the database not be locked (+ warning) during pihole -g?
Hmm, yes, but it seems better to just move copy process itself further down, immediately before the swapping. Hereby, users will be able to use the database all the time and no locking happens. If they would try to add something in the exact milliseconds the swapping happens, we already show an error as the database will indeed be locked during this short time interval.
edit Reproduced. Group assignments are correctly copied and kept.
However, one of the triggers fires and adds the default group for all added clients on top of their already configured groups. This is clearly a bug and needs to be addresses. The only way to do this is to delete the triggers before copying the stuff and re-add them later again.