[gnue] r10239 - in trunk/gnue-common: . src/apps src/datasources
[email protected] Sun, 14 Nov 2010 12:36:34 -0600 (CST)
| Newsgroups | gmane.comp.cms.gnue.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: reinhard Date: 2010-11-14 12:36:34 -0600 (Sun, 14 Nov 2010) New Revision: 10239 Modified: trunk/gnue-common/ trunk/gnue-common/src/apps/GBaseApp.py trunk/gnue-common/src/datasources/GConditions.py Log: Run with Python 2.4 so nightlies can be generated on ash, removed some ch= eck for older Python versions. Property changes on: trunk/gnue-common ___________________________________________________________________ Name: bzr:revision-info - timestamp: 2010-11-14 14:00:53.595999956 +0100 committer: Reinhard M=C3=BCller <[email protected]> properties:=20 branch-nick: common + timestamp: 2010-11-14 19:35:32.653000116 +0100 committer: Reinhard M=C3=BCller <[email protected]> properties:=20 branch-nick: common Name: bzr:file-ids - setup.py 946@3a364389-8fce-0310-8f11-cc363fde16c7:trunk%2Fgnue-commo= n:setup.py src/base/setup.py 9934@3a364389-8fce-0310-8f11-cc363fde16c7:trunk%2Fgnue-= common:src%2Fbase%2Fsetup.py + src/apps/GBaseApp.py 1799@3a364389-8fce-0310-8f11-cc363fde16c7:trunk= %2Fgnue-common:src%2Fapps%2FGBaseApp.py src/datasources/GConditions.py 1265@3a364389-8fce-0310-8f11-cc363fde16c7:= trunk%2Fgnue-common:src%2Fdatasources%2FGConditions.py Name: bzr:revision-id:v4 - 3116 [email protected] 3117 [email protected] 3118 [email protected] 3119 [email protected] 3120 [email protected] 3121 [email protected] 3122 [email protected] 3123 [email protected] 3124 [email protected] 3125 [email protected] 3126 [email protected] 3127 [email protected] 3128 [email protected] 3129 [email protected] 3130 [email protected] 3131 [email protected] 3132 [email protected] 3133 [email protected] 3134 [email protected] 3135 [email protected] 3136 [email protected] 3137 [email protected] 3138 [email protected] 3139 [email protected] + 3116 [email protected] 3117 [email protected] 3118 [email protected] 3119 [email protected] 3120 [email protected] 3121 [email protected] 3122 [email protected] 3123 [email protected] 3124 [email protected] 3125 [email protected] 3126 [email protected] 3127 [email protected] 3128 [email protected] 3129 [email protected] 3130 [email protected] 3131 [email protected] 3132 [email protected] 3133 [email protected] 3134 [email protected] 3135 [email protected] 3136 [email protected] 3137 [email protected] 3138 [email protected] 3139 [email protected] 3140 [email protected] Name: bzr:text-parents - setup.py [email protected]= c src/base/setup.py [email protected]= wxixc + src/apps/GBaseApp.py [email protected]= bu24ep3nwxixc src/datasources/GConditions.py svn-v3-single1-dHJ1bmsvZ251ZS1jb21tb24.:3a= 364389-8fce-0310-8f11-cc363fde16c7:trunk%2Fgnue-common:9954 Modified: trunk/gnue-common/src/apps/GBaseApp.py =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- trunk/gnue-common/src/apps/GBaseApp.py 2010-11-14 18:34:58 UTC (rev 1= 0238) +++ trunk/gnue-common/src/apps/GBaseApp.py 2010-11-14 18:36:34 UTC (rev 1= 0239) @@ -229,7 +229,7 @@ os.path.join(paths.config, "connections.conf")) ] =20 # Python version check - if not hasattr(sys, 'hexversion') or sys.hexversion < 0x02050000= : + if not hasattr(sys, 'hexversion') or sys.hexversion < 0x02040000= : msg =3D u_("This application requires Python 2.5 or greater.= ") if hasattr(sys, 'version'): msg =3D u_("This application requires Python 2.5 or grea= ter. " Modified: trunk/gnue-common/src/datasources/GConditions.py =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- trunk/gnue-common/src/datasources/GConditions.py 2010-11-14 18:34:58 = UTC (rev 10238) +++ trunk/gnue-common/src/datasources/GConditions.py 2010-11-14 18:36:34 = UTC (rev 10239) @@ -27,8 +27,7 @@ import re import sys import datetime -if sys.hexversion >=3D 0x02040000: - import decimal +import decimal =20 from gnue.common.base import errors =20 @@ -1724,8 +1723,7 @@ newValue =3D 0L =20 # Boolean to Decimal - elif sys.hexversion >=3D 0x02040000 \ - and isinstance (chkValue, decimal.Decimal): + elif isinstance (chkValue, decimal.Decimal): if oldValue: newValue =3D decimal.Decimal(1) else: @@ -1754,8 +1752,7 @@ newValue =3D long (oldValue) =20 # Integer to Decimal - elif sys.hexversion >=3D 0x02040000 \ - and isinstance (chkValue, decimal.Decimal): + elif isinstance (chkValue, decimal.Decimal): newValue =3D decimal.Decimal (oldValue) else: raise ConversionRuleError, (oldValue, chkValue) @@ -1776,15 +1773,13 @@ newValue =3D float (oldValue) =20 # Long to Decimal - elif sys.hexversion >=3D 0x02040000 \ - and isinstance (chkValue, decimal.Decimal): + elif isinstance (chkValue, decimal.Decimal): newValue =3D decimal.Decimal (oldValue) else: raise ConversionRuleError, (oldValue, chkValue) =20 # Decimal conversion (Python 2.4 or later) - elif sys.hexversion >=3D 0x02040000 \ - and (isinstance (v1, decimal.Decimal) \ + elif (isinstance (v1, decimal.Decimal) \ or isinstance (v2, decimal.Decimal)): =20 if isinstance (v1, decimal.Decimal):