From eef7c1dc7d5f9d6f6033eae029565fefe82db28e Mon Sep 17 00:00:00 2001 From: Tomasz Zielinski Date: Mon, 9 Jan 2012 22:28:29 +0100 Subject: Migrations fix to avoid buggy unicode keyword parameters --- askbot/migrations/0092_postize_vote_and_activity.py | 2 +- askbot/migrations/0095_postize_award_and_repute.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/askbot/migrations/0092_postize_vote_and_activity.py b/askbot/migrations/0092_postize_vote_and_activity.py index a4cf3e4e..556ef18a 100644 --- a/askbot/migrations/0092_postize_vote_and_activity.py +++ b/askbot/migrations/0092_postize_vote_and_activity.py @@ -47,7 +47,7 @@ class Migration(DataMigration): ct = a.content_type if ct.app_label == 'askbot' and ct.model in ('question', 'answer', 'comment'): a.content_type = ct_post - a.object_id = orm.Post.objects.get(**{'self_%s__id' % ct.model: a.object_id}).id + a.object_id = orm.Post.objects.get(**{'self_%s__id' % str(ct.model): a.object_id}).id save = True if a.question: diff --git a/askbot/migrations/0095_postize_award_and_repute.py b/askbot/migrations/0095_postize_award_and_repute.py index bca50617..0071199c 100644 --- a/askbot/migrations/0095_postize_award_and_repute.py +++ b/askbot/migrations/0095_postize_award_and_repute.py @@ -15,7 +15,7 @@ class Migration(DataMigration): ct = aw.content_type if ct.app_label == 'askbot' and ct.model in ('question', 'answer', 'comment'): aw.content_type = ct_post - aw.object_id = orm.Post.objects.get(**{'self_%s__id' % ct.model: aw.object_id}).id + aw.object_id = orm.Post.objects.get(**{'self_%s__id' % str(ct.model): aw.object_id}).id aw.save() ### -- cgit v1.2.3-1-g7c22