bugmonotone - Bugs: bug #18462, automate stdio seems not to be...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #18462: automate stdio seems not to be utf-8 aware

Submitted by:  Thomas Keller <tommyd>
Submitted on:  Tue 05 Dec 2006 03:44:14 PM UTC  
 
Category: command line UISeverity: 4 - Important
Item Group: incorrect behaviorStatus: Invalid
Privacy: PublicAssigned to: None
Open/Closed: Closed
mtn version --full: 

mtn-0.31

Tue 05 Dec 2006 04:08:46 PM UTC, comment #2:

Not a bug, need to make sure that the counts I get and receive from monotone are actually byte counts rather than character counts.

Thomas Keller <tommyd>
Project Administrator
Tue 05 Dec 2006 03:50:13 PM UTC, comment #1:

Hrm... the second error could be fixed by manually "adapting" the read size (I internally convert the output of monotone to UTF-8), but this seems to be a little hacky. Completly ignoring the output size is not an option since the output can come in chunks.

Thomas Keller <tommyd>
Project Administrator
Tue 05 Dec 2006 03:44:14 PM UTC, original submission:

This is my environment:

$ env | grep UTF
LANG=de_DE.UTF-8
G_FILENAME_ENCODING=@locale,UTF-8,ISO-8859-15,CP1252

$ cat | LANG=en_US.UTF-8 mtn automate stdio
l6:genkey1:äe
mtn: error: Bad input to automate stdio: expected ':' after string size

This pops up because the German umlaut 'ä' is a two byte char in UTF-8 and this seems to confuse the automate_reader class.

Furthermore, output which contains UTF-8 chars is not properly put into chunks, i.e. has a wrong string size prepended:

$ cat | LANG=de_DE.UTF-8 mtn automate stdio
l6:genkey4:foo/3:bare
0:2:l:66:falscher Gebrauch: schlechtes Zeichen '/' in Schlüsselname 'foo/'

Here the German translation of the "misuse" error contains a two byte char and errornously outputs that 66 chars instead of 65 chars follow.

Thomas Keller <tommyd>
Project Administrator

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by tbrownaw (Updated the item)
  • -unavailable- added by tommyd (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 25 Nov 2007 02:53:08 PM UTCtbrownawOpen/ClosedOpen=>Closed
    Tue 05 Dec 2006 04:08:46 PM UTCtommydStatusNone=>Invalid

    Back to the top


    Powered by Savane 3.1-cleanup1