UTF-8 is not working in Pagure #13064

Open
opened 2026-01-20 15:52:39 +00:00 by jskarvad · 7 comments

Describe what you would like us to do:

UTF-8 doesn't work in Pagure, e.g. check:
https://src.fedoraproject.org/tests/exim/blob/main/f/main.fmf

There is written:
Jaroslav Škarvada

Or even the RAW:
https://src.fedoraproject.org/tests/exim/raw/main/f/main.fmf
There is:
Jaroslav Å karvada

It should be:
Jaroslav Škarvada

I tried Firefox and Chrome. The file is downloaded OK, so it's probably bad encoding headers.

The 'Š' in UTF-8 is coded as 0xC5 0xA0, the local file:

$ cat main.fmf 
# QE owner
contact: Jaroslav Škarvada <jskarvad@redhat.com>
component: exim

$ file main.fmf 
main.fmf: Unicode text, UTF-8 text

$ hexdump -C ./main.fmf 
00000000  23 20 51 45 20 6f 77 6e  65 72 0a 63 6f 6e 74 61  |# QE owner.conta|
00000010  63 74 3a 20 4a 61 72 6f  73 6c 61 76 20 c5 a0 6b  |ct: Jaroslav ..k|
00000020  61 72 76 61 64 61 20 3c  6a 73 6b 61 72 76 61 64  |arvada <jskarvad|
00000030  40 72 65 64 68 61 74 2e  63 6f 6d 3e 0a 63 6f 6d  |@redhat.com>.com|
00000040  70 6f 6e 65 6e 74 3a 20  65 78 69 6d 0a           |ponent: exim.|

When do you need this to be done by?

No deadline, nice to have.

# Describe what you would like us to do: UTF-8 doesn't work in Pagure, e.g. check: https://src.fedoraproject.org/tests/exim/blob/main/f/main.fmf There is written: Jaroslav ┼ákarvada Or even the RAW: https://src.fedoraproject.org/tests/exim/raw/main/f/main.fmf There is: Jaroslav Å karvada It should be: Jaroslav Škarvada I tried Firefox and Chrome. The file is downloaded OK, so it's probably bad encoding headers. The 'Š' in UTF-8 is coded as 0xC5 0xA0, the local file: ``` $ cat main.fmf # QE owner contact: Jaroslav Škarvada <jskarvad@redhat.com> component: exim $ file main.fmf main.fmf: Unicode text, UTF-8 text $ hexdump -C ./main.fmf 00000000 23 20 51 45 20 6f 77 6e 65 72 0a 63 6f 6e 74 61 |# QE owner.conta| 00000010 63 74 3a 20 4a 61 72 6f 73 6c 61 76 20 c5 a0 6b |ct: Jaroslav ..k| 00000020 61 72 76 61 64 61 20 3c 6a 73 6b 61 72 76 61 64 |arvada <jskarvad| 00000030 40 72 65 64 68 61 74 2e 63 6f 6d 3e 0a 63 6f 6d |@redhat.com>.com| 00000040 70 6f 6e 65 6e 74 3a 20 65 78 69 6d 0a |ponent: exim.| ``` ---- # When do you need this to be done by? No deadline, nice to have. ----
$ curl -If https://src.fedoraproject.org/tests/exim/raw/main/f/main.fmf | grep -i content-type:
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0    77    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
content-type: text/plain; charset=IBM852

text/plain is okay, I am not sure where does the IBM852 come from.

$ curl -sfI https://src.fedoraproject.org/tests/exim/raw/main/f/LICENSE | grep -i content-type:
content-type: text/plain; charset=ASCII

$ curl -sfI https://src.fedoraproject.org/tests/exim/raw/main/f/README.md | grep -i content-type:
content-type: text/markdown; charset=ASCII
``` $ curl -If https://src.fedoraproject.org/tests/exim/raw/main/f/main.fmf | grep -i content-type: % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 77 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 content-type: text/plain; charset=IBM852 ``` text/plain is okay, I am not sure where does the IBM852 come from. ``` $ curl -sfI https://src.fedoraproject.org/tests/exim/raw/main/f/LICENSE | grep -i content-type: content-type: text/plain; charset=ASCII $ curl -sfI https://src.fedoraproject.org/tests/exim/raw/main/f/README.md | grep -i content-type: content-type: text/markdown; charset=ASCII ```

I think everywhere not specifc charset is needed otherwise, UTF-8 should be default in 2026

I think everywhere not specifc charset is needed otherwise, UTF-8 should be default in 2026
Member

Metadata Update from @james:

  • Issue priority set to: Waiting on Assignee (was: Needs Review)
  • Issue tagged with: low-gain, low-trouble
**Metadata Update from @james**: - Issue priority set to: Waiting on Assignee (was: Needs Review) - Issue tagged with: low-gain, low-trouble
Owner

Is this something we can change in infra or is this issue on pagure?

Is this something we can change in infra or is this issue on pagure?
Owner

Does it happen on pagure.io as well? (or stg.pagure.io )

They are using the same packages/os... but deployed differently.

Does it happen on pagure.io as well? (or stg.pagure.io ) They are using the same packages/os... but deployed differently.
Owner

I tested it out today on pagure.io by adding Czech letters to my fork and it looks OK.

curl -If https://pagure.io/fork/zlopez/fedora-infra/ansible/blob/main/f/README.md | grep -i "content-type:"                                                                            % Total    % Received % Xferd  Average Speed  Time    Time    Time   Current
                                 Dload  Upload  Total   Spent   Left   Speed
  0      0   0      0   0      0      0      0                              0
content-type: text/html; charset=utf-8

So it seems something is wrong just on src.fp.o.

I tested it out today on pagure.io by adding Czech letters to my fork and it looks OK. ``` curl -If https://pagure.io/fork/zlopez/fedora-infra/ansible/blob/main/f/README.md | grep -i "content-type:" % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 0 content-type: text/html; charset=utf-8 ``` So it seems something is wrong just on src.fp.o.
Owner

So, we should perhaps look at the config on pagure01 vs pkgs01 and see if we can see something ?
or I suppose it could be in the proxy layer, but thats should mostly just be passing requests back and forth.

So, we should perhaps look at the config on pagure01 vs pkgs01 and see if we can see something ? or I suppose it could be in the proxy layer, but thats should mostly just be passing requests back and forth.
Sign in to join this conversation.
No milestone
No project
No assignees
5 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
infra/tickets#13064
No description provided.