cisticola.scraper.rumble module
- class cisticola.scraper.rumble.RumbleScraper
Bases:
ScraperAn implementation of a Scraper for Rumble, using custom functions
- archive_files(result: ScraperResult) ScraperResult
Archive files corresponding to
archived_urldict keys, if the files have not previously been archived.- Parameters:
result (ScraperResult) – Previously scraped ScraperResult.
- Returns:
Same ScraperResult as
result, but with all URLs inarchived_urldict archived.- Return type:
- can_handle(channel)
Whether or not the scraper can scrape the specified channel.
- Parameters:
channel (Channel) – Channel to be scraped.
- Returns:
Trueif the scraper is capable of scrapingchannel,Falseif not.- Return type:
bool
- cookiefilename = 'cookiefile.txt'
- get_posts(channel: Channel, since: ScraperResult | None = None) Generator[ScraperResult, None, None]
Scrape all posts from the specified Channel.
- Parameters:
channel (Channel) – Channel to be scraped.
since (ScraperResult or None) – Most recently scraped ScraperResult from a previous scrape, or
Noneif scraper has not run before.
- Yields:
ScraperResult – Scraper result from a single post/comment from the specified Channel.
- get_profile(channel: Channel) RawChannelInfo
- url_to_key(url: str, content_type: str) str
Generate a unique identifier for media from a specified post.
- Parameters:
url (str) – URL of original post. e.g.
"https://twitter.com/bellingcat/status/1503397267675533313"content_type (str) – Content-Type of media. e.g.
"image/jpeg"
- Returns:
key – Unique identifier for the media file from a specified post based on the original post URL and the media’s Content-Type.
- Return type:
str
- cisticola.scraper.rumble.get_channel_profile(url)
- cisticola.scraper.rumble.get_channel_videos(url)
- cisticola.scraper.rumble.get_media_url(url)
- cisticola.scraper.rumble.process_video(video)