ajbmachon / guidata

Automatically exported from code.google.com/p/guidata
Other
0 stars 0 forks source link

wrong handling of None values in py3compat.py:to_text_string #34

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I had some problems with the automatic checking of text related DataItems in 
guidata 1.6.1. 

Looking inside the code I found that the function to_text_string returns 
u"None" for a None input value. This results in valid empty text fields with 
a missing default value.

To reproduce this problem, just create a dialogue 

   class Parameters(dt.DataSet):
        x_user_name = di.StringItem("Full Name", notempty=True)
        y_user_name = di.StringItem("Full Name", notempty=True, default="")

   Parameters().edit()

Original issue reported on code.google.com by rockspor...@gmail.com on 28 Aug 2013 at 2:44

GoogleCodeExporter commented 9 years ago
I can't reproduce this bug with the provided example on Windows 7 with Python 
2.7 or Python 3.3.

Original comment by pierre.raybaut on 29 Aug 2013 at 7:21