FS#62625 - AUR atom generation doesn't pass w3c validator

Attached to Project: AUR web interface
Opened by Swift Geek (swiftgeek) - Monday, 13 May 2019, 22:02 GMT
Last edited by Lukas Fleischer (lfleischer) - Tuesday, 21 April 2020, 16:05 GMT
Task Type Bug Report
Category Backend
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version 4.7.0
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Example atom feed for yay package:
https://aur.archlinux.org/cgit/aur.git/atom/?h=yay

W3C Validator:
https://validator.w3.org/feed/check.cgi?url=https%3A%2F%2Faur.archlinux.org%2Fcgit%2Faur.git%2Fatom%2F%3Fh%3Dyay

Namely contains this error that prevents parsing the feed:
line 12, column 137: XML parsing error: <unknown>:12:137: not well-formed (invalid token)
... b1c3b38dc0b5bf07e1b0a62519b845ba497f20&h=yay'/>
This task depends upon

Closed by  Lukas Fleischer (lfleischer)
Tuesday, 21 April 2020, 16:05 GMT
Reason for closing:  Not a bug
Comment by Eli Schwartz (eschwartz) - Monday, 13 May 2019, 22:12 GMT
This comes from cgit, not aurweb itself. In our configuration, this is producing content such as:

<link rel='alternate' type='text/html' href='https://aur.archlinux.org/cgit/aur.git/commit/?id=d8b1c3b38dc0b5bf07e1b0a62519b845ba497f20&h=yay'/>

And the href contents have an unescaped & in there, which is probably not very good news... the thing is, the only way to find a commit in the aurweb cgit interface is with the GIT_NAMESPACE branch. Upstream cgit seems to, usually, just print the commit id= there, without referencing branches. I believe this should be raised as a cgit bug.

Loading...