Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

get_posts returns nothing #1102

Open
beatrisu21 opened this issue May 2, 2024 · 15 comments
Open

get_posts returns nothing #1102

beatrisu21 opened this issue May 2, 2024 · 15 comments

Comments

@beatrisu21
Copy link

Func get_posts returns nothing

Here is my code (same as one on the main page of this repo):

from facebook_scraper import get_posts
for post in get_posts('nintendo', cookies="/Users/beatrisu/Desktop/twi/1.txt"):
print(post['text'][:50])

output:
(gg) beatrisu@Savelijs-MacBook-Air twi % /Users/beatrisu/Desktop/twi/gg/bin/pyth
on /Users/beatrisu/Desktop/twi/scrap.py
/Users/beatrisu/Desktop/twi/gg/lib/python3.9/site-packages/facebook_scraper/facebook_scraper.py:912: UserWarning: Facebook says 'Unsupported Browser'
warnings.warn(f"Facebook says 'Unsupported Browser'")

get_group_info and get_profile are working ok but with some warnings.

@jaimeelincoln
Copy link

Having the same issue suddenly today. Can't get something simple like the example code you're using to work either

@beatrisu21
Copy link
Author

Also I got my facebook account blocked. It asks my id now

@minhson1411
Copy link

I had the same issue, I think this tool is no longer usable

@aoiotoko
Copy link

aoiotoko commented May 9, 2024

I had the same issue, I think this tool is no longer usable

I agree.

@Defcon27
Copy link

Defcon27 commented May 16, 2024

I too faced the same issue

@DarkzAtom
Copy link

So, I guess, sadly, this tool isn't usable for now?

@YSHebron
Copy link

I'm also experiencing the same.

@frishtik
Copy link

oh shoot. figured out the entire configuration finally, just to bump into the same problem -- results ARE being returned, but the fields are just none (all but the username). Anyone got any way forward? I need specifically get_profile.

@ChillVibesMushroom
Copy link

I used this code it was written via ai maybe facebook scraper selenium will help but what happened to dude yup

from facebook_scraper import get_posts

Initialize a list to store the first two posts

first_two_posts = []

Iterate over the posts and append the first two to the list

for post in get_posts('BigQuax', cookies="exported-cookies.json",pages=2):
first_two_posts.append(post)

Print the first two posts

for post in first_two_posts:
print(post)

@MadsMMP
Copy link

MadsMMP commented Jun 11, 2024

Having the same issue suddenly.

@AbdElrahmanMostafaRifaat1432

has anyone reached any solution or found a good library to scrabe facebook other than this library I really need any solution for my project

@moda20
Copy link

moda20 commented Jun 12, 2024

@AbdElrahmanMostafaRifaat1432 yeah, i forked this repo and it's working correctly here : https://github.com/moda20/facebook-scraper

i also forked a second repo that scrapes fb without logins, this one does less but is good enough : https://github.com/moda20/facebook_page_scraper

Note: these repos are for personal use and will certainally lead to rate limiting and banning your account even is you use them too much

@MadsMMP
Copy link

MadsMMP commented Jun 12, 2024

@AbdElrahmanMostafaRifaat1432 yeah, i forked this repo and it's working correctly here : https://github.com/moda20/facebook-scraper

i also forked a second repo that scrapes fb without tokens, this one does less but good enough : https://github.com/moda20/facebook_page_scraper

Note: these repos are for personal use and will certainally lead to rate limiting and banning your account even is you use them too much

Thanks, i will need to pull like once or twice a week will this be possible with this repo?

@moda20
Copy link

moda20 commented Jun 12, 2024

@MadsMMP yes, it should suffice for that but don't pull more than a hundred at a time, you will get blocked by fb for sure

@AbdElrahmanMostafaRifaat1432
Copy link

AbdElrahmanMostafaRifaat1432 commented Jun 12, 2024

@moda20
can you explain how to control that using parameters please
or which parameters to use to make sure I don't exceed 100

because I see alot of parameters that I cannot understand like pages and posts per pages

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests