kevinzg / facebook-scraper

Scrape Facebook public pages without an API key
MIT License
2.29k stars 616 forks source link

ERROR: This video is only available for registered users. Use --username and --password or --netrc to provide account credentials. #467

Open shanghongjialaopo opened 2 years ago

shanghongjialaopo commented 2 years ago

I extract cookies from my browser after logging into Facebook with an extension like EditThisCookie (Chrome), But mistakes still occur: ERROR: This video is only available for registered users. Use --username and --password or --netrc to provide account credentials. /home/uu/project/news/virtualenv/lib/python3.6/site-packages/facebook_scraper/facebook_scraper.py:441: UserWarning: Facebook served mbasic/noscript content unexpectedly on https://m.facebook.com/page_content_list_view/more/?page_id=107823734079058&start_cursor=%7B%22timeline_cursor%22:%22AQHRT4pDRmu4WPK1y2ZIstsNHwrW2YjKWQBdWoNhXjqkyiePq2F0eevyekhAZf-Jpt21ttZyW-GLiieBNdtduHh2NstB6BoCYOMTtZVyLmnjLOyH9L7Mz3AZHcieEqUnsPPc%22,%22timeline_section_cursor%22:null,%22has_next_page%22:true%7D&num_to_fetch=4&surface_type=posts_tab f"Facebook served mbasic/noscript content unexpectedly on {response.url}"

shanghongjialaopo commented 2 years ago

I scraper like this: get_posts(src, cookies='facebook.cookies', page=3, youtube_dl=True)

neon-ninja commented 2 years ago

This error is coming from youtube_dl. What happens if you don't use youtube_dl?

shanghongjialaopo commented 2 years ago

The crawler script works when i remove the youtube_dl parameter. Thank you for your help,and i have a question, are you going to fix the error come from youtube_dl ?