[github] get full post

Post plugins and custom CSS snippets here
ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

[github] get full post

Postby ManuelW » 01 Feb 2015, 15:40

Hey there,

i forked the af_fullpost plugin and have rewritten some parts. And i use the readability module from fivefilters.org, wich works much better in my opinion.

What i have done:
1) the plugin gets the fullpost for ALL articles
2) there is a preference pane to set, wich pages are excluded from getting fullpost
3) the option list is much easier than in the original plugin, you don't need to write json, you write simply comma-separated
4) there is a option in pref. pane to enable/disable a info on the bottom of every article, if its processed by readability or excluded or failed.
5) some pages wrote there path to images ...img src="//url.com"... to handle http:// and https:// calls. This images can't be viewed on mobile apps, because they ant handle this links. So i have a simple function to rewrite //url... to http://url...

https://github.com/ManuelW77/ttrss_fullpost

regards
Manuel

alxctc
Bear Rating Trainee
Bear Rating Trainee
Posts: 3
Joined: 05 Feb 2015, 21:22

Re: [github] get full post

Postby alxctc » 05 Feb 2015, 21:29

Hi Manuel,

Thanks for update the "fullpost" plugin.

However, i got some problem that no effect after enable the plugin, and shown a error message in system log, as "Cannot redeclare class Readability".

Do you have any idea about the error?
I'm a basic user and don't know how to solve the technical problem.

Thanks in advance.

alx

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 05 Feb 2015, 22:00

Hm, do you have some more information on you log? Line number or something else?

Is there another readability plugin active on your ttrss?

macfly
Bear Rating Disaster
Bear Rating Disaster
Posts: 82
Joined: 27 Mar 2013, 23:07

Re: [github] get full post

Postby macfly » 05 Feb 2015, 22:50

Hi,

looks like german umlaute are broken.

I'm subscribed to
http://www.spiegel.de/schlagzeilen/index.rss

and after letting your plugin parse this feed, it looks like

Er�ffnungsfilme m�ssen nicht gut sein, sie m�ssen nur gute Laune machen. Das ist die goldene Regel f�rs Programmfeuerwerk aller gr��eren Filmfestivals, die bei den Berliner Filmfestspielen zuletzt supergut funktioniert hat. Im vergangenen Jahr n�mlich durfte der quietschvergn�gte Wes-Anderson-Film "Grand Budapest Hotel" die Berlinale er�ffnen, der Film machte die Gala-G�ste und fast alle Filmkritiker gl�cklich und ist in diesem Fr�hjahr sogar noch �berraschend gro� bei der Oscar-Verleihung am Start. Ein bunter Traumkracher f�r strenge Cineasten und die ganze vergn�gungss�chtige Berlinale-Familie.

every � is actually one of a äöüÄÖÜß

regards,
macfly.

alxctc
Bear Rating Trainee
Bear Rating Trainee
Posts: 3
Joined: 05 Feb 2015, 21:22

Re: [github] get full post

Postby alxctc » 06 Feb 2015, 09:59

Hi,

I've followed your suggestion, and disabled another readability plugin (for tigger individual entry to trim it by Readablity API.)
For your ref., the beforementioned full error message is " E_COMPILE_ERROR (64) plugins\af_fullpost\Readability.php:68 Cannot redeclare class Readability".

After that, the mentioned error gone, but other issues happen, error log as following :
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:44
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:29
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:28
E_ERROR (1) classes\db\mysqli.php:27 Maximum execution time of 30 seconds exceeded 14:27
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:26
E_ERROR (1) plugins\af_fullpost\Readability.php:533 Maximum execution time of 30 seconds exceeded 14:24
E_ERROR (1) classes\db\mysqli.php:27 Maximum execution time of 30 seconds exceeded 14:23
E_ERROR (1) classes\db\mysqli.php:27 Maximum execution time of 30 seconds exceeded 14:21
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:17
E_ERROR (1) plugins\af_fullpost\init.php:114 Allowed memory size of 134217728 bytes exhausted (tried to allocate 33554432 bytes) 13:28
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

I look forward to waiting for your further instruction.

Thx!

alx

User avatar
fox
^ me reading your posts ^
Posts: 6267
Joined: 27 Aug 2005, 22:53
Location: Saint-Petersburg, Russia
Contact:

Re: [github] get full post

Postby fox » 06 Feb 2015, 10:10

E_ERROR (1) plugins\af_fullpost\init.php:114 Allowed memory size of 134217728 bytes exhausted (tried to allocate 33554432 bytes) 13:28


whoa

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 06 Feb 2015, 18:21

macfly wrote:Hi,

looks like german umlaute are broken.

I'm subscribed to
http://www.spiegel.de/schlagzeilen/index.rss

regards,
macfly.

This problem should be fixed. Thanks to itohsnap ;)

Can you try it and give me a short feedback pls.

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 06 Feb 2015, 18:25

alxctc wrote:After that, the mentioned error gone, but other issues happen, error log as following :
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
E_ERROR (1) plugins\af_fullpost\init.php:110 Maximum execution time of 30 seconds exceeded 14:44
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

This comes from curl, when it is get the content from a webpage. Can you find out, on which page it happens? Maybe there is a really big element on the page.
Did you get other content or nothing?

alxctc
Bear Rating Trainee
Bear Rating Trainee
Posts: 3
Joined: 05 Feb 2015, 21:22

Re: [github] get full post

Postby alxctc » 06 Feb 2015, 22:08

Thanks Manuel for following up our cases, and revise your plugin instantly.

I've updated your newest version of "af_fullpost", and re-tested my feeds,
I found most of the feeds can be parsed by php_readability now, but took about 5-20s in to complete fetching a site,
and sometime need to double click the site title to refresh the feed again and get the full content.

After testing many sites and review the system log, I found the "execution time of 30 seconds exceeded" error is still present.

Previously, This one can't be fetched the full content, but now is alright :
http://www.scmp.com/rss/asia_world.xml

This one is still fail to be parsed, and this feed is in traditional chinese :
http://hk.news.yahoo.com/rss/news_hk_general_all.xml
- - - - - - - - - - - - - - - - - - - - - - - - Result of each feed's entry, and load for a long time.
Failed
Processed by Readability + 0 Replacements
- - - - - - - - - - - - - - - - - - - - - - - -

http://rss.appleactionews.com/rss.xml
- - - - - - - - - - - - - - - - - - - - - - - - Result (chinese site too)
Date : 7th Feb, 2015
Processed by Readability + 2 Replacements
- - - - - - - - - - - - - - - - - - - - - - - -

Almost all problem are related to asian language sites, and seems to be no problem if site is in english.

Anyway, your plugin is usable now. I'll disable the sites in perference or use the online full-content services for these cases.

Thanks once again !!! Have a nice day !!!

alx

afk_zzz
Bear Rating Trainee
Bear Rating Trainee
Posts: 3
Joined: 10 Feb 2015, 18:59

Re: [github] get full post

Postby afk_zzz » 10 Feb 2015, 19:19

Looks like excluding more than one feed from fetching somehow broken. Only the last typed feed being excluded (the one without comma in the end) and all others are successfully processed by readability.

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 10 Feb 2015, 19:27

afk_zzz wrote:Looks like excluding more than one feed from fetching somehow broken. Only the last typed feed being excluded (the one without comma in the end) and all others are successfully processed by readability.

really? i'll check this.

Update:
I updated the plugin. Can you give it a try and a little feedback to me.

afk_zzz
Bear Rating Trainee
Bear Rating Trainee
Posts: 3
Joined: 10 Feb 2015, 18:59

Re: [github] get full post

Postby afk_zzz » 11 Feb 2015, 17:40

Pulled update. Now even last typed feed successfully processed.

Update:
Wow. After some testing on fresh database I came to conclusion. If "Show processed by Readability info on article bottom" checked (af_fullpost_show_info true) all of the excluded feeds are processed. And if af_fullpost_show_info false all of the excluded feeds are skipped.

JustAMacUser
Bear Rating Overlord
Bear Rating Overlord
Posts: 371
Joined: 20 Aug 2013, 23:13

Re: [github] get full post

Postby JustAMacUser » 11 Feb 2015, 19:03

There's a variable typo on line 61.

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 11 Feb 2015, 19:09

Thank you all for your suggestions.

I found the variable typo with you hint and i found another very stupid thing. I shouldn't code at deep night :)

I'll have a little test for now an in round about 1h i upload the new Version on Github.

ManuelW
Bear Rating Trainee
Bear Rating Trainee
Posts: 10
Joined: 30 Apr 2013, 18:16

Re: [github] get full post

Postby ManuelW » 11 Feb 2015, 20:34

I updated the plugin on github yet. It should work now as it should :mrgreen:

I updated the Options for the textfield too. You can write websites down now

comma-separated:
site1, site2, site3

or new line separated:
site1
site2
site3

or mixed:
site1, site2, site3
site4, site5
site6, site7, site8


Return to “Themes and plugins”

Who is online

Users browsing this forum: No registered users and 2 guests

cron