Suggestions for how to delay a feed?

I subscribe to some Reddit RSS feeds in TT-RSS. I was wondering if there is any way to “delay” the display of that feed by some amount of time.

The reason I ask is that when a new post is submitted to Reddit, the post will pop up on my fresh feeds, but of course that post will not have very many comments, if any. What would be more useful to me would be if that post could somehow be delayed such that it appears in my fresh feeds the next day. At that point, when I click on it, there will be lots of comments to read.

I’m not afraid to attempt to make a plugin to do this, I just need a few pointers for how such a thing could be done, or whether such a thing is simply too difficult to do such that I should just forget about it.

Thanks!

that is technically a somewhat interesting problem, even though to me your goal of wanting to read more reddit comments seems like a weird kind of masochism. :slight_smile:

this could however be useful to, for example, filter out all posts deleted by mods.

I have 70-80 reddit feeds in my ttrss. I know the “problem”.
I mark interessting threads as “starred” and look after them after some time :slight_smile:

this tool helps to subscribe reddit feed based on up votes, so they definitely have more comments, compared to fresh feeds

this tool helps you to get feed based on thresholds

both can be selfhosted

proof of concept:

https://git.tt-rss.org/fox/ttrss-reddit-delay

e: update: this seems to be working.

my first impressions is that it is the best idea ever and changes ~everything~ at least for reddit feeds. thanks, op.

Oh wow, I certainly wasn’t expecting this! Thank you fox, I’m really excited to try it out.

Thank you as well teddokarrun for those two projects, I’ll take a look at those as well.

Sorry to bring this thread back to life, but would you consider creating a mysql version?

Thanks in advance

i’ll make a note but no promises.

Hi Fox. Thanks anyway. I appreciate it nonetheless.

https://dev.tt-rss.org/fox/ttrss-reddit-delay/commit/d44db02017748c30fc06a91de4c00060e3ee4e29

i didn’t fully test this, so poke me if something doesn’t work right.

Thanks Fox.

I tried to install the plugin but run into a couple of issues.

I used the plugin manager from my admin account and the installation seemed ok.
I logged out to log in with my normal account, I got the following error message:

Via phpmyadmin I changed the table to innodb and I was able to login. I also saw and activated the plugin in the preferences. Unfortunately it does not show up under feeds → plugins
Error log is now full of:
Error: E_USER_WARNING (512)
Filename: classes/db/migrations.php:182
Message:
Failed to load base schema for ttrss_migrations_plugin_reddit_delay: SQLSTATE[42000]: Syntax error or access violation: 1170 BLOB/TEXT column ‘link’ used in key specification without a key length

  1. classes/db/migrations.php(182): user_error(Failed to load base schema for ttrss_migrations_plugin_reddit_delay: SQLSTATE[42000]: Syntax error or access violation: 1170 BLOB/TEXT column ‘link’ used in key specification without a key length)
  2. plugins.local/reddit_delay/init.php(20): migrate()
  3. classes/pluginhost.php(509): init({PluginHost})
  4. classes/userhelper.php(137): load(af_catchup_old,cache_starred_images,note,prefs_effective_config,reddit_delay)
  5. backend.php(51): load_user_plugins()

Remote IP: xx.xx.xxx.xxx
Request URI: /rss/backend.php?op=pref-system
User agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:101.0) Gecko/20100101 Firefox/101.0

Hope it helps.

P.S.: server info:
PHP 8.0
MySQL Version: 10.3.34-MariaDB-log-cll-lve

ok nevermind the (deleted post) above for the time being, i’ve switched my docker-compose setup to mariadb 10.3.34 and i’m seeing the same issue (it’s about the index on the column, not the column definition itself).

https://dev.tt-rss.org/fox/ttrss-reddit-delay/commit/24256c75cb31991058f88b06b98881ca2454619a

still i have no idea why would the table be created as MyISAM.

p.s. make sure you drop these two tables before retrying:

| ttrss_migrations_plugin_reddit_delay |
| ttrss_plugin_reddit_delay_cache      |

Now seems to be working :slight_smile:
I already updated a couple of feeds from reddit and ttrss_plugin_reddit_delay_cache is being populated.
ttrss_error_log so far does not contain anything new.
If somethig strange happens in the future, I will report it here.
Thanks a lot. Really.

P.S.: I know I am pushing my luck, but you seem to be in a “mysql-friendly mode” :innocent:… Is this still out of question?

4 posts were merged into an existing topic: [Plugin suggestion] Similar articles as read, but for MySQL