sadpanda + typo
This commit is contained in:
parent
c9a838d368
commit
e9f629dee4
|
@ -3,7 +3,7 @@
|
|||
|
||||
A Microsoft reward automator, designed to work headless on any server.
|
||||
Using a discord webhook or SQL to log points everyday.
|
||||
Using Selenium and geckodriver.
|
||||
Using Selenium and Geckodriver.
|
||||
|
||||
## If you're using docker (way easier)
|
||||
to use docker, run
|
||||
|
@ -12,14 +12,14 @@ sudo docker build .
|
|||
#copy the build id
|
||||
sudo docker run -ti --name MsRewards [build id]
|
||||
```
|
||||
Then, fill the config and start the programm everydays with
|
||||
Then, fill the config and start the program everyday with
|
||||
```
|
||||
sudo docker start MsRewards
|
||||
```
|
||||
|
||||
## Other configuration
|
||||
|
||||
To use the database, I recommand MySql, Create a database with the name you want and create a table `daily`, like the one from the image :
|
||||
To use the database, I recommend MySql, Create a database with the name you want and create a table `daily`, like the one from the image :
|
||||
![B96F2F6D-7257-4F12-BFA7-0BEC3FB72993](https://user-images.githubusercontent.com/74496300/172872979-05396b6b-b682-471a-b71b-41602d816504.jpeg)
|
||||
|
||||
You have to use the default world list (`sudo apt install wfrench`). The language is french by default, but you can change it if you want.
|
||||
|
|
11
V5.py
11
V5.py
|
@ -15,9 +15,8 @@ def printf(e):
|
|||
printf2(str(e), _mail)
|
||||
|
||||
# TODO
|
||||
# handle "panda"'s error: error while logging in preventing some task to be done
|
||||
# handle "panda"'s error: error while logging in preventing some task to be done SadPanda.svg
|
||||
# check that each card worked (lot of misses lately) -- test that -- don't crash at least
|
||||
# Fix l'affichage du compteur de custom_sleep
|
||||
|
||||
|
||||
# create a webdriver
|
||||
|
@ -233,7 +232,7 @@ def all_cards(): # return to the main page and closes all other tabs
|
|||
driver.get("https://www.bing.com/rewardsapp/flyout")
|
||||
reset(part2)
|
||||
|
||||
def daily_cards(): # cartes de la premiere partie (renouvelées chaque jours).
|
||||
def daily_cards(): # cartes de la premiere partie (renouvelée chaque jour).
|
||||
try:
|
||||
# make sure that the daily area is expanded
|
||||
row_element = driver.find_elements(By.CSS_SELECTOR, f'[class="i-h rw-sh fp_row"]')[0]
|
||||
|
@ -307,7 +306,7 @@ def all_cards(): # return to the main page and closes all other tabs
|
|||
|
||||
try :
|
||||
#top_cards()
|
||||
print("top card not working really well right now. Disableing them")
|
||||
print("top card not working really well right now. They are currently disabled")
|
||||
except Exception as e:
|
||||
log_error(e)
|
||||
|
||||
|
@ -475,6 +474,10 @@ def login(ldriver):
|
|||
ldriver.refresh()
|
||||
rgpd_popup(ldriver) # Ultra important
|
||||
ldriver.get("https://www.bing.com/rewardsapp/flyout")
|
||||
if "SadPanda.svg" in ldriver.page_source :
|
||||
log_error('test SadPanda before', ldriver)
|
||||
ldriver.refresh()
|
||||
log_error('test SadPanda after', ldriver)
|
||||
if not('>Tableau de bord' in ldriver.page_source):
|
||||
try :
|
||||
ldriver.find_element(By.CSS_SELECTOR, "[h='ID=RewardsFlyout,2.1']").click()
|
||||
|
|
Loading…
Reference in New Issue