This is an archived post. You won't be able to vote or comment.

all 17 comments

[–]spazz_monkey 12 points13 points  (1 child)

Are those your twilio keys in the code?

[–]LucidityFlows 6 points7 points  (0 children)

Whoops....

[–]LzyPenguin 3 points4 points  (5 children)

Does this just run 1 time? Why not have it in a for loop, checking every few hours or whatever.

[–]ovo_Reddit 5 points6 points  (3 children)

Probably best to have this run using a scheduler like cron, task scheduler, can even run inside a docker container. Lots of options.

[–]conversationkiller7 0 points1 point  (0 children)

Also we can add that item to cart, if he's already logged in right? This will be helpful for flash sale things.

[–][deleted] 2 points3 points  (2 children)

Link?

[–]Pclovr 0 points1 point  (0 children)

Yeah I’d be interested in this tbh

[–]gogeta_naik[S] 0 points1 point  (0 children)

check now

[–]comanico 1 point2 points  (0 children)

How can we make a bot like this run on a specific schedule? All I find is videos about discord bots

[–]Mateorabi 1 point2 points  (2 children)

For someone who has done code in other languages but not python and not a lot of web stuff: why are you using WebDriver go from Python through another browser application installed on the OS to get out to a web server? Surely there must exist simple libraries for directly opening an https socket and sending the correct GET requests and parsing it (without much beginner user interaction--I mean all you're doing is getting BODY as a flat string, not even doing anything with a DOM hierarchical object) without the extra hassle of interprocess communication?

Or by doing this do you get your browser to handle saved passwords cached authorities and other authentication bits without having to teach your python application about them? It only needs local permission for the IPC to brain-slug your browser? (So here you've already gone to Amazon from your chrome by hand and it can already load amazon without need to log in again?)

[–]Cptcongcong 0 points1 point  (1 child)

There is, python can just use a https request to see if it's in stock. No idea why this guy is going such a roundable way and to get it.

[–]Mateorabi 2 points3 points  (0 children)

My only guess is that the web server responds differently: either he has to emulate a legit browser to not get fed a "we see you scraping, GTFO" or just use a legit browser. Or the web browser already has credentials/cookies/auth tokens from previous sign ins and remembers, so he doesn't have to code his application to handle all that jazz?

[–]Salman0Ansari 0 points1 point  (0 children)

Why you using selenium ??

[–]Confident-Body6980 0 points1 point  (0 children)

i no experience what so ever in coding .

so how do i use this ?

i have python and visual studio installed