mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
27 lines
669 B
Python
27 lines
669 B
Python
# -*- coding: utf-8 -*-
|
|
import datetime
|
|
from south.db import db
|
|
from south.v2 import DataMigration
|
|
from django.db import models
|
|
import redis
|
|
from django.conf import settings
|
|
|
|
class Migration(DataMigration):
|
|
|
|
def forwards(self, orm):
|
|
r = redis.Redis(connection_pool=settings.REDIS_POOL)
|
|
keys = r.keys("*:*:????????????????????????????????????????")
|
|
print " ---> %s keys" % len(keys)
|
|
for key in keys:
|
|
print "Deleting %s" % key
|
|
r.delete(key)
|
|
|
|
def backwards(self, orm):
|
|
"Write your backwards methods here."
|
|
|
|
models = {
|
|
|
|
}
|
|
|
|
complete_apps = ['social']
|
|
symmetrical = True
|