Fix seeder crash on null game data and disable SQL logging by default
Skip games with null route data (Gen 8-9 have no PokeAPI encounters) and silence SQLAlchemy echo unless --verbose/-v is passed. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -77,6 +77,9 @@ async def seed():
|
||||
continue
|
||||
|
||||
routes_data = load_json(f"{game_slug}.json")
|
||||
if not routes_data:
|
||||
print(f" {game_slug}: no route data, skipping")
|
||||
continue
|
||||
route_map = await upsert_routes(session, game_id, routes_data)
|
||||
total_routes += len(route_map)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user