-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Map: Reset Spawnpoints after migration #234
base: develop
Are you sure you want to change the base?
Map: Reset Spawnpoints after migration #234
Conversation
@@ -138,10 +138,12 @@ def get_spawnpoint_markers(): | |||
spawns = session.query(Spawnpoint) | |||
return [{ | |||
'spawn_id': spawn.spawn_id, | |||
'despawn_time': spawn.despawn_time, | |||
'despawn_time': spawn.despawn_time | |||
if spawn.updated and spawn.updated > conf.LAST_MIGRATION else None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say truth-testing spawn.updated
before the comparison isn't necessary. The default migration time isn't zero and if someone wants to disable migration checks entirely they should set LAST_MIGRATION
to 1
or any time before their first scan. So with a valid configuration spawn.updated > conf.LAST_MIGRATION
should always fail when spawn.updated
fails the truth test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
after removing the spawn.updated and
I get TypeError: unorderable types: NoneType() > int()
guess I'll have to readd it
c4a6aec
to
0a2ed10
Compare
Marking not jet updated spawns as mysteries again
0a2ed10
to
b9793ef
Compare
Cleaned up duplicate and unused imports.
Marking not jet updated spawns as mysteries again