When I call wx.DateTimeFromDMY(1,0,1970),
the Python interpreter dies.
(Actually, this gets called by wx.masked.TimeCtrl)
Any suggestions? I'm running windows XP.
Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
···
****************************************************************
Personal firewall software may warn about the connection IDLE
makes to its subprocess using this computer's internal loopback
interface. This connection is not visible on any external
interface and no data is sent to or received from the Internet.
****************************************************************
IDLE 1.0
import wx
wx.__version__
'2.5.2.8'
wx.DateTimeFromDMY(1,0,1980)
<wx.DateTime: "01/01/80 00:00:00" at _98d43701_p_wxDateTime>
Well, I'd say this is an error in the error handling.
1,0,1970 is an invalid date, since there is no month 0
When I call wx.DateTimeFromDMY(1,0,1970),
the Python interpreter dies.
(Actually, this gets called by wx.masked.TimeCtrl)
Any suggestions? I'm running windows XP.
Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on
win32 Type "copyright", "credits" or "license()" for more information.
****************************************************************
Personal firewall software may warn about the connection IDLE
makes to its subprocess using this computer's internal loopback
interface. This connection is not visible on any external
interface and no data is sent to or received from the Internet.
****************************************************************
IDLE 1.0
>>> import wx
>>> wx.__version__
'2.5.2.8'
>>> wx.DateTimeFromDMY(1,0,1980)
<wx.DateTime: "01/01/80 00:00:00" at _98d43701_p_wxDateTime>
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
- --
UC
- --
Open Source Solutions 4U, LLC 2570 Fleetwood Drive
Phone: +1 650 872 2425 San Bruno, CA 94066
Cell: +1 650 302 2405 United States
Fax: +1 650 872 2417
···
On Monday 11 October 2004 05:57 pm, Tom McDermott wrote:
The problem call - wx.DateFromTimeDMY(1,0,1970) - is called, directly or indirectly, several times in the initialization of the wx.masked.TimeCtrl widget. This causes the TimeCtrl pane of the wxPython demo to die horribly, for example.
So the obvious solution - "don't do that them" - doesn't cut it.
Well, I'd say this is an error in the error handling.
1,0,1970 is an invalid date, since there is no month 0
0 is january, the first month
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
Tom McDermott le3zmev02-at-sneakemail.com |wxPython| wrote:
···
Ah-ha!
Really, I'm in GMT-10:
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
H:\>python
Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import time
>>> time.tzname
('AUS Eastern Standard Time', 'AUS Eastern Daylight Time')
>>> time.timezone
-36000
>>> import wx
>>> wx.DateTimeFromDMY(1,0,1970)
H:\>
But if I change to Pacific Time (GMT-8), it works:
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
H:\>python
Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import time
>>> time.tzname
('Pacific Standard Time', 'Pacific Daylight Time')
>>> import wx
>>> wx.DateTimeFromDMY(1,0,1970)
<wx.DateTime: "01/01/70 00:00:00" at _f0f53101_p_wxDateTime>
>>> time.timezone
28800
>>>
Robin Dunn robin-at-alldunn.com |wxPython| wrote:
Robin Dunn wrote:
Tom McDermott wrote:
When I call wx.DateTimeFromDMY(1,0,1970),
the Python interpreter dies.
(Actually, this gets called by wx.masked.TimeCtrl)
Any suggestions? I'm running windows XP.
Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
Works fine here. The only difference I can see is I'm using a newer version of Python.
Another thought. What is your timezone? What happens if you set it to another one? Perhaps this is a timezone related issue...
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org