Changed steam sale offer checker
All checks were successful
Deploy dev on push / on-push-deploy_sh-edraft (push) Successful in 4m5s
All checks were successful
Deploy dev on push / on-push-deploy_sh-edraft (push) Successful in 4m5s
This commit is contained in:
parent
b8356917b3
commit
ed72620d33
@ -66,7 +66,7 @@ class SteamOfferWatcher(TaskABC):
|
||||
def _get_games_from_page(self, start: int, count: int) -> List[SteamSpecialOffer]:
|
||||
games = List(SteamSpecialOffer)
|
||||
result = requests.get(
|
||||
f"https://store.steampowered.com/search/results?query&start={start}&count={count}&force_infinite=1&specials=1"
|
||||
f"https://store.steampowered.com/search/results?query&start={start}&count={count}&force_infinite=1&specials=1&filter=topsellers"
|
||||
)
|
||||
soup = bs4.BeautifulSoup(result.text, "lxml")
|
||||
elements = soup.find_all("a", {"class": "search_result_row"})
|
||||
@ -109,7 +109,7 @@ class SteamOfferWatcher(TaskABC):
|
||||
new_offers = List(SteamSpecialOffer)
|
||||
|
||||
# sale_count = self._get_max_count() + 100
|
||||
sale_count = 500 # only look at first 500
|
||||
sale_count = 250 # only look at first 500
|
||||
# todo: let admins change the value
|
||||
self._logger.debug(__name__, f"Get special offers from 0 to {sale_count}")
|
||||
for i in range(0, sale_count, 100):
|
||||
|
Loading…
Reference in New Issue
Block a user