tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Wyraz <michael.wy...@evermind.de>
Subject Problems with utf8 characters in tml in 5.4-alpha24
Date Wed, 06 Nov 2013 12:12:47 GMT

I'm testing a bit with tapestry 5.4 (latest alpha). As soon as I have 
utf8 characters in my tml i get an exception concerning invalid utf8 
bytes. This happens at least on windows.
I assume it's a bug in XMLTokenStream 

within openStream.

On Tapestry 5.3, both reader and writer use system encoding so encoding 
will be intact.

On 5.4 the reader ist opened with "utf-8", the writer with system 
encoding which might mess up resulting encoding. That was discussed a 
while ago in 

but never changed.

It would be great if this can be fixed. I could not test an in-place-fix 
(using service overrides or so) because the class is directly 
instanciated rather than injected. Basically the fix would be to change 
the line

    PrintWriter writer = new PrintWriter(bos);


    PrintWriter writer = new PrintWriter(new OutputStreamWriter(bos,

(Is not 100% equal because the upper constructor wraps the OSW into a 
BufferedWriter but this should not make sense when writing to a BAOS.

Thank you,

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message