[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: files in international/l10n take too long to process



On Fri, Jul 28, 2000 at 12:08:03AM +0200, Denis Barbier wrote:
> > > This is indeed what i realized, version shipped with Potato has a bad
> > > designed pass5, which has been fixed lately because this slow processing
> > > only occurs with large files.
> > 
> > NB take a look at http://lully.debian.org/~joy/webwml/build-log for a
> > listing of website building errors with wml 2.x... scary.
> 
> Hi Josip, could you check if these changes are right with WML 1.7.4 so
> that they could be committed, please?

Aside from the commenting in votebar.wml and wml::sys::compat1 thing in
.wmlrc, I've verified all of your patches worked and checked them in CVS.
Thanks.

BTW why not fix individual documents containing container tags and include
wml::sys::compat1 in them? Perhaps with some kind of conditional, so that we
don't have to make the bogus directory with a bogus file in it.

> With these patches applied, i was able to compile the whole website (but
> i send patches about international/l10n to Jay) with my current
> development version (i did not check with WML 2.0.2).
> The more i read WML code, the less i understand how Meta-HTML is able to
> parse some buggy constructs, there might be some kind of magic here ;-)
> 
> I only fixed English version, because i believe that if something goes
> wrong with foreign languages, it is translator's fault.

Right.

Note: I've applied the below patch for SPI/template/template.wml to
template/{devel,menu}bar.wml, too. Also, I've noticed that the pass 9 takes
quite a lot of time on vendors.CD file, too; however two slices are used in
the file. Could we <protect pass=5,9> everything but that chunk?

> Index: english/.wmlrc
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/.wmlrc,v
> retrieving revision 1.8
> diff -u -r1.8 .wmlrc
> --- english/.wmlrc	2000/06/07 13:01:58	1.8
> +++ english/.wmlrc	2000/07/27 22:01:10
> @@ -17,3 +17,4 @@
>  -D HTMLDIR~../../debian.org
>  -D CHARSET=iso-8859-1
>  -I ../english/template
> +-i wml::sys::compat1
> Index: english/SPI/template/ctime.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/SPI/template/ctime.wml,v
> retrieving revision 1.6
> diff -u -r1.6 ctime.wml
> --- english/SPI/template/ctime.wml	2000/03/19 13:51:02	1.6
> +++ english/SPI/template/ctime.wml	2000/07/27 22:01:11
> @@ -83,12 +83,24 @@
>  	my ($time, $sec, $min, $hour, $mday, $monnr, $year, $wday, $yday, $isdst, $mon);
>  	# The last modification time of inputfile in ISO dd-mm-yyyy hh:mm:ss format.
>  	if (defined $(GEN_TIME)) {
> -		$WML_GEN_ISOTIME =~ /(..)-(..)-(....) (..):(..):(..)/;
> -		$time = timelocal($6, $5, $4, $1, $2-1, $3);
> +		$WML_GEN_ISOTIME =~ /(\d+)-(..)-(\d+) (..):(..):(..)/;
> +                if ($1 <= 31) {
> +                        #  for WML 1.x
> +		        $time = timelocal($6, $5, $4, $1, $2-1, $3);
> +                }
> +                else {
> +		        $time = timelocal($6, $5, $4, $3, $2-1, $1);
> +                }
>  	}
>  	else {
> -		$WML_SRC_ISOTIME =~ /(..)-(..)-(....) (..):(..):(..)/;
> -		$time = timelocal($6, $5, $4, $1, $2-1, $3);
> +		$WML_SRC_ISOTIME =~ /(\d+)-(..)-(\d+) (..):(..):(..)/;
> +                if ($1 <= 31) {
> +                        #  for WML 1.x
> +		        $time = timelocal($6, $5, $4, $1, $2-1, $3);
> +                }
> +                else {
> +		        $time = timelocal($6, $5, $4, $3, $2-1, $1);
> +                }
>  	}
>  	($sec, $min, $hour, $mday, $monnr, $year, $wday, $yday, $isdst) = gmtime($time);
>  	$wday = $dow{$CUR_ISO_LANG}[$wday];
> Index: english/SPI/template/template.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/SPI/template/template.wml,v
> retrieving revision 1.25
> diff -u -r1.25 template.wml
> --- english/SPI/template/template.wml	2000/07/01 11:23:06	1.25
> +++ english/SPI/template/template.wml	2000/07/27 22:01:11
> @@ -151,11 +151,7 @@
>  
>  # %0 and %1 are for font color and font size
>  <define-container FONTS_SANS-SERIF whitespace=delete>
> -	<font face="\
> -	<: if ("$(SANS_SERIF_FONT)" eq "")
> -		{print "Arial,Helvetica"}
> -	else
> -		{print "$(SANS_SERIF_FONT)"} :>" %0 %1>
> +	<font face="$(SANS_SERIF_FONT:-Arial,Helvetica)" %0 %1>
>  	%body
>  	</font>
>  </define-container>
> Index: english/consultants/consultant.data
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/consultants/consultant.data,v
> retrieving revision 1.87
> diff -u -r1.87 consultant.data
> --- english/consultants/consultant.data	2000/07/10 01:42:49	1.87
> +++ english/consultants/consultant.data	2000/07/27 22:01:11
> @@ -150,7 +150,7 @@
>  	[NO:Villig å flytte:]\
>  	[RU:Willing to Relocate:]\
>  </define-tag>
> -<define-tag total_consultant>125</define-tag>
> +<define-tag total_consultant>128</define-tag>
>  <define-tag total_country>28</define-tag>
>  <define-tag consult_total_message whitespace=delete>
>  	[DE:<total_consultant> Debian consultants listed in <total_country> countries worldwide.:]
> @@ -220,11 +220,11 @@
>  <LI><A HREF="#Portugal"><PTc></A> (2)</LI>
>  <LI><A HREF="#Russia"><RUc></A> (1)</LI>
>  <LI><A HREF="#South_Africa"><ZAc></A> (2)</LI>
> -<LI><A HREF="#Spain"><ESc></A> (1)</LI>
> +<LI><A HREF="#Spain"><ESc></A> (2)</LI>
>  <LI><A HREF="#Sweden"><SEc></A> (4)</LI>
>  <LI><A HREF="#UK"><UKc></A> (2)</LI>
> -<LI><A HREF="#US"><USc></A> (33)</LI>
> -<LI><A HREF="#Relocate"><willing_to_relocate></A> (4)</LI>
> +<LI><A HREF="#US"><USc></A> (37)</LI>
> +<LI><A HREF="#Relocate"><willing_to_relocate></A> (2)</LI>
>  </UL>
>  
>  # Total
> @@ -815,8 +815,8 @@
>  <company SoftBrain>
>  <address Munich, Germany>
>  <phone   +49-(0)6781-44486>
> -<phone   +49-(0)171-6937380
> -<fax     +49-(0)6781-44586
> +<phone   +49-(0)171-6937380>
> +<fax     +49-(0)6781-44586>
>  <email   rashid@paracha.de>
>  <URL     http://www.softbrain.de/>
>  <rates   Negotiable.>
> @@ -1692,7 +1692,7 @@
>  # Consultant: Relocate
>  <P>
>  <name    Aaron Dewell>
> -<company Woods Networking Consultants
> +<company Woods Networking Consultants>
>  <address Anywhere, currently Anchorage, AK, USA>
>  <phone   +1-907-230-0199>
>  <email   info@woods.net>
> Index: english/distrib/vendors.CD
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/distrib/vendors.CD,v
> retrieving revision 1.87
> diff -u -r1.87 vendors.CD
> --- english/distrib/vendors.CD	2000/07/27 02:52:28	1.87
> +++ english/distrib/vendors.CD	2000/07/27 22:01:11
> @@ -1,5 +1,7 @@
>  #include "../../english/distrib/vendors.CD.def"
>  
> +#   Fix a bug with WML 1.7.4 which make WML very slow on large files
> +<protect pass=5>
>  <a name="ar"><h3><ARc></h3>
>  <vendorentry>
>  	<vendor Internet Argentina ISP>
> @@ -1175,3 +1177,4 @@
>  	<tr><td colspan="2">
>  	<type> <OfficialCD>
>  </vendorentry>
> +</protect>
> Index: english/security/1997/19970206b.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/security/1997/19970206b.wml,v
> retrieving revision 1.4
> diff -u -r1.4 19970206b.wml
> --- english/security/1997/19970206b.wml	1999/08/13 21:18:18	1.4
> +++ english/security/1997/19970206b.wml	2000/07/27 22:01:12
> @@ -1,8 +1,8 @@
>  <define-tag pagetitle>rlogin</define-tag>
>  <define-tag report_date>1997-02-06</define-tag>
>  <define-tag packages></define-tag>
> -<define-tag description>rlogin doesn't check $TERM's length.</define -tag>
> -<define-tag vulnerable><FONT COLOR=FF0000|>Yes</FONT></define-tag>
> +<define-tag description>rlogin doesn't check $TERM's length.</define-tag>
> +<define-tag vulnerable><FONT COLOR=FF0000>Yes</FONT></define-tag>
>  <define-tag fixed>yes</define-tag>
>  <define-tag moreinfo></define-tag>
>  
> Index: english/template/debian/ctime.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/template/debian/ctime.wml,v
> retrieving revision 1.48
> diff -u -r1.48 ctime.wml
> --- english/template/debian/ctime.wml	2000/05/26 08:27:05	1.48
> +++ english/template/debian/ctime.wml	2000/07/27 22:01:12
> @@ -110,15 +110,27 @@
>  	my ($time, $sec, $min, $hour, $mday, $monnr, $year, $wday, $yday, $isdst, $mon);
>  	# The last modification time of inputfile in ISO dd-mm-yyyy hh:mm:ss format.
>  	if (defined $(GEN_TIME)) {
> -		$WML_GEN_ISOTIME =~ /(..)-(..)-(\d+) (..):(..):(..)/;
> -		$time = timelocal($6, $5, $4, $1, $2-1, $3);
> +		$WML_GEN_ISOTIME =~ /(\d+)-(..)-(\d+) (..):(..):(..)/;
> +                if ($1 <= 31) {
> +                        #  for WML 1.x
> +		        $time = timelocal($6, $5, $4, $1, $2-1, $3);
> +                }
> +                else {
> +		        $time = timelocal($6, $5, $4, $3, $2-1, $1);
> +                }
>  		# $lday=$1; $lmon=$2; $lyear=$3; $lhr=$4; $lmin=$5; $lsec=$6;
>  		# if ($lyear > 19000) { $lyear = 1900+($lyear-19000); }
>  		# $time = timelocal($lsec, $lmin, $lhr, $lday, $lmon-1, $lyear);
>  	}
>  	else {
> -		$WML_SRC_ISOTIME =~ /(..)-(..)-(\d+) (..):(..):(..)/;
> -		$time = timelocal($6, $5, $4, $1, $2-1, $3);
> +		$WML_SRC_ISOTIME =~ /(\d+)-(..)-(\d+) (..):(..):(..)/;
> +                if ($1 <= 31) {
> +                        #  for WML 1.x
> +		        $time = timelocal($6, $5, $4, $1, $2-1, $3);
> +                }
> +                else {
> +		        $time = timelocal($6, $5, $4, $3, $2-1, $1);
> +                }
>  		# $lday=$1; $lmon=$2; $lyear=$3; $lhr=$4; $lmin=$5; $lsec=$6;
>  		# if ($lyear > 19000) { $lyear = 1900+($lyear-19000); }
>  		# $time = timelocal($lsec, $lmin, $lhr, $lday, $lmon-1, $lyear);
> Index: english/template/debian/footer.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/template/debian/footer.wml,v
> retrieving revision 1.55
> diff -u -r1.55 footer.wml
> --- english/template/debian/footer.wml	2000/07/06 10:58:17	1.55
> +++ english/template/debian/footer.wml	2000/07/27 22:01:12
> @@ -127,9 +127,9 @@
>  # write to debian-www first.
>  
>  <define-tag webmastermail whitespace=delete>
> -	<if   "%0" ""     "<A href=\"mailto:webmaster@debian.org\";>webmaster@debian.org</A>">
> -	<ifeq "%0" "vote" "<A href=\"mailto:webmaster@vote.debian.org\";>webmaster@vote.debian.org</A>">
> -	<ifeq "%0" "bugs" "<A href=\"mailto:owner@bugs.debian.org\";>owner@bugs.debian.org</A>">
> +	<when <string-eq "%0" "">><A href="mailto:webmaster@debian.org";>webmaster@debian.org</A></when>
> +	<when <string-eq "%0" "vote">><A href="mailto:webmaster@vote.debian.org";>webmaster@vote.debian.org</A></when>
> +	<when <string-eq "%0" "bugs">><A href="mailto:owner@bugs.debian.org";>owner@bugs.debian.org</A></when>
>  </define-tag>
>  
>  <HR>
> @@ -138,5 +138,6 @@
>  
>  <SMALL><lastmodified>: <:= ctime () :><BR>
>  
> -<ifeq "$(NOCOPYRIGHT)" ""
> -"<copyright> &copy; 1997-2000 <A href=\"http://www.spi-inc.org/\";>SPI</A>; <seelicense> </SMALL>">
> +<when <string-eq "$(NOCOPYRIGHT)" "">>
> +<copyright> &copy; 1997-2000 <A href="http://www.spi-inc.org/";>SPI</A>; <seelicense> </SMALL>
> +</when>
> Index: english/template/debian/news.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/template/debian/news.wml,v
> retrieving revision 1.12
> diff -u -r1.12 news.wml
> --- english/template/debian/news.wml	2000/07/27 19:43:28	1.12
> +++ english/template/debian/news.wml	2000/07/27 22:01:12
> @@ -46,7 +46,8 @@
>  <<mainbody>>
>  
>  <ifeq "$(NOHOMELINK)" ""
> -      "<HR>\n<P><returnline>">
> +      "<HR>
> +<P><returnline>">
>  <ifeq "$(NOLANGUAGES)" "" "<:= languages() :>">
>  #use wml::debian::footer
>  
> Index: english/template/debian/template.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/template/debian/template.wml,v
> retrieving revision 1.6
> diff -u -r1.6 template.wml
> --- english/template/debian/template.wml	2000/03/26 18:10:33	1.6
> +++ english/template/debian/template.wml	2000/07/27 22:01:12
> @@ -12,7 +12,8 @@
>  <<mainbody>>
>  
>  <ifeq "$(NOHOMELINK)" ""
> -      "<HR>\n<P><returnline>">
> +      "<HR>
> +<P><returnline>">
>  <ifeq "$(NOLANGUAGES)" "" "<:= languages() :>">
>  #use wml::debian::footer
>  
> Index: english/template/debian/votebar.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/template/debian/votebar.wml,v
> retrieving revision 1.42
> diff -u -r1.42 votebar.wml
> --- english/template/debian/votebar.wml	2000/07/22 23:32:43	1.42
> +++ english/template/debian/votebar.wml	2000/07/27 22:01:12
> @@ -307,6 +307,7 @@
>          $base = $1;
>       }
>       $title = ''; $status = '';
> +<protect pass=2>
>       foreach $line (<FILE>) {
>          if ($line =~ /^<define-tag pagetitle>(.*)<\/define-tag>$/) {
>             $title = $1;
> @@ -314,6 +315,7 @@
>          elsif ($line =~ /^<define-tag status>(.*)<\/define-tag>$/) {
>             $status = $1;
>          }
> +</protect>
>  
>  		if ( $title && $status ) {
>             $str1 = "&nbsp;<A HREF=\"$path/$base\">$title</A><BR>\n";
> @@ -390,7 +392,7 @@
>  			&nbsp;<A href="howto_vote"><vote></A><BR>
>  			</SMALL>
>  		</FONT></P>
> -		<:= get_issues_list( <sub>, '0', <current> ) :>
> +		#<:= get_issues_list( <sub>, '0', <current> ) :>
>  	</TD>
>  	<TD valign="TOP">
>  		<BR>
> Index: english/vote/1999/amend_0004.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/vote/1999/amend_0004.wml,v
> retrieving revision 1.4
> diff -u -r1.4 amend_0004.wml
> --- english/vote/1999/amend_0004.wml	1999/05/18 16:33:10	1.4
> +++ english/vote/1999/amend_0004.wml	2000/07/27 22:01:12
> @@ -6,10 +6,10 @@
>  #use wml::debian::basic
>  
>  <define-tag email>\
> -	%0 &lt;<A HREF="mailto:%1";>%1</a>&gt;
> +	%0 &lt;<A HREF="mailto:%1";>%1</A>&gt;
>  </define-tag>
>  
> -<A NAME="0001>
> +<A NAME="0001">&nbsp;</A>
>  <H2>Amendment-0004-1</H2>
>  <TABLE>
>  	<TR>
> @@ -41,7 +41,7 @@
>  		<TD><OL>
>  			<LI><A HREF="fixed_chicken.jpg"><IMG SRC="fixed_chicken_t.jpg" ALT="fixed chicken"></A>
>  			<LI><A HREF="dg.jpg"><IMG SRC="dg_t.jpg" ALT="dg"></A>
> -			<LI><A AHREF="villate.jpg">pending "swirl w/ offical"<AIMG SRC="villate_t.jpg" ALT="new villante"></A><BR>
> +			<LI><A HREF="villate.jpg">pending "swirl w/ offical"<IMG SRC="villate_t.jpg" ALT="new villante"></A><BR>
>  		</OL></TD>
>  	</TR>
>  	<TR>
> Index: english/vote/1999/vote_0001.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/vote/1999/vote_0001.wml,v
> retrieving revision 1.12
> diff -u -r1.12 vote_0001.wml
> --- english/vote/1999/vote_0001.wml	1999/05/03 02:29:15	1.12
> +++ english/vote/1999/vote_0001.wml	2000/07/27 22:01:12
> @@ -35,7 +35,7 @@
>  					<LI><A HREF="joseph">Joseph Carter</A>
>  					<LI><A HREF="ben">Ben Collins</A>
>  					<LI><A HREF="wichert">Wichert Akkerman</A>
> -					<LI><A HREF="richard"">Richard Braakman</A>
> +					<LI><A HREF="richard">Richard Braakman</A>
>  				</OL></TD>
>  			</TR>
>  			<TR>
> Index: english/vote/1999/vote_0002.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/vote/1999/vote_0002.wml,v
> retrieving revision 1.11
> diff -u -r1.11 vote_0002.wml
> --- english/vote/1999/vote_0002.wml	1999/05/04 17:53:05	1.11
> +++ english/vote/1999/vote_0002.wml	2000/07/27 22:01:12
> @@ -85,7 +85,7 @@
>  			<TR>
>  				<TD><B>Ballot</B>:</TD>
>  				<TD>
> -					<A HREF="mailto:ballot@vote.debian.org?S=logo1>ballot@vote.debian.org</A><BR>
> +					<A HREF="mailto:ballot@vote.debian.org?S=logo1";>ballot@vote.debian.org</A><BR>
>  					Subject = logo1
>  				</TD>
>  			</TR>
> Index: english/vote/2000/amend_0008.wml
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/vote/2000/amend_0008.wml,v
> retrieving revision 1.1
> diff -u -r1.1 amend_0008.wml
> --- english/vote/2000/amend_0008.wml	2000/06/16 04:51:37	1.1
> +++ english/vote/2000/amend_0008.wml	2000/07/27 22:01:12
> @@ -6,10 +6,10 @@
>  #use wml::debian::basic
>  
>  <define-tag email>\
> -	%0 &lt;<A HREF="mailto:%1";>%1</a>&gt;
> +	%0 &lt;<A HREF="mailto:%1";>%1</A>&gt;
>  </define-tag>
>  
> -<A NAME="0001>
> +<A NAME="0001">&nbsp;</A>
>  <H2>Amendment-0008-1</H2>
>  <TABLE>
>  	<TR>
> Index: english/y2k/extra.data
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/y2k/extra.data,v
> retrieving revision 1.29
> diff -u -r1.29 extra.data
> --- english/y2k/extra.data	2000/05/13 18:06:12	1.29
> +++ english/y2k/extra.data	2000/07/27 22:01:12
> @@ -107,7 +107,7 @@
>  <define-tag y2kentry>\
>  	<TR><TD width=15%>%0<TD width=5%>\
>  	<: if ("%1" eq "ALL") {print "<all>";} else {print "%1";} :>
> -	<TD width=5%><font color="\
> +	<TD width=5%><: print "<" . "font color=\""; :>\
>  	<ifeq "%2" "OK" "00BB00\"><ok>">\
>  	<ifeq "%2" "BAD" "FF0000\"><bad>">\
>  	<ifeq "%2" "OK?" "00BBBB\"><ok2>">\
> @@ -300,7 +300,7 @@
>  <y2kentry twm ALL OK http://www.xfree86.org/FAQ/#Y2K>
>  <y2kentry vim ALL OK http://www.vim.org/y2k.html>
>  <y2kentry vim-rt ALL OK http://www.vim.org/y2k.html>
> -<y2kentry webalizer 1.20-4 BAD http://www.debian.org/Bugs/db/53/53820.html
> +<y2kentry webalizer 1.20-4 BAD http://www.debian.org/Bugs/db/53/53820.html>
>  <y2kentry xbase ALL OK http://www.xfree86.org/FAQ/#Y2K>
>  <y2kentry xbase-clients ALL OK http://www.xfree86.org/FAQ/#Y2K>
>  <y2kentry xbooks ALL OK http://www.xfree86.org/FAQ/#Y2K>
> Index: english/y2k/index.data
> ===================================================================
> RCS file: /cvs/webwml/webwml/english/y2k/index.data,v
> retrieving revision 1.20
> diff -u -r1.20 index.data
> --- english/y2k/index.data	1999/12/20 11:50:25	1.20
> +++ english/y2k/index.data	2000/07/27 22:01:12
> @@ -91,7 +91,7 @@
>  <define-tag y2kentry>\
>  	<TR><TD width=15%>%0<TD width=5%>\
>  	<: if ("%1" eq "ALL") {print "<all>";} else {print "%1";} :>
> -	<TD width=5%><font color="\
> +	<TD width=5%><: print "<" . "font color=\""; :>\
>  	<ifeq "%2" "OK" "00BB00\"><ok>">\
>  	<ifeq "%2" "BAD" "FF0000\"><bad>">\
>  	<ifeq "%2" "OK?" "00BBBB\"><ok2>">\


-- 
Digital Electronic Being Intended for Assassination and Nullification



Reply to: