Facundo Batista | 17 Oct 04:18 2007
Picon

Docutils, Python PEPs, and non-ASCII day names

Hi!

I have a problem in the Python project related to docutils.

I wanted to make a change in some Python PEPs. So I checked out the
PEPs from the SVN and run "make", and it crashes with the following:

  SyntaxError: Non-ASCII character '\xc3' in file
    .../peps/docutils/parsers/rst/directives/images.py
    on line 4, but no encoding declared;
    see http://www.python.org/peps/pep-0263.html for details
  make: *** [pep-0001.html] Error 1

Line 4 of that file says:

  # Date: $Date: 2005-12-28 22:14:21 -0300 (mié, 28 dic 2005) $

Notice the day name: mié. This is because the $date of the file is
translated by SVN, and in Spanish Wednesday is Miércoles.

The solution to this is to put a "-*- coding:utf8 -*-" line in the
beginning of this file and all where happens the same.

I'm pretty sure that this file comes from the Docutils project,
because in the PEP SVN it makes a checkout from svn.berlios.de, but I
actually don't know how this is done, and I'm not finding which files
are checked out.

If you please point me, I can fix these. The "coding" line won't hurt
anybody, and help all those that have non-ASCII characters in the
(Continue reading)

David Goodger | 26 Oct 15:54 2007

Re: Docutils, Python PEPs, and non-ASCII day names

On 16/10/2007, Facundo Batista <facundobatista <at> gmail.com> wrote:
> I have a problem in the Python project related to docutils.
>
> I wanted to make a change in some Python PEPs. So I checked out the
> PEPs from the SVN and run "make", and it crashes with the following:
>
>   SyntaxError: Non-ASCII character '\xc3' in file
>     .../peps/docutils/parsers/rst/directives/images.py
>     on line 4, but no encoding declared;
>     see http://www.python.org/peps/pep-0263.html for details
>   make: *** [pep-0001.html] Error 1
>
> Line 4 of that file says:
>
>   # Date: $Date: 2005-12-28 22:14:21 -0300 (mié, 28 dic 2005) $
>
> Notice the day name: mié. This is because the $date of the file is
> translated by SVN, and in Spanish Wednesday is Miércoles.

This is a known SVN issue.  On python-dev you received instructions
how to avoid this (workaround: use "LANG=C svn up").

> The solution to this is to put a "-*- coding:utf8 -*-" line in the
> beginning of this file and all where happens the same.

Another solution is to replace $Date$ with $Id$.  This was done in
revision 4564 on 2006-05-21.

> I'm pretty sure that this file comes from the Docutils project,
> because in the PEP SVN it makes a checkout from svn.berlios.de, but I
(Continue reading)

Facundo Batista | 26 Oct 16:07 2007
Picon

Re: Docutils, Python PEPs, and non-ASCII day names

2007/10/26, David Goodger <goodger <at> python.org>:

> > The solution to this is to put a "-*- coding:utf8 -*-" line in the
> > beginning of this file and all where happens the same.
>
> Another solution is to replace $Date$ with $Id$.  This was done in
> revision 4564 on 2006-05-21.

Yes, after I found out how this "external thing" was done (learning
everyday!), I found that we're checking out from the "PEP project" an
old version of docutils...

> Already fixed in SVN.  The PEP repository's external Docutils is
> pinned at revision 4447 right now; it could be updated to refer to a
> later revision.

Yes, good point: Do you have a recomendation to which version update?
Something like the last stable?

I could update this, and see if there's no major difference or
something in the resulting htmls...

Thank you!!!

--

-- 
.    Facundo

Blog: http://www.taniquetil.com.ar/plog/
PyAr: http://www.python.org/ar/

(Continue reading)

David Goodger | 26 Oct 16:32 2007

Re: Docutils, Python PEPs, and non-ASCII day names

On 26/10/2007, Facundo Batista <facundobatista <at> gmail.com> wrote:
> 2007/10/26, David Goodger <goodger <at> python.org>:
> > Already fixed in SVN.  The PEP repository's external Docutils is
> > pinned at revision 4447 right now; it could be updated to refer to a
> > later revision.
>
> Yes, good point: Do you have a recomendation to which version update?
> Something like the last stable?

There is no such thing currently.

The latest version should be fine, but needs to be tested well.  I
don't have time to test.

It may be easier for now to just use "LANG=C svn up".

> I could update this, and see if there's no major difference or
> something in the resulting htmls...

Be sure to run the python.org build as well, since that depends on the
same version of Docutils.  Ask on the pydotorg at python.org list.

--

-- 
David Goodger <http://python.net/~goodger>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
(Continue reading)

SourceForge.net | 29 Oct 19:36 2007
Picon
Picon

[ docutils-Bugs-1822272 ] latex writer should include hyperref only at the end

Bugs item #1822272, was opened at 2007-10-29 18:36
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=422030&aid=1822272&group_id=38414

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nicolas Girard (ngirard)
Assigned to: Nobody/Anonymous (nobody)
Summary: latex writer should include hyperref only at the end

Initial Comment:
In latex2e/__init__.py, line 696 generates

  \usepackage[colorlinks=true,linkcolor=blue,urlcolor=blue]{hyperref}

The problem is, hyperref is included before many extensions, among which the one that the user may specify
using the --stylesheet command-line option.
This is highly likely to trigger incompatibilities.[1]_

>From hyperref's manual:

  "Make sure it comes last of your loaded packages, 
(Continue reading)

Nicolas Girard | 31 Oct 13:42 2007
Picon

Handling the class directive in the LaTeX writer

Hi,
for personal use in any case, and for anyone interested if any, I'd like to 
change the way the LaTeX writer deals with:: 

  .. class:: c1...ci...cn

upon sections and paragraphs.

Right now, afaik, the writer produces comments like:

  % class: c1...ci...cn

whereas I'd like it to generate something like

  \AtBeginc1
  ...
  \AtBeginci
  ...
  \AtBegincn

before generating the related node, and something like

  \AtEndc1
  ...
  \AtEndci
  ...
  \AtEndcn

after generating the node.

(Continue reading)


Gmane