From e19936f58921288b8eea3b100960afd9863dea2e Mon Sep 17 00:00:00 2001 From: Marcin Koziej Date: Wed, 21 Dec 2011 09:28:43 +0100 Subject: [PATCH] python 2.5 does not support tuple.index() --- librarian/dcparser.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/librarian/dcparser.py b/librarian/dcparser.py index 245cf92..cf4a7b9 100644 --- a/librarian/dcparser.py +++ b/librarian/dcparser.py @@ -126,7 +126,7 @@ class Field(object): class DCInfo(type): def __new__(meta, classname, bases, class_dict): - fields = class_dict['FIELDS'] + fields = list(class_dict['FIELDS']) for base in bases[::-1]: if hasattr(base, 'FIELDS'): @@ -136,7 +136,7 @@ class DCInfo(type): except ValueError: fields = (field,) + fields - class_dict['FIELDS'] = fields + class_dict['FIELDS'] = tuple(fields) return super(DCInfo, meta).__new__(meta, classname, bases, class_dict) -- 2.20.1