pearlxcore / Shopee-Autobuy-Bot

Automation program to assist users with purchasing products on the Shopee website.
55 stars 30 forks source link

Loading Issue after countdown finish #32

Open dualsh0ck opened 8 months ago

dualsh0ck commented 8 months ago

sbot

[12:29:50] Countdown started..
[12:30:55] Product page loaded.
[12:31:00] Current element :  ()
An error occurred on line    at OpenQA.Selenium.WebDriver.UnpackAndThrowOnError(Response errorResponse, String commandToExecute)
   at OpenQA.Selenium.WebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
   at OpenQA.Selenium.WebDriver.FindElement(String mechanism, String value)
   at OpenQA.Selenium.By.<.ctor>b__11_0(ISearchContext context)
   at OpenQA.Selenium.By.FindElement(ISearchContext context)
   at OpenQA.Selenium.WebDriver.FindElement(By by)
   at Shopee_Autobuy_Bot.SeleniumService.GetElement(By locator)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable()
   at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): no such element: Unable to locate element: {"method":"xpath","selector":"//button[contains(@class, 'btn btn-solid-primary btn--l') and contains(text(), 'buy now')]"}
  (Session info: chrome=119.0.6045.106)
[12:31:00] Product page loaded.
[12:31:06] Current element :  ()
An error occurred on line    at OpenQA.Selenium.WebDriver.UnpackAndThrowOnError(Response errorResponse, String commandToExecute)
   at OpenQA.Selenium.WebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
   at OpenQA.Selenium.WebDriver.FindElement(String mechanism, String value)
   at OpenQA.Selenium.By.<.ctor>b__11_0(ISearchContext context)
   at OpenQA.Selenium.By.FindElement(ISearchContext context)
   at OpenQA.Selenium.WebDriver.FindElement(By by)
   at Shopee_Autobuy_Bot.SeleniumService.GetElement(By locator)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable()
   at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): no such element: Unable to locate element: {"method":"xpath","selector":"//button[contains(@class, 'btn btn-solid-primary btn--l') and contains(text(), 'buy now')]"}
  (Session info: chrome=119.0.6045.106)
[12:31:06] Product page loaded.
[12:31:11] Current element :  ()
An error occurred on line    at OpenQA.Selenium.WebDriver.UnpackAndThrowOnError(Response errorResponse, String commandToExecute)
   at OpenQA.Selenium.WebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
   at OpenQA.Selenium.WebDriver.FindElement(String mechanism, String value)
   at OpenQA.Selenium.By.<.ctor>b__11_0(ISearchContext context)
   at OpenQA.Selenium.By.FindElement(ISearchContext context)
   at OpenQA.Selenium.WebDriver.FindElement(By by)
   at Shopee_Autobuy_Bot.SeleniumService.GetElement(By locator)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable()
   at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode)
   at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): no such element: Unable to locate element: {"method":"xpath","selector":"//button[contains(@class, 'btn btn-solid-primary btn--l') and contains(text(), 'buy now')]"}
  (Session info: chrome=119.0.6045.106)
[12:31:11] Product page loaded.
[12:31:17] Job aborted.

Shopee page seems like having loading issue after countdown finish.

Btw, truly appreciate this tool.

Thanks in advance!

farisz14 commented 8 months ago

Screenshot_85 happen to me to but my logs looks like this [12:00:31] Countdown started.. [12:01:00] Product page loaded. [12:01:00] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:00] Product page loaded. [12:01:00] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:00] Product page loaded. [12:01:00] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:00] Product page loaded. [12:01:00] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:01] Product page loaded. [12:01:01] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:01] Product page loaded. [12:01:01] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:01] Product page loaded. [12:01:01] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:01] Product page loaded. [12:01:01] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:01] Product page loaded. [12:01:01] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:02] Product page loaded. [12:01:02] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:03] Product page loaded. [12:01:03] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:03] Product page loaded. [12:01:03] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:03] Product page loaded. [12:01:03] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:03] Product page loaded. [12:01:03] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:03] Product page loaded. [12:01:03] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:04] Product page loaded. [12:01:04] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:04] Product page loaded. [12:01:04] Current element : () An error occurred on line at Shopee_Autobuy_Bot.Services.AutoBuyService.IsProductAvailable() at Shopee_Autobuy_Bot.Services.AutoBuyService.BuyProduct(String buyMode) at Shopee_Autobuy_Bot.Services.AutoBuyService.ProductPage(String buyMode): Object reference not set to an instance of an object. [12:01:05] Job aborted.

dualsh0ck commented 8 months ago

after multiple try and error, I can conclude that if I'm using option with "Product Link", it will reproduce above page error.

But, there is a time when it works. Still trying to replicate.

pearlxcore commented 8 months ago

That is Shopee anti bot feature I guess. Some reported bot user will counter the error on ‘out of stock’ item.

Not sure how Shopee detect bot user. Could be shadow ip ban or too many page request.