Giter VIP home page Giter VIP logo

rss-chan's Introduction

A telegram RSS feed reader bot, made in python using feedparser.


About

A self-hosted telegram bot that dumps posts from a RSS feed to a telegram chat.

This project is inspired by BoKKeR's telegram bot and ayrat555's el_monitorro bot written in Rust.

Note: The previous version was a complete refactor of BoKKeR's code, which also addresses a couple of issues in his repo with many bug fixes and features of my own. They've been integrated with the current version. Head over to the changelog section for more.

Deploy

Instructions to deploy to Heroku or self-host resides in the wiki.

Usage

The bot uses a TITLE <-> URL mechanism so that the user doesn't have to mess with the feed URL every time, instead use a TITLE to perform a task.

Commands:
/help: To get the help message
/list: List your subscriptions
/get TITLE 10: Force fetch last n item(s)
/sub TITLE https://www.rss-url.com/feed: Subscribe to a RSS feed
/unsub TITLE: Removes the RSS subscription corresponding to it's title
/unsuball: Removes all subscriptions
/template TITLE TEMPLATE: Set a template to a specific RSS feed

Credits

Projects used in the making:

Others:

rss-chan's People

Contributors

hypnoticdo0g avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

rss-chan's Issues

[Bugfix] Alter RSS monitor algorithm to support quickly updating feed items

feed_count += 1

What if rss only provide 25 item .. and all of them are new ... if someone added delay 20 min for example and in those 20 min, a 25 new items added ... the while loop will not stop until maching last previous link and title .. and this will not happen bcz all items are new... index error will raised cz u trying to get feed with index 26 and the max item no. provided from this rss is 25.

[Feature Request] Display feeds based on a Template

Hey, thank you for this amazing project.

I would like to request 2 features here,

  1. Adding custom message to be sent with the entry in message.
  2. Selecting which entry should be sent for each feeds.
    Ex- /mirror entry.link or
    /mirror entry.enclosures[0]['href'] or
    /mirror entry['torrent_magneturi']

Since different sites gives magnet/download links in different entries it'd be helpful to select the ones we need.

deploy

Heroku deploy button isn't working its giving 404 error please look into it

YTS RSS Feed

Hi,

Since the YTS RSS feed always leads to main URL instead of direct torrent URL and breaks the auto mirroring, which codes should I edit to replace;

From this:
Influence (2020) [WEBRip] [720p] [YTS.MX]
https://yts.mx/movies/influence-2020

To this:
Influence (2020) [WEBRip] [720p] [YTS.MX]
https://yts.mx/torrent/download/E605F583298C3DAAC17B1B79E30DB3C4A8E99B8A

To test it out I'm thinking to change to this line to find out the output:

item_info +=f"<b>{rss_d.entries[item_num]['title']}</b>\n{rss_d.entries[item_num]['link']}\n\n"

And for final part to this line:

feed_info = f"{CUSTOM_MESSAGES}\n<b>{feed_titles[x]}</b>\n{feed_urls[x]}"

I found a workaround to this issue in another RSS Repo but not on yours.

Any feedback and help would be appreciated. Thank you!

Deploy with Railway

Could you please update the wiki and include instructions on how to deploy with Railway now that Heroku is no longer free?

Actual <content> posting.

Could you please add actual content posting? Take Twitter parsing by rss-bridge, for example. https://rss-bridge.ggc-project.de/?action=display&bridge=Twitter&context=By+username&u=elonmusk&norep=on&noretweet=on&nopinned=on&nopic=on&noimgscaling=on&format=Atom

As you can see, tweet text as well as attachments are stored in content, which is d.entries[0].content in feedparser. You can store images as links in Database instead of actually downloading them, and if you need to attach them - perform image downloading from links which are tied to post. This way, the database won't grow rapidly. rss-chan will turn into rss-mirrorchan!

Perhaps you could just add the ability of choosing Atom elements per each subscription.

help for fix

2021-08-29 16:52:21,043 - bot - INFO - Database Loaded.
2021-08-29T16:52:21.044265+00:00 app[search.1]: 2021-08-29 16:52:21,043 - telegram.utils.promise - ERROR - An uncaught error was raised while running the promise
2021-08-29T16:52:21.044266+00:00 app[search.1]: Traceback (most recent call last):
2021-08-29T16:52:21.044267+00:00 app[search.1]: File "/usr/local/lib/python3.7/site-packages/telegram/utils/promise.py", line 57, in run
2021-08-29T16:52:21.044267+00:00 app[search.1]: self._result = self.pooled_function(*self.args, **self.kwargs)
2021-08-29T16:52:21.044268+00:00 app[search.1]: File "/app/", line 144, in rss_load
2021-08-29T16:52:21.044268+00:00 app[search.1]: for row in postgres_load_all():
2021-08-29T16:52:21.044268+00:00 app[search.1]: TypeError: 'Promise' object is not iterable

I am getting this error.
bot responds to all commands but when I command / list, bot say no subscriptions even though I have saved feed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.