Django

Code

Changeset 3874

Show
Ignore:
Timestamp:
09/26/06 21:50:46 (2 years ago)
Author:
mtredinnick
Message:

Fixed Python 2.3 compatibility problem in [3872].

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/core/management.py

    r3872 r3874  
    868868                db_version = connection.get_server_version() 
    869869                if db_version < (5, 0, 3) and isinstance(f, (models.CharField, models.CommaSeparatedIntegerField, models.SlugField)) and f.maxlength > 255: 
    870                     e.add(opts, '"%s": %s cannot have a "maxlength" greater than 255 when you are using a version of MySQL prior to 5.0.3 (you are using %s).' % (f.name, f.__class__.__name__, '.'.join(str(n) for n in db_version[:3]))) 
     870                    e.add(opts, '"%s": %s cannot have a "maxlength" greater than 255 when you are using a version of MySQL prior to 5.0.3 (you are using %s).' % (f.name, f.__class__.__name__, '.'.join([str(n) for n in db_version[:3]]))) 
    871871 
    872872            # Check to see if the related field will clash with any