alexschimpf / Snkrs-Bot

Selenium bot for Nike Snkrs site
The Unlicense
846 stars 289 forks source link

Waiting for login in button to become clickable #11

Open SilvesterLi opened 5 years ago

SilvesterLi commented 5 years ago

python main.py --username 'username' --password 'password' --url 'https://www.nike.com/launch/t/air-jordan-1-high-fearless/' --shoe-size 9.5 --release-time '11/2/2019' --driver-type 'chrome' --headless --num-retries 100 2019-10-31 06:59:05,821 [PID 1237] [Thread 4722918848] [INFO] [root] Requesting page: https://www.nike.com/us/en_us/ 2019-10-31 06:59:07,824 [PID 1237] [Thread 4722918848] [INFO] [root] Page load timed out but continuing anyway 2019-10-31 06:59:07,824 [PID 1237] [Thread 4722918848] [INFO] [root] Waiting for login button to become clickable

alexschimpf commented 5 years ago

Nike has changed their HTML since I wrote this script. The login button no longer matches the XPATH I'm using. I'm not really maintaining this anymore, but you can always fork it.

SilvesterLi commented 5 years ago

Nike has changed their HTML since I wrote this script. The login button no longer matches the XPATH I'm using. I'm not really maintaining this anymore, but you can always fork it.

I know, so I tried to switch the xpath to class_name, but still didn't working

alexschimpf commented 5 years ago

You can try debugging by using the --screenshot-path and --html-path scripts args, or just don't use headless mode. You can also try using XPATH to match the data-type or data-path attribute of the login button.

SilvesterLi commented 5 years ago

You can try debugging by using the --screenshot-path and --html-path scripts args, or just don't use headless mode. You can also try using XPATH to match the data-type or data-path attribute of the login button.

ok,thank you, i will try later

smallzZz8 commented 4 years ago

You can try debugging by using the --screenshot-path and --html-path scripts args, or just don't use headless mode. You can also try using XPATH to match the data-type or data-path attribute of the login button.

ok,thank you, i will try later

Any luck on this?

yuansshi commented 4 years ago

one of the option is try using this link instead. NIKE_HOME_URL = "https://www.nike.com/login"

it can bypass some of the code. I do have it coded up already.

alexschimpf commented 4 years ago

Looks like there is a PR out for this fix: https://github.com/alexschimpf/Snkrs-Bot/pull/18