Edgewall Software
Modify

Opened 19 years ago

Closed 18 years ago

Last modified 18 years ago

#3066 closed defect (fixed)

unicode error in SilverCity

Reported by: Christian Boos Owned by: Jonas Borgström
Priority: normal Milestone: 0.10
Component: general Version: devel
Severity: minor Keywords: unicode silvercity
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description (last modified by Christian Boos)

I was looking for one of the SilverCity error that cmlenz told me about on IRC:

2006-04-19 15:37:08,424 Trac[browser] DEBUG: Rendering preview of node Menu.py@1 with mime-type text/x-python; charset=iso-8859-15
2006-04-19 15:37:08,428 Trac[api] DEBUG: Trying to render HTML preview using SilverCityRenderer
2006-04-19 15:37:08,472 Trac[api] WARNING: HTML preview using <trac.mimeview.silvercity.SilverCityRenderer object at 0x41de7f4c> failed ('ascii' codec can't encode character u'\xf6' in position 749: ordinal not in range(128))
Traceback (most recent call last):
  File "/usr/lib/python2.3/site-packages/trac/mimeview/api.py", line 287, in render
    filename, url)
  File "/usr/lib/python2.3/site-packages/trac/mimeview/silvercity.py", line 95, in render
    generator().generate_html(buf, content)
  File "/usr/lib/python2.3/site-packages/SilverCity/Python.py", line 60, in generate_html
    lexer.tokenize_by_style(buffer, self.event_handler)
  File "/usr/lib/python2.3/site-packages/SilverCity/Lexer.py", line 8, in tokenize_by_style
    call_back
UnicodeEncodeError: 'ascii' codec can't encode character u'\xf6' in position 749: ordinal not in range(128)
2006-04-19 15:37:08,580 Trac[api] DEBUG: Trying to render HTML preview using EnscriptRenderer
2006-04-19 15:37:08,580 Trac[enscript] DEBUG: Enscript command line: enscript --color -h -q --language=html -p - -Epython
2006-04-19 15:37:08,601 Trac[cache] DEBUG: Checking whether sync with repository is needed

another one:

2006-04-19 15:37:09,518 Trac[browser] DEBUG: Rendering preview of node auth.py@1 with mime-type text/x-python; charset=iso-8859-15
2006-04-19 15:37:09,519 Trac[api] DEBUG: Trying to render HTML preview using SilverCityRenderer
2006-04-19 15:37:09,564 Trac[api] WARNING: HTML preview using <trac.mimeview.silvercity.SilverCityRenderer object at 0x83d71ec> failed ('ascii' codec can't encode character u'\xf6' in position 749: ordinal not in range(128))
Traceback (most recent call last):
  File "/usr/lib/python2.3/site-packages/trac/mimeview/api.py", line 287, in render
    filename, url)
  File "/usr/lib/python2.3/site-packages/trac/mimeview/silvercity.py", line 95, in render
    generator().generate_html(buf, content)
  File "/usr/lib/python2.3/site-packages/SilverCity/Python.py", line 60, in generate_html
    lexer.tokenize_by_style(buffer, self.event_handler)
  File "/usr/lib/python2.3/site-packages/SilverCity/Lexer.py", line 8, in tokenize_by_style
    call_back
UnicodeEncodeError: 'ascii' codec can't encode character u'\xf6' in position 749: ordinal not in range(128)
2006-04-19 15:37:09,566 Trac[api] DEBUG: Trying to render HTML preview using EnscriptRenderer
2006-04-19 15:37:09,567 Trac[enscript] DEBUG: Enscript command line: enscript --color -h -q --language=html -p - -Epython
2006-04-19 15:37:09,626 Trac[svn_fs] DEBUG: Closing subversion file-system at /var/svn/edgewall.com/trac

As we can see, the enscript renderer succeed on the same input.

Attachments (0)

Change History (3)

comment:1 by Jonas Borgström, 18 years ago

I don't see any reference to SilverCity at all in that log message…

comment:2 by Christian Boos, 18 years ago

Description: modified (diff)

Right, I pasted the wrong stack trace (mixed up with #3065…)

I returned to the log, found some of the SilverCity related errors and adjusted the description accordingly.

(btw, jonas, guess where's the u'\xf6' coming from :) )

comment:3 by Jonas Borgström, 18 years ago

Resolution: fixed
Status: newclosed

Yeah I've seen that error a million times :) It should be fixed in r3420 anyway.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jonas Borgström.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jonas Borgström to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.