Page 3 of 4

Re: Scratching some itches of people who used and liked GRea

Posted: 16 Mar 2013, 01:18
by fox
Maybe delete everything archived (e.g. feed_id is null) before processing. With a warning.

Re: Scratching some itches of people who used and liked GRea

Posted: 16 Mar 2013, 01:49
by nic
btw, Fox, since we got your attention concerning published articles: I always patch my tt-rss instance to not purge articles with published=true. Could that feature become part of the main trunk (I could provide a pull request)?

Re: Scratching some itches of people who used and liked GRea

Posted: 16 Mar 2013, 10:42
by fox
This was discussed before and we settled on a small periodically-run script which would star published items as a workaround. I feel that published contents are still transient by definition just like the rest of news items, so it seems like a fair thing for people who want to archive them.

Here's a simple example that should be placed into tt-rss directory. It can be extended as necessary.

Code: Select all

#!/usr/bin/php
<?php
        set_include_path(get_include_path() . PATH_SEPARATOR .
                dirname(__FILE__) ."/include");

        include "config.php";
        include "include/db.php";

        $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME);

        if ($link) {
                db_query($link, "update ttrss_user_entries set marked = true WHERE published = true AND owner_uid = (SELECT id FROM ttrss_users WHERE login = 'YOURLOGIN')");

                db_close($link);
        }
?>

Re: Scratching some itches of people who used and liked GRea

Posted: 16 Mar 2013, 22:08
by nic
Thanks. I didn't see that, only the one where someone proposed the patch. But for me starred and published shouldn't be mixed. I'll continue patching.

Re: Scratching some itches of people who used and liked GRea

Posted: 20 Mar 2013, 15:09
by Andyt8
I don't know exactly how it work? I have here a .json file from Google Reader.

Also Tiny Tiny RSS 1.7.4 with added XML file from Google Reader. I have no python, so I see the php code above. How does that work? Do I need do run it one time must be the .json file in the same directory?

Please for help.

Re: Scratching some itches of people who used and liked GRea

Posted: 20 Mar 2013, 15:30
by nic
Did you read the README?

Every PC should have Python, so you should be able to generate the SQL on your local computer.

The PHP code above is about something else, which should be clear if you read the previous messages. But if you read anything, just read the README that I wrote and then ask a specific question.

Re: Scratching some itches of people who used and liked GRea

Posted: 20 Mar 2013, 15:35
by nic
The README (and the python script) are here: https://github.com/nhoening/gritttt-rss ... der-import

Re: Scratching some itches of people who used and liked GRea

Posted: 20 Mar 2013, 18:05
by Andyt8
Ok, big thanks. I thought Python needs to be on the Webserver. I was able to run the script and create the sql file. Also import to TT-RSS was successful.

Your link was really nice. It give me the last note to understand all. First time on github, I was confused und didn't found the correct way. Don't know why it was in that way, before I asked my question.

Re: Scratching some itches of people who used and liked GRea

Posted: 27 Mar 2013, 23:15
by krosseyed
I have used the import.py tool, and had one starred item before the import of about 2000 Google Reader starred/favorite articles.

The one starred item is missing from the starred section in TT-RSS, and I cannot add new starred items. However the import seems to be successful.

Is there a way to clean this up? Or will i have to trash and start over?

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 01:23
by nic
I haven't had this issue, so I'm not sure what's wrong in your installation. Specifically, how could inserting data in your database destroy functionality ("I cannot add new starred items")? Most likely, something with the dates or the sorting is messed up. That means, you probably have your old and the new starred items, but you can't see them.

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 01:34
by krosseyed
Nic, This is what I am visually seeing:

Before Import:
http://i.imgur.com/MwjwezW.png

After Import:
http://i.imgur.com/RspUUAK.png

After the GReader Starred item import, I can still search for new favorites from the individual feeds as a workaround. But I would like to have one spot for all my favorites/starred items.

Let me know if there is there any other information I can provide to help with troubleshooting. And thank you for your time!

Also, I can log in to phpMyAdmin and find the articles, they just dont show up under the /tt-rss site.

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 02:01
by nic
Not sure what to do with the screenshots tbh. But - now I do remember having a similar issue (it was a year ago that I did my import). Not sure if it was the same. And I can for the life of me not remember what I actually did about it. I think I fixed something in the import script back then, so that is probably not of help for you right now. A friend of mine also saw something with sorting (but not after importing, just after updating the tt-rss version). I can ask him what he did.

In the meantime, if I were you, I'd try to deduce what makes the imported articles different to the newer ones. I'd look in phpMyAdmin, starting with the date.

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 02:13
by krosseyed
Also, I am the least observant person in the world. I figured out where the imported items go, They ended up in my 'Archived articles' folder. That was an unexpected outcome, or I did not RTFM.

This still does not solve my problem of showing starred items from new feeds on the global starred items list under the /tt-rss site.

The only thing I see is the Archived articles that have been starred in the global starred articles list. The pictures are still relevant to the problem I suppose.

I have been reverse engineering this issue, and will do a trip report once something comes up.

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 02:38
by krosseyed
nic wrote:Most likely, something with the dates or the sorting is messed up. That means, you probably have your old and the new starred items, but you can't see them.


This is exactly what is happening, I have deducted that pretty confidently now.

Is there a fix for this?

Thank you again nic for taking the time, and fox for making such an awesome product!

Re: Scratching some itches of people who used and liked GRea

Posted: 28 Mar 2013, 12:39
by nic
So how do the dates differ? Or is it the sorting?

If it is the dates, maybe the timezone on your machine that runs tt-rss is off?