I'm using Selenium with chrome driver to scrape facebook, insta and reddit. Everything's working perfectly on local server. However, when I deploy on AWS EC2 (using Elastic Beanstalk) it does not work properly. Reddit is being scraped without any problem but for facebook and instagram it throws: selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element.
Searching for the solution to this problem, I came to know that this error occurs when the page is not yet loaded completely and we try to look for elements of the page. (Note: this issue did not occur on my local machine.)
To resolve this problem I added waiting delay so that the page can load completely. I tried giving delay of up to 60 seconds but it is still failing to load the page. Note: this issue does not occur on page 1 e.g. on facebook: login goes successful, search query goes successful and the results are shown and then when a try is made to load a specific post error occurs (page fails to load) similarly on Instagram: login is successful but when a try is made to access the search box element error occurs.
No idea why the pages are not being loaded when accessing through AWS server but working fine on my local server. The fact that reddit is being scraped confirms that the issue is not with selenium or other environmental dependencies...
If someone has any idea about this problem, please share. Thanks.
Related
I followed the AWS guide on how to set up Drupal on AWS, everything installed fine and the command line is working well.
It's the basic site and set up with nothing custom.
I can access the site fine following the guide but when I try to log in I get the below error:
To log in to this site, your browser must accept cookies from the domain ec2-XXX
After Googling, it mentions a patch could fix it but I can't seem to get it working.
Any help is appreciated! Thanks
Turns out I just needed to Open on Safari - I was already logged into the site!!
Must be an actual Chrome cookie issue, clean up those crumbs people!
Leaving in case someone needs the help....
I have a website with published posts, like a blog, and each post page have a Facebook like button, provided by their official documentation page. When testing, on my local environment and on my test server it works fine, but in production the buttons don't show up. In some computers they popup, but in most cases it doesn't. The iframe is generated, but blank. I'll list what I already tried:
Disabled adblock
Cleaned cache
Tried on another browsers
Tried a different DNS server (the DNS that worked on one machine didn't work on another)
Looked for errors or any hint on chrome developer console, even inside the requests made to facebook
Checked the allow-origin configs on the apache server and tried different setups
Tried both method of embedding, through iframe and script
When we are trying to add our website URLs
https://taiwan.kisan.app and https://taiwan.kisan.in
in the Facebook advertisement.
We are getting the following error.
Invalid link URL Provided: The link URL https://taiwan.kisan.app used
in the Ad is invalid. Please use a different URL and try again.
(#2490193)
We are not able to understand what is causing this error
as our site has SSL and it can be browsed from the browser
without error.
The site is hosted on Apache, AWS EC2 instance and there is a load balancer before EC2.
How can we fix this?
You can use an URL shortener service like bit.ly to quickly resolve this. You can also have custom URL tag if you want. See Bit.ly Sign Up
You might try running your website through the Facebook Debugger:
https://developers.facebook.com/tools/debug/
This tool was built to help to identify any errors that Facebook is reading from your website, and help provide information on what needs to be fixed to unblock your link.
From there, you can get help from your developers team or from the Facebook Developers team to make your website compliant and help our systems detect it as safe. Click the link below and select "Get Started" to open a support ticket with the Facebook Developers team (this option may not be available for all websites):
https://developers.facebook.com/tools-and-support/
The error may also occur because the URL is already being used by another Facebook page –possibly a forgotten page, previous page, or an unofficial, unverified page that was created by someone else
I working on a web brower in C++ using Windows Form for my final exam in high school.My problem is that i need manualy to accept Security Alerts and Script Error everytime i try to enter page on internet with my browser.
I tried web browser propertie "Script Error Suppresed" but that just hide error and give me other page to aprove that I'm sure that i want to see that page.
I expect that web browser automaticly allow certificates and allow to coninue even i have script errors.
I'm using Facebook Marketing API. Starting from last week I get an error message when I try to send a request from my local machine.
The exact error I'm getting on my screen is the following:
RequestException in RequestException.php line 154:
(#3) App must be on whitelist
When I send a request from production server, the app is working fine and creates a campaign.
I went through all the possible settings in the app, to see if I'm able to configure it from there, but seems like the app is configured well.
App is also public:
This app is public and available to all users
Appreciate any help or tips!
App suddenly started working without making any changes to code or configuration. Must be an Facebook issue...
I had this issue when provide 'is_autobid' property to new campaign