'ascii' codec can't decode byte 0xc3 in position 3: ordinal not in range(128)

Bug #518483 reported by agudeza
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
openMolar
Incomplete
Undecided
Neil Wallace

Bug Description

'ascii' codec can't decode byte 0xc3 in position 3: ordinal not in range(128)

Revision history for this message
Neil Wallace (rowinggolfer) wrote :

I've seen this before, and it relates to the uk pound sign, an issue I thought I had fixed.

could you please indicate which version you are running (the bazaar version is best), and steps needed to duplicate the bug.

the version is displayed at startup, or under "about openmolar" in the menu.

if the gui doesn't fire up at all, versioning can be got from the command line with
openmolar --version

thanks

Neil.

Changed in openmolar:
status: New → Incomplete
Revision history for this message
jesuma (jesuma24) wrote :

jesus@dell2:~/Software$ openmolar --version
trying to install your environment language es_VE.UTF-8
['/usr/bin/openmolar', '--version']
--version
translation tools are installed sucessfully
Version 0.1.9
Bzr Revision No. 605
linux settings
command line options are as follows
--help show this text
--firstrun offer the firstrun config and demodatabase generation
--setup takes you to the admin page
--version show the versioning and exit

Revision history for this message
Neil Wallace (rowinggolfer) wrote :

jesuma - thanks for that.

I am still unsure at which point during runtime you get this bug.

Revision history for this message
jesuma (jesuma24) wrote :

This reported bug occurs in Mint8. In another identical machine (dell 1420) I have ubuntu 9.10 and openmolar runs without problems.

Revision history for this message
ediaz (ediaz-pk25) wrote :

This is a bug, you can start the program in a terminal from the user and put LANG=C and the program start Ok.. This is because you try to use Spanish lang or other..

regards!

Revision history for this message
Neil Wallace (rowinggolfer) wrote :

the real problem here is (I believe) some debugging code I had left in place. The strings are all encoded/decoded correctly for the application, but the output to the terminal was giving this error perhaps.

in any case, bzr version 686 should completely resolve this as the currency symbol is taken from python locale for everything. see also https://bugs.launchpad.net/openmolar/+bug/581498

I would like to close this bug, however, as it remains unclear what steps I have to take to reproduce the error, I am unable to do so.
jesuma - Could you please see if 686 resolves this for you ?

many thanks for reporting this.

Neil

Changed in openmolar:
status: Incomplete → In Progress
Changed in openmolar:
status: In Progress → Fix Committed
assignee: nobody → Neil Wallace (rowinggolfer)
Revision history for this message
ediaz (ediaz-pk25) wrote :
Download full text (7.1 KiB)

sorry doesn't run :-(

alex@alex-desktop:~$ openmolar --firstrun
trying to install your environment language es_ES.UTF-8
['/usr/bin/openmolar', '--firstrun']
--firstrun
translation tools are installed sucessfully
Version 0.1.9
Bzr Revision No. 640
linux settings
deleting any existing openmolar_demo database.... 42
creating database... 1
setting privileges for 'OMuser'
db created sucessfully
New database created sucessfully.
attempting to loadtables.... localhost 3306 OMuser openmolar_demo password
successfully loaded tables
putting a global settings file in /etc/openmolar unable to write to /etc/openmolar... we need root privileges for that
will resort to putting settings into a local file /home/alex/.openmolar/openmolar.conf
putting a local settings file in /home/alex/.openmolar ...ok
Could not resolve property : Strips1_1
DBNAME= existing_database
parsing the global settings file
not using ssl (you really should!)
New connection needed
connecting to openmolar_demo on localhost port 3306
checking schema version... no settings table! (1146, "Table 'openmolar_demo.settings' doesn't exist")
schema assumed to be 1.0
schema is out of date
no settings table! (1146, "Table 'openmolar_demo.settings' doesn't exist")
schema assumed to be 1.0
upgrading to schema version 1.1
running script to convert from schema 1.0 to 1.1
extracting estimates
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
converting data
exporting into newestimates table
now exporting, this can take some time
New connection needed
connecting to openmolar_demo on localhost port 3306
updating stored schema version
New connection needed
connecting to openmolar_demo on localhost port 3306
making the db aware of it's schema version
disabling old clients
/usr/lib/python2.6/dist-packages/openmolar/dbtools/schema_version.py:70: Warning: Field 'time_stamp' doesn't have a default value
  cursor.execute(query, values)
updating stored schema version
upgrading to schema version 1.2
running script to convert from schema 1.1 to 1.2
updating schema to 1,2
created new table "forumread"
start_ix = 2
copied data from obsolete table OMforum
New connection needed
connecting to openmolar_demo on localhost port 3306
making the db aware of it's schema version
disabling old clients
updating stored schema version
upgrading to schema version 1.3
running script to convert from schema 1.2 to 1.3
creando tablas nuevas
alter table newfeeta...
alter table newfeeta...
alter table newfeeta...
alter table newfeeta...
alter table newfeeta...
alter table newfeeta...

CREATE TABLE if not...
actualizando configuraciones
update database settings...
making the db aware of it's schema version
disabling old clients
updating stored schema version
upgrading to schema version 1.4
running script to convert from schema 1.3 to 1.4
creando tablas nuevas

CREATE TABLE if not...

INSERT into feetabl...

CREATE TABLE if not...

INSERT into feetabl...

CREATE TABLE if not...

INSERT into feetabl...

...

Read more...

Revision history for this message
ediaz (ediaz-pk25) wrote :

If you want we can open to you a ssh shell to conect to this machine.. please send me a email.

regards!

Revision history for this message
Neil Wallace (rowinggolfer) wrote : Re: [Bug 518483] Re: 'ascii' codec can't decode byte 0xc3 in position 3: ordinal not in range(128)

On 23 May 2010 23:52, ediaz <email address hidden> wrote:

> If you want we can open to you a ssh shell to conect to this machine..
> please send me a email.
>
>
that would be a good idea.

Revision history for this message
ediaz (ediaz-pk25) wrote :

alex@alex-desktop:~$ echo $LANG
es_ES.UTF-8
alex@alex-desktop:~$ openmolar
trying to install your environment language es_ES.UTF-8
['/usr/bin/openmolar']
Could not resolve property : Strips1_1
New connection needed
connecting to openmolar_demo on localhost port 3306
checking schema version... loading fee and treatment logic tables
cashbook codes loaded sucessfully
Traceback (most recent call last):
  File "/usr/bin/openmolar", line 12, in <module>
    main.run()
  File "/usr/lib/python2.6/dist-packages/openmolar/main.py", line 373, in run
    main()
  File "/usr/lib/python2.6/dist-packages/openmolar/main.py", line 288, in main
    proceed()
  File "/usr/lib/python2.6/dist-packages/openmolar/main.py", line 105, in proceed
    maingui.main(my_app)
  File "/usr/lib/python2.6/dist-packages/openmolar/qt4gui/maingui.py", line 4084, in main
    mainWindow = openmolarGui(app) #-- app required for polite shutdown
  File "/usr/lib/python2.6/dist-packages/openmolar/qt4gui/maingui.py", line 144, in __init__
    self.addCustomWidgets()
  File "/usr/lib/python2.6/dist-packages/openmolar/qt4gui/maingui.py", line 298, in addCustomWidgets
    self.ui.toothPropsWidget = toothProps.tpWidget(self)
  File "/usr/lib/python2.6/dist-packages/openmolar/qt4gui/customwidgets/toothProps.py", line 315, in __init__
    self.populateComboBoxes()
  File "/usr/lib/python2.6/dist-packages/openmolar/qt4gui/customwidgets/toothProps.py", line 324, in populateComboBoxes
    vals.sort()
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 3: ordinal not in range(128)
alex@alex-desktop:~$

if you change the LANG to:
alex@alex-desktop:~$ echo $LANG
en_GB.UTF-8

start ok.

Changed in openmolar:
status: Fix Committed → Incomplete
Revision history for this message
ediaz (ediaz-pk25) wrote :

Hi, I think that the problem is the translation to spanish, because I download the developer version and the error don't happends, the aplication show Euro symbol but don't have any translation and start in english..

regards!

Revision history for this message
Neil Wallace (rowinggolfer) wrote :

hopefully this is fixed for all translations.
there is no £ symbol anywhere in the code, the only issue could be a rogue £ symbol in your feetable?

the application should start in Spanish if that is your locale, if this is not the case, please file a separate bug giving precise version numbers.

regards

Neil.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.