diff --git a/pandora/clip/managers.py b/pandora/clip/managers.py index 729624d5..d69fb7c6 100644 --- a/pandora/clip/managers.py +++ b/pandora/clip/managers.py @@ -145,11 +145,7 @@ class ClipManager(Manager): keys = layer_ids + ['annotations', 'text', '*'] conditions = data.get('query', {}).get('conditions', []) conditions = flatten_conditions(conditions) - conditions_ = [] - for c in conditions: - if c.get('key') in keys and c not in conditions_: - conditions_.append(c) - conditions = conditions_ + conditions = list(filter(lambda c: c.get('key') in keys, conditions)) operator = data.get('query', {}).get('operator', '&') def parse(condition): diff --git a/pandora/clip/views.py b/pandora/clip/views.py index df2c9103..b37427c2 100644 --- a/pandora/clip/views.py +++ b/pandora/clip/views.py @@ -95,7 +95,7 @@ def findClips(request, data): if 'keys' in data: qs = order_query(qs, query['sort']) qs = qs[query['range'][0]:query['range'][1]] - #qs = qs.select_related('item') + qs = qs.select_related('item') layers = settings.CONFIG['layers'] entity_layer_ids = [k['id'] for k in layers if k['type'] == 'entity'] diff --git a/pandora/settings.py b/pandora/settings.py index 4f24c8fc..a8e59fed 100644 --- a/pandora/settings.py +++ b/pandora/settings.py @@ -170,13 +170,6 @@ LOGGING = { } } -CACHES = { - 'default': { - 'BACKEND': 'django.core.cache.backends.db.DatabaseCache', - 'LOCATION': 'cache', - } -} - AUTH_PROFILE_MODULE = 'user.UserProfile' AUTH_CHECK_USERNAME = True FFMPEG = 'ffmpeg' diff --git a/pandora/user/views.py b/pandora/user/views.py index d9639d70..17ce76da 100644 --- a/pandora/user/views.py +++ b/pandora/user/views.py @@ -785,7 +785,7 @@ def setUI(request, data): if isinstance(p, list): p = p[getPositionById(p, key)] else: - if key not in p or not isinstance(p[key], dict): + if key not in p: p[key] = {} p = p[key] if value == None and keys[0] in p: diff --git a/requirements.txt b/requirements.txt index a3b5c98f..a3936b66 100644 --- a/requirements.txt +++ b/requirements.txt @@ -10,4 +10,3 @@ requests==2.19.1 tornado<5 geoip2==2.9.0 youtube-dl -python-memcached diff --git a/static/js/filterForm.js b/static/js/filterForm.js index 2240876b..d6e85ca2 100644 --- a/static/js/filterForm.js +++ b/static/js/filterForm.js @@ -100,7 +100,7 @@ pandora.ui.filterForm = function(options) { id: list.id, query: that.$filter.options('value') }, function(result) { - pandora.$ui.editPanel && pandora.$ui.editPanel.updatePanel(); + editPanel.updatePanel && pandora.$ui.editPanel.updatePanel(); }); } else { pandora.$ui.list && pandora.$ui.list diff --git a/update.py b/update.py index e5a41f06..72ad1db8 100755 --- a/update.py +++ b/update.py @@ -249,9 +249,6 @@ if __name__ == "__main__": update_service('pandora-tasks') if old < 5975: run('./bin/pip', 'install', '-r', 'requirements.txt') - if old <= 6064: - run('./bin/pip', 'install', '-r', 'requirements.txt') - run('./pandora/manage.py', 'createcachetable') else: if len(sys.argv) == 1: release = get_release()