Bug#905440: www.debian.org: remove "last modified" from footer
Hey steve! On 8/21/18, Steve McIntyre wrote: > On Sun, Aug 05, 2018 at 06:40:23AM +0100, Steve McIntyre wrote: >>On Sat, Aug 04, 2018 at 07:32:17PM +0200, Laura Arjona Reina wrote: The last commit on index.wml was in 2014, which only changed http to https, so no real content change. In fact, the content didn't changed since 2012 and may be out of date. >>> >>>The content is current. >>> Please just remove this useless information from every page. >>> >>>The date shown is the date of last build. This can be the date when >>>something changed in the page (content or layout), in the templates >>>used to build that page (e.g. a change in the footer), or a force >>>rebuild for any reason. >>> >>>We probably change the string from "Last modified" to something else >>>("Last build" or other wording), but I don't think that it is useless >>>and we should remove it (I'm open to listen to other opinions, >>>though). >> >>Definitely it should stay - a major part of the usefulness of many >>pages is "can I trust this to be up to date?". If desired, I'm happy >>to prod the wml tooling to give us more useful data ("page content >>last modified , page built ")...? > > See https://salsa.debian.org/webmaster-team/webwml/merge_requests/21 > for a first attempt... > > -- > Steve McIntyre, Cambridge, UK. > st...@einval.com > "Arguing that you don't care about the right to privacy because you have > nothing to hide is no different than saying you don't care about free > speech because you have nothing to say." >-- Edward Snowden > >
Bug#905440: www.debian.org: remove "last modified" from footer
The Perl script shown in this post sets the mtime (and atime) to the last commit time. Works very well and needs only 7 sec for the whole webwml repository on my notebook. https://stackoverflow.com/questions/2458042/restore-a-files-modification-time-in-git# I think we only need this run once, after that the perl code for generating the footer can grab the correct mtime. -- regards Thomas
Bug#905440: www.debian.org: remove "last modified" from footer
Hi! El 23/08/18 a las 18:28, Steve McIntyre escribió: > > Except... in Thomas' original bug report he mentions the specific URL > https://www.debian.org/women/ and that *doesn't* have the GEN_TIME > variable set. I think we're actually looking at something else here - > on the www-master server, what's the mtime of the file > english/women/index.wml? If *that* is where the "Last Modified: Fri, > Jun 1 18:42:17 UTC 2018" text is coming from, then I'll need to rework > this change to ignore the on-disk mtime and ask git instead. > yes, ls --full-time index.wml (in www-master.debian.org:/srv/www.debian.org/webwml/english/women/) produces this time: 2018-06-01 18:42:17.640970720 + Cheers -- Laura Arjona Reina https://wiki.debian.org/LauraArjona
Bug#905440: www.debian.org: remove "last modified" from footer
On Thu, Aug 23, 2018 at 02:06:25AM +0200, Laura Arjona Reina wrote: >Hello all > >El 22/08/18 a las 01:50, Steve McIntyre escribió: >> >> See https://salsa.debian.org/webmaster-team/webwml/merge_requests/21 >> for a first attempt... >> >Thanks. >I've had a look to this and made some tests. > >The layout and strings look fine for me. The POT/PO templates update well. > >The pages seem to build well (I didn't build the whole website locally >but tried a good portion of /english and some other languages). > >* Looking at the resulting times shown in the html pages, and >researching a bit, I found this in /devel/website/working: > >--- >GEN_TIME="true" >Sets the date on the resulting files to the timestamp of the >generated files, instead of the timestamp of the source file. >--- Hmmm, yeah. I see that's used in a number of place, not all. No idea why it's there, nor why anybody would think it's a good idea! Looking at the list, *maybe* it's intended to be used in places where a page is just a template and the contents are actually auto-generated, like index files for security updates? Yeah, I think that's the expectation. Except... in Thomas' original bug report he mentions the specific URL https://www.debian.org/women/ and that *doesn't* have the GEN_TIME variable set. I think we're actually looking at something else here - on the www-master server, what's the mtime of the file english/women/index.wml? If *that* is where the "Last Modified: Fri, Jun 1 18:42:17 UTC 2018" text is coming from, then I'll need to rework this change to ignore the on-disk mtime and ask git instead. >(I didn't know this existed) You're not alone! :-) >This variable is considered, in the MR, only in the webwml_built_time >function (correct). The issue I see is that the variable is used in few >pages (see attached file containing a list of the English page that have >the variable set). > >I am not sure how to go now from here; if reviewing which pages should >have the GEN_TIME="true" option in the header, or just forget about the >GEN_TIME variable (delete it in every page) and simplify the functions >in ctime.wml template to reuse the code that is run now when >GEN_VARIABLE is not present for the webwml_modified_time, and the code >that now is run when GEN_VARIABLE is present and has "yes", for the >webwml_built_time. > >Note: there is some more code related to the GEN_VARIABLE in >/english/template/debian/footer.wml that we would need to adapt if we >decide to remove the variable. Nod... -- Steve McIntyre, Cambridge, UK.st...@einval.com Into the distance, a ribbon of black Stretched to the point of no turning back
Bug#905440: www.debian.org: remove "last modified" from footer
Hello all El 22/08/18 a las 01:50, Steve McIntyre escribió: > > See https://salsa.debian.org/webmaster-team/webwml/merge_requests/21 > for a first attempt... > Thanks. I've had a look to this and made some tests. The layout and strings look fine for me. The POT/PO templates update well. The pages seem to build well (I didn't build the whole website locally but tried a good portion of /english and some other languages). * Looking at the resulting times shown in the html pages, and researching a bit, I found this in /devel/website/working: --- GEN_TIME="true" Sets the date on the resulting files to the timestamp of the generated files, instead of the timestamp of the source file. --- (I didn't know this existed) This variable is considered, in the MR, only in the webwml_built_time function (correct). The issue I see is that the variable is used in few pages (see attached file containing a list of the English page that have the variable set). I am not sure how to go now from here; if reviewing which pages should have the GEN_TIME="true" option in the header, or just forget about the GEN_TIME variable (delete it in every page) and simplify the functions in ctime.wml template to reuse the code that is run now when GEN_VARIABLE is not present for the webwml_modified_time, and the code that now is run when GEN_VARIABLE is present and has "yes", for the webwml_built_time. Note: there is some more code related to the GEN_VARIABLE in /english/template/debian/footer.wml that we would need to adapt if we decide to remove the variable. Cheers -- Laura Arjona Reina https://wiki.debian.org/LauraArjona misc/merchandise.wml:1:#use wml::debian::template title="Debian Merchandise" GEN_TIME="yes" BARETITLE=true security/2015/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2016/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/1999/index.wml:2:#use wml::debian::template title="Security Advisories from 1999" GEN_TIME="yes" security/2018/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2014/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2003/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2008/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2012/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2004/CAN-2004-0109.wml:1:#use wml::debian::template title="Kernel Vulnerability Matrix for CAN-2004-0109" GEN_TIME="yes" security/2004/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2004/CAN-2004-0077.wml:1:#use wml::debian::template title="Kernel Vulnerability Matrix for CAN-2004-0077" GEN_TIME="yes" security/1997/index.wml:1:#use wml::debian::template title="Security Advisories from 1997" GEN_TIME="yes" security/2001/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2005/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/make-ref-table.pl:259:#use wml::debian::template title="Security Crossreferences" GEN_TIME="yes" security/1998/index.wml:2:#use wml::debian::template title="Security Advisories from 1998" GEN_TIME="yes" security/parse-advisory.pl:262: $index .= qq|#use wml::debian::template title="" GEN_TIME="yes"\n|; security/crossreferences.wml:1:#use wml::debian::template title="Security Cross References" GEN_TIME="yes" NOHEADER="indeed" security/2007/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2013/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2000/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2002/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2011/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2010/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2009/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/index.wml:1:#use wml::debian::template title="Security Information" GEN_TIME="yes" security/2006/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/2017/index.wml:2:#use wml::debian::template title="" GEN_TIME="yes" security/undated/index.wml:1:#use wml::debian::template title="Security Advisories from late '97 and early '98" GEN_TIME="yes" CD/vendors/index.wml:1:#use wml::debian::cdimage title="Vendors of Debian installation media" BARETITLE=true GEN_TIME=true doc/books.wml:1:#use wml::debian::template title="Debian Books" GEN_TIME="yes" devel/website/working.wml:197:GEN_TIME="true" devel/wnpp/being_packaged_byactivity.wml:1:#use wml::debian::template title="Packages being worked on, organized by activity" GEN_TIME="true" devel/wnpp/help_requested_byage.wml:1:#use wml::debian::template title="Packages for which help was requested, organized by age" GEN_TIME="true" devel/wnpp/being_adopted_byactivity.wml:1:#use wml::debian::template title="Packages currently being
Bug#905440: www.debian.org: remove "last modified" from footer
On Sun, Aug 05, 2018 at 06:40:23AM +0100, Steve McIntyre wrote: >On Sat, Aug 04, 2018 at 07:32:17PM +0200, Laura Arjona Reina wrote: >>> >>>The last commit on index.wml was in 2014, which only changed http to >>>https, so no real content change. In fact, the content didn't changed >>>since 2012 and may be out of date. >> >>The content is current. >> >>>Please just remove this useless information from every page. >> >>The date shown is the date of last build. This can be the date when >>something changed in the page (content or layout), in the templates >>used to build that page (e.g. a change in the footer), or a force >>rebuild for any reason. >> >>We probably change the string from "Last modified" to something else >>("Last build" or other wording), but I don't think that it is useless >>and we should remove it (I'm open to listen to other opinions, >>though). > >Definitely it should stay - a major part of the usefulness of many >pages is "can I trust this to be up to date?". If desired, I'm happy >to prod the wml tooling to give us more useful data ("page content >last modified , page built ")...? See https://salsa.debian.org/webmaster-team/webwml/merge_requests/21 for a first attempt... -- Steve McIntyre, Cambridge, UK.st...@einval.com "Arguing that you don't care about the right to privacy because you have nothing to hide is no different than saying you don't care about free speech because you have nothing to say." -- Edward Snowden
Bug#905440: www.debian.org: remove "last modified" from footer
Hi, On Sun, Aug 05, 2018 at 08:08:40AM +0200, Thomas Lange wrote: > > On Sun, 5 Aug 2018 06:40:23 +0100, Steve McIntyre > > said: > > > Definitely it should stay - a major part of the usefulness of many > > pages is "can I trust this to be up to date?". If desired, I'm happy > That's excatly what I tried to accomplish. Either remove it or have > the correct information. > > If we can generate this information cheaply - perfect. > Do we just need to change the mtime of the *.wml files to the last date > from the git logs before calling make? I could try to write a pipe of > commands for that if you like. No not mtime but git commit time, I guess. That is simpler and more robust. There may be cleaner way but my elementally git skill can come up with this for path/to/file.to.check as: $ git log -n 1 path/to/file.to.check |sed -n -e "s/Date: *//p" So commit your change to git repo and let build script to extract the commit timing. Then inject this sting while building the web page. (Alternatively for Debian package building, we should extract date from debian/changelog.) You can use the "date" command to convert format to any styke (e.g. ISO). I didn't think this was as easy with git until Steve's comment. I am stll have some hung over from $id:$. Osamu
Bug#905440: www.debian.org: remove "last modified" from footer
> On Sun, 5 Aug 2018 06:40:23 +0100, Steve McIntyre said: > Definitely it should stay - a major part of the usefulness of many > pages is "can I trust this to be up to date?". If desired, I'm happy That's excatly what I tried to accomplish. Either remove it or have the correct information. If we can generate this information cheaply - perfect. Do we just need to change the mtime of the *.wml files to the last date from the git logs before calling make? I could try to write a pipe of commands for that if you like. -- regards Thomas
Bug#905440: www.debian.org: remove "last modified" from footer
On Sun, Aug 05, 2018 at 05:51:36AM +0200, Thomas Lange wrote: > >In the long run we may be able to read the git logs and have the >accurate information of the 'last modification'. Currently that does >not seem to be possible, because the build already takes too long. That's actually one of the bits of information we can get quite cheaply. Happy to play with it... -- Steve McIntyre, Cambridge, UK.st...@einval.com "You can't barbecue lettuce!" -- Ellie Crane
Bug#905440: www.debian.org: remove "last modified" from footer
On Sat, Aug 04, 2018 at 07:32:17PM +0200, Laura Arjona Reina wrote: >> >>The last commit on index.wml was in 2014, which only changed http to >>https, so no real content change. In fact, the content didn't changed >>since 2012 and may be out of date. > >The content is current. > >>Please just remove this useless information from every page. > >The date shown is the date of last build. This can be the date when >something changed in the page (content or layout), in the templates >used to build that page (e.g. a change in the footer), or a force >rebuild for any reason. > >We probably change the string from "Last modified" to something else >("Last build" or other wording), but I don't think that it is useless >and we should remove it (I'm open to listen to other opinions, >though). Definitely it should stay - a major part of the usefulness of many pages is "can I trust this to be up to date?". If desired, I'm happy to prod the wml tooling to give us more useful data ("page content last modified , page built ")...? -- Steve McIntyre, Cambridge, UK.st...@einval.com Google-bait: http://www.debian.org/CD/free-linux-cd Debian does NOT ship free CDs. Please do NOT contact the mailing lists asking us to send them to you.
Bug#905440: www.debian.org: remove "last modified" from footer
> On Sat, 04 Aug 2018 19:32:17 +0200, Laura Arjona Reina > said: > The content is current. That's good. > The date shown is the date of last build. This can be the date when something changed in the page (content or layout), in the templates used to build that page (e.g. a change in the footer), or a force rebuild for any reason. I figured that this should be the date of the last build. > We probably change the string from "Last modified" to something else ("Last build" or other wording), but I don't think that it is useless and we should remove it (I'm open to listen to other opinions, though). "Last build" is fine for me. In the long run we may be able to read the git logs and have the accurate information of the 'last modification'. Currently that does not seem to be possible, because the build already takes too long. -- regards Thomas
Bug#905440: www.debian.org: remove "last modified" from footer
El 4 de agosto de 2018 19:32:17 CEST, Laura Arjona Reina escribió: > >We probably change the string I wanted to say: we probably should change the string... Kind regards -- Laura Arjona Reina https://wiki.debian.org/LauraArjona Sent with K-9 mail
Bug#905440: www.debian.org: remove "last modified" from footer
Hello Thomas El 4 de agosto de 2018 17:23:06 CEST, Thomas Lange escribió: > >Package: www.debian.org > >In the footer of every page we list the date the page was last >modified. Currently this information is completly useless, because it >does not show a correct date. e.g. > >https://www.debian.org/women/ >Last Modified: Fri, Jun 1 18:42:17 UTC 2018 > >Let's look into the git log: > >The last commit on index.wml was in 2014, which only changed http to >https, so no real content change. In fact, the content didn't changed >since 2012 and may be out of date. > The content is current. >Please just remove this useless information from every page. The date shown is the date of last build. This can be the date when something changed in the page (content or layout), in the templates used to build that page (e.g. a change in the footer), or a force rebuild for any reason. We probably change the string from "Last modified" to something else ("Last build" or other wording), but I don't think that it is useless and we should remove it (I'm open to listen to other opinions, though). Kind regards -- Laura Arjona Reina https://wiki.debian.org/LauraArjona Sent with K-9 mail
Bug#905440: www.debian.org: remove "last modified" from footer
Package: www.debian.org In the footer of every page we list the date the page was last modified. Currently this information is completly useless, because it does not show a correct date. e.g. https://www.debian.org/women/ Last Modified: Fri, Jun 1 18:42:17 UTC 2018 Let's look into the git log: The last commit on index.wml was in 2014, which only changed http to https, so no real content change. In fact, the content didn't changed since 2012 and may be out of date. Please just remove this useless information from every page. -- regards Thomas