ospaceteam / outerspace

Outer Space is turn-base 4X multiplayer on-line strategy game.
GNU General Public License v2.0
20 stars 10 forks source link

When galaxy is deleted, players are not unregistered #209

Closed dahaic closed 6 years ago

dahaic commented 6 years ago

Triggered by deletion via osclient_tui.py. That has unfortunate consequence of errors for given account when logging in.

dahaic commented 6 years ago

The issue is actually more complex. First of all, in 0.5.74, this particular behavior cannot be observed. This was only possible in 0.5.73.

Whole problem was mismatch between DB cache and DB itself. Sometimes DB cache two similar keys, integer and string variants of the OID, and so commands issued from osclient_tui got fed empty version of object, from DB cache (string variant). That meant planets and systems were not deleted properly. And in 0.5.73, player galaxies were regenerated every turn from existing planets, thus now nonexistent galaxy (from system.comp) got added back to player.