| Summary: | "Long description" link of many ports returns error | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Documentation | Reporter: | graham | ||||
| Component: | Website | Assignee: | Chris Rees <crees> | ||||
| Status: | Closed FIXED | ||||||
| Severity: | Affects Only Me | CC: | allanjude, andipersti, bjk, crees, joeb1, linimon, portmgr, sd | ||||
| Priority: | --- | ||||||
| Version: | Latest | ||||||
| Hardware: | Any | ||||||
| OS: | Any | ||||||
| URL: | https://svnweb.freebsd.org/doc/head/en_US.ISO8859-1/htdocs/ports/portindex | ||||||
| Attachments: |
|
||||||
|
Description
graham
2016-05-03 02:49:20 UTC
There are no files other than the Makefile for this port. I.e., pkg-descr is missing under ports/wireshark-qt5. Looks like a port issue. I don't know if it's a ports issue or a website issue, but there are lots of ports that don't have a pkg-descr. They will all have this problem. Below are the first 20 or so I found. So, either all ports should have this file, or the web site shouldn't show the link for those that don't. math/fpc-fftw math/fpc-gmp math/php70-bcmath math/php70-gmp math/fpc-numlib math/arpack-ng-mpich math/xlapack math/php56-bcmath math/php56-gmp math/ploticus-nox11 math/spooles-mpich math/mumps-mpich math/fftw-float math/fftw3-float math/fftw3-long math/fftw3-quad math/php55-bcmath math/php55-gmp textproc/php55-pspell textproc/php55-wddx textproc/php55-xmlreader textproc/php55-xsl textproc/php56-pspell textproc/php56-wddx textproc/php56-xmlreader textproc/php56-xsl textproc/qt4-xmlpatterns textproc/qt5-xmlpatterns Adding portmgr to cc to opine on official ports policy. All ports have a pkg-descr file, but it's not always in the port's directory: mat@aragorn.in:/home/mat/work/freebsd/ports/net/wireshark-qt5 $ make -V DESCR /home/mat/work/freebsd/ports/net/wireshark-qt5/../wireshark/pkg-descr Whatever's generating that link gets is wrong. The script that generates the link is portindex (see URL), which I submitted a patch for in 206709. The pkg-descr field is derived from INDEX. Looking at the current links on the website, I no longer see this problem. Can the submitter confirm this? I found same problem in under 1 minute just clicking on any "long description". Your fix is not working in all cases. https://svnweb.freebsd.org/ports/head/textproc/go.text/pkg-descr?revision=HEAD?revision=HEAD https://svnweb.freebsd.org/ports/head/math/php70-gmp/pkg-descr?revision=HEAD Maybe the current version of what the website is reading needs to be rebuilt to remove all the bad url's pointing to the port's long description text file. IIRC, we get a full rebuild every 6 hours, and an incremental rebuild ever 10 minutes. (In reply to joeb1 from comment #6) The first of the two URLs that joeb1 lists has two "?revision=HEAD" bits. Remove the second one and it works correctly. The second one works for me. So, yes, this appears to be fixed. Thanks! (In reply to Mark Linimon from comment #5) Looks good! Thanks, Mark. (In reply to graham from comment #9) Oops, looks like I spoke too soon. I just tried a few of the ones I listed above. https://svnweb.freebsd.org/ports/head/math/fftw3-quad/pkg-descr?revision=HEAD (i.e. math/fftw3-quad from my list) still returns an error. (In reply to graham from comment #10) That port actually lacks a pkg-descr file. The error is correct. I am not sure what percentage of ports lack a pkg-descr file Created attachment 175460 [details] Fix the long description link for ports without their own pkg-descr file This bug is not related to bug#206709 because portindex only creates the html pages for the categories listings (reachable from the left sidebar). E.g. if you go to the listing for all math ports (https://www.freebsd.org/ports/math.html) and then scroll down to the fftw3-quad port, the link for the long description works (linking to the description for the "master" port fftw3). But if you use the search box you get to another page (https://www.freebsd.org/cgi/ports.cgi?query=fftw3-quad&stype=all) where the link is broken. The search results are created by /cgi/ports.cgi (https://svnweb.freebsd.org/doc/head/en_US.ISO8859-1/htdocs/cgi/ports.cgi?view=markup). On lines 311-314 the value from the INDEX file is correctly read into $descfile but on line 344 $l (which is based on the port's path in the ports tree) is used for creating the link. In my attached patch I've also renamed a variable name ($remotePrefixCVS -> $remotePrefixRepo) and updated the associated comment. :-) A commit references this bug: Author: crees Date: Sun Dec 23 21:41:27 UTC 2018 New revision: 52715 URL: https://svnweb.freebsd.org/changeset/doc/52715 Log: Fix long descriptions (pkg-descr) links for slave ports While here, use https for svnweb and use Repo instead of Cvs for variable. PR: doc/209220 Submitted by: Andreas Perstinger Changes: head/en_US.ISO8859-1/htdocs/cgi/ports.cgi Brilliant, well done. I've applied the substitution to the descr variable as well as $l, though I'm sure it works mostly without. Committed, thanks! |