debug
This commit is contained in:
parent
0a43465504
commit
1c70741531
@ -4,6 +4,7 @@ import json
|
|||||||
import requests
|
import requests
|
||||||
import time
|
import time
|
||||||
import os
|
import os
|
||||||
|
import pdb
|
||||||
|
|
||||||
|
|
||||||
def get_log(log_path_files="/data/logs/ops/ops.log"):
|
def get_log(log_path_files="/data/logs/ops/ops.log"):
|
||||||
@ -45,6 +46,7 @@ def set_gameinfo_ext(gameids: list) -> bool:
|
|||||||
i = 0
|
i = 0
|
||||||
for line in gameids:
|
for line in gameids:
|
||||||
try:
|
try:
|
||||||
|
pdb.set_trace()
|
||||||
oldGameId = line.get("gameid", 0)
|
oldGameId = line.get("gameid", 0)
|
||||||
platform = line.get("platform", 0)
|
platform = line.get("platform", 0)
|
||||||
url = game_info_url.format(gameid=oldGameId, platformid=platform)
|
url = game_info_url.format(gameid=oldGameId, platformid=platform)
|
||||||
@ -68,6 +70,7 @@ def set_game_price(gameids: list) -> bool:
|
|||||||
i = 0
|
i = 0
|
||||||
for line in gameids:
|
for line in gameids:
|
||||||
try:
|
try:
|
||||||
|
pdb.set_trace()
|
||||||
oldGameId = line.get("gameid", 0)
|
oldGameId = line.get("gameid", 0)
|
||||||
platform = line.get("platform", 0)
|
platform = line.get("platform", 0)
|
||||||
logger.info(f"start get {oldGameId} {platform} game price!")
|
logger.info(f"start get {oldGameId} {platform} game price!")
|
||||||
@ -91,6 +94,7 @@ def set_history_price(gameids: list) -> bool:
|
|||||||
i = 0
|
i = 0
|
||||||
for line in gameids:
|
for line in gameids:
|
||||||
try:
|
try:
|
||||||
|
pdb.set_trace()
|
||||||
oldGameId = line.get("gameid", 0)
|
oldGameId = line.get("gameid", 0)
|
||||||
platform = line.get("platform", 0)
|
platform = line.get("platform", 0)
|
||||||
logger.info(f"start get {oldGameId} {platform} history price!")
|
logger.info(f"start get {oldGameId} {platform} history price!")
|
||||||
@ -181,8 +185,8 @@ def get_inc_gamelist() -> list:
|
|||||||
mongo_db['gameinfo'].update_one({'oldGameId': gameid},
|
mongo_db['gameinfo'].update_one({'oldGameId': gameid},
|
||||||
{'$set': item},
|
{'$set': item},
|
||||||
upsert=True)
|
upsert=True)
|
||||||
# if len(diff_gameid) >= 2:
|
if len(diff_gameid) >= 2:
|
||||||
# return diff_gameid
|
return diff_gameid
|
||||||
else:
|
else:
|
||||||
logger.debug(f"get {url} {info} ")
|
logger.debug(f"get {url} {info} ")
|
||||||
break
|
break
|
||||||
|
Loading…
x
Reference in New Issue
Block a user