Bug 236397

Summary: www/newsboat: Bad display from an atom source
Product: Ports & Packages Reporter: moebius444
Component: Individual Port(s)Assignee: Marko Turk <mt-bugs>
Status: Closed FIXED    
Severity: Affects Only Me CC: arved, eual.jp, mt-bugs, ygy
Priority: --- Keywords: needs-qa
Version: LatestFlags: bugzilla: maintainer-feedback? (mt-bugs)
Hardware: Any   
OS: Any   
Bug Depends on: 250163    
Bug Blocks:    
Attachments:
Description Flags
Proposition for utils::clean_nonprintable_characters() none

Description moebius444 2019-03-08 19:47:29 UTC
Hi,

Using www/newsboat 2.14.1_2 from ports.
Some texts do not appear correctly from the following source

https://rss.evangelizo.org/v2/evangelizo_rss-fr.xml

Especially for the sections "Evangile...".
Where could the problem come from ?
Try using without 'config' file.
A config file with 'pager less' (or most) resolves the problem.

See : https://groups.google.com/forum/#!topic/newsboat/IhbsCs_NtFI

Best regards.

-----------------
Olivier
Comment 1 moebius444 2019-03-19 19:23:30 UTC
Another source with the same problem:

http://www.rfi.fr/emission/autour-question/podcast

Best regards

------------------
Olivier
Comment 2 Tilman Keskinoz freebsd_committer freebsd_triage 2019-03-19 21:12:54 UTC
Hi, to narrow it down, have you tried to save the text and display it in another ncurses application like e.g. nano?

If you are on STABLE or CURRENT, have you tried using C.UTF-8 as LANG?

I am not even sure, if this really counts as a bug, as you are trying to display UTF-8 text on a locale that does not support UTF-8 (but I am not a locale expert).
Comment 3 moebius444 2019-03-24 05:36:54 UTC
Created attachment 203095 [details]
Proposition for utils::clean_nonprintable_characters()

I found that the remplacement char \uFFFD does not display correctly.
In utils::clean_nonprintable_characters(), I force \u00A0 (NO-BREAK SPACE) remplacement by \u0020.

In stfl, and via iconv, wstr2str utils::clean_nonprintable_curiously replaces space with \u00A0 (for example before ':'),  which does not suit my case.

Best regards.

----------------------
Olivier
Comment 4 Marko Turk 2019-04-12 19:50:27 UTC
(In reply to moebius444 from comment #3)

I don't feel comfortable with adding this patch to ports. We might break some other stuff.

Since the issue is not seen on e.g. Linux, the problem could be in the way we build stfl.

The only other application using stfl in ports is kdbx-viewer, I'll try to reproduce the issue there and see how it behaves with these characters you mentioned.

Have you been able to get this characters to display properly by chaning the locale that you use?

BR/Marko
Comment 5 moebius444 2019-04-25 16:59:07 UTC
I try to change locale with LANG=C.UTF-8 and for the other LC_ccc I export en_US.UTF-8. The result is the same : the text does not display correctly.

---------------
Olivier
Comment 6 Marko Turk 2020-10-06 17:54:49 UTC
Hi,

can you see if you have the same problem if you start newsboat like this?
env LANG= newsboat

Regards,
Marko
Comment 7 Marko Turk 2020-10-07 06:39:53 UTC
The bug seems to be fixed on -CURRENT.

Can you try -CURRENT in a VM or somewhere and see if it fixes the issues for you also?

Regards,
Marko
Comment 8 moebius444 2020-12-12 17:52:05 UTC
(In reply to Marko Turk from comment #7)

Yes, in FreeBSD 12.2, the problem in newsboat 2.20.1 does not appear anymore.
Note : I recompile newsboat from ports without my patch.

Everything is correct now.
You can close the bug 236397.

Regards,
Olivier
Comment 9 Kubilay Kocak freebsd_committer freebsd_triage 2020-12-28 00:56:45 UTC
(In reply to moebius444 from comment #8)

Issue should be resolved for all supported (non-EoL) FreeBSD versions.

What are:

1) The root cause(s) involved
2) The remaining affected FreeBSD versions
3) The steps to reproduce on those (2) versions
Comment 10 Guangyuan Yang freebsd_committer freebsd_triage 2020-12-28 07:07:48 UTC
Assign to maintainer as requested.
Comment 11 Marko Turk 2020-12-28 07:59:24 UTC
(In reply to Kubilay Kocak from comment #9)
Hi Kubilay,

please see https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=250163

It's fixed in all versions except 11.x. The 250163 was closed and I assume the fix will not be ported to 11.x branch so I'll close this newsboat PR also.

Regards,
Marko
Comment 12 Marko Turk 2021-07-03 10:16:08 UTC
Closing this since it works okay on 12-RELEASE.