lwindolf / liferea

Liferea (Linux Feed Reader), a news reader for GTK/GNOME
https://lzone.de/liferea
GNU General Public License v2.0
817 stars 130 forks source link

Problematic behavior with the latest commit(s) #1259

Closed stefanos82 closed 1 year ago

stefanos82 commented 1 year ago

After compiling the latest commit I have opened liferea and could see it attempted to pull the latest feed updates but without success.

I press Ctrl+U to update all my feeds, only to get a red thumbnail on the left side of each feed, indicating a problem fetching the available updates.

I rolled back to b63def78 and everything works as expected.

lwindolf commented 1 year ago

@stefanos82 Can you please paste some example lines from a run with --debug-net?

stefanos82 commented 1 year ago

Responses are correct HTTP/2 200 OK, but what caught my attention is the following line that was blended in the debug output: sys:1: Warning: g_atomic_ref_count_dec: assertion 'old_value > 0' failed

stefanos82 commented 1 year ago

I have tried liferea --debug-html and generated nested errors without logical sense and the output in $HOME/.cache/liferea/output.html contained only a single feed URL with info; the rest were ignored for some reason.

Running liferea --debug-parsing I get the following output:

$ liferea --debug-parsing
14:05:30 PARSING: Registering node source type Static Feed List
14:05:30 PARSING: Registering node source type Dummy Feed List Source
14:05:30 PARSING: Registering node source type Planet, BlogRoll, OPML
14:05:30 PARSING: Registering node source type Google Reader API
14:05:30 PARSING: Registering node source type Reedah
14:05:30 PARSING: Registering node source type Tiny Tiny RSS
14:05:30 PARSING: Registering node source type TheOldReader
14:05:30 PARSING: Registering node source type Miniflux
14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:30 PARSING: SAX parser error : xmlParseEntityRef: no name

sys:1: Warning: g_atomic_ref_count_dec: assertion 'old_value > 0' failed
14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name

14:05:32 PARSING: SAX parser error : xmlParseEntityRef: no name
sunwire commented 1 year ago

Same problem here, after start everything works fine, but if I update the feed and feed returns error 304 I got an error

Problematic feed

15:40:09 NET    : downloading http://www.blogplay.eu/feed/
> GET /feed/ HTTP/1.1
> Soup-Debug-Timestamp: 1688046009
> Soup-Debug: SoupSession 1 (0x55ded70ec800), SoupMessage 201 (0x55ded7b78bd0), GSocket 135 (0x55ded8a2bf80)
> If-Modified-Since: Thu, 18 May 2023 19:43:40 GMT
> If-None-Match: "a5a4bfca09c36a2dbd35afd8b598cde9"
> Accept: application/atom+xml,application/xml;q=0.9,text/xml;q=0.8,*/*;q=0.7
> DNT: 1
> Accept-Encoding: gzip, deflate
> User-Agent: Liferea/1.15.0 (Android 12; Mobile; https://lzone.de/liferea/) AppleWebKit (KHTML, like Gecko)
> Connection: Keep-Alive
> Host: www.blogplay.eu
> A-IM: feed

< HTTP/1.1 304 Not Modified
< Soup-Debug-Timestamp: 1688046010
< Soup-Debug: SoupMessage 201 (0x55ded7b78bd0)
< Date: Thu, 29 Jun 2023 13:40:09 GMT
< Server: Apache
< X-Content-Type-Options: nosniff
< Upgrade: h2,h2c
< Connection: Upgrade, Keep-Alive
< Last-Modified: Thu, 18 May 2023 19:43:40 GMT
< ETag: "a5a4bfca09c36a2dbd35afd8b598cde9"
< Keep-Alive: timeout=5, max=100
< Strict-Transport-Security: max-age=63072000; preload

15:40:10 NET    : download status code: 304
15:40:10 NET    : source after download: >>>http://www.blogplay.eu/feed/<<<
15:40:10 NET    : 0 bytes downloaded

Working feed

15:45:54 NET    : downloading https://testhub.pl/feed/
> GET /feed/ HTTP/2
> Soup-Debug-Timestamp: 1688046354
> Soup-Debug: SoupSession 1 (0x55ded70ec800), SoupMessage 202 (0x55ded8bc7040), GSocket 136 (0x55ded7c237c0)
> Accept: application/atom+xml,application/xml;q=0.9,text/xml;q=0.8,*/*;q=0.7
> DNT: 1
> Accept-Encoding: gzip, deflate, br
> User-Agent: Liferea/1.15.0 (Android 12; Mobile; https://lzone.de/liferea/) AppleWebKit (KHTML, like Gecko)

< HTTP/2 200 OK
< Soup-Debug-Timestamp: 1688046354
< Soup-Debug: SoupMessage 202 (0x55ded8bc7040)
< Vary: Accept-Encoding,User-Agent
< Content-Encoding: gzip
< Content-Length: 28802
< Content-Type: text/xml;charset=UTF-8
< Date: Thu, 29 Jun 2023 13:45:54 GMT
< Server: Apache/2
< x-powered-by: PHP/7.4.32

15:45:54 NET    : download status code: 200
15:45:54 NET    : source after download: >>>https://testhub.pl/feed/<<<
15:45:54 NET    : 116137 bytes downloaded

For me it looks like liferea try to parse feed even when the downloaded size is 0

stefanos82 commented 1 year ago

Does liferea --debug-html report parsing errors for HTML tags on your side as well?

sunwire commented 1 year ago

Does liferea --debug-html report parsing errors for HTML tags on your side as well?

Yes. but in the previous version these errors were also present

HTML parser error : Tag rss invalid
    <rss version="2.0">
                      ^
HTML parser error : Tag channel invalid
     <channel>
             ^
HTML parser error : Unexpected end tag : link
        <link>https://www.phoronix.com/</link>
                                              ^
HTML parser error : Tag description invalid
        <description>Linux Hardware Reviews, Benchmarks &amp; Open-Source News</descri
                    ^
HTML parser error : Tag language invalid
        <language>en-us</language>
                 ^
stefanos82 commented 1 year ago

That's interesting; I had the impression the issue was introduced with the latest commits.

Let me checkout to b63def7 and try again.

stefanos82 commented 1 year ago

Indeed the HTML parsing issue exists in 1.15.0 too...weird!

lwindolf commented 1 year ago

@stefanos82 @sunwire thank you for the traces will have a look at the issue!

lwindolf commented 1 year ago

Fix provided by @rich-coe in #1286 Will be released with 1.15.1 soon.