diff --git a/pandora/api/views.py b/pandora/api/views.py index aac4b3a8..3ceaaf0f 100644 --- a/pandora/api/views.py +++ b/pandora/api/views.py @@ -74,7 +74,6 @@ def init(request): else: response['data']['user'] = response['data']['site']['user'] response['data']['user']['ui'] = get_ui(json.loads(request.session.get('ui', '{}'))) - print request.session, request.session.keys() return render_to_json_response(response) actions.register(init) diff --git a/pandora/item/management/commands/update_external.py b/pandora/item/management/commands/update_external.py index d58dacf4..04070ebb 100644 --- a/pandora/item/management/commands/update_external.py +++ b/pandora/item/management/commands/update_external.py @@ -30,8 +30,9 @@ class Command(BaseCommand): chunk = options['all'] and 100 or options['items'] qs = models.Item.objects.exclude(itemId__startswith='0x') count = pos = qs.count() - while options['all'] and offset <= count or offset < options['items']: - for i in qs.order_by('modified')[offset:offset+chunk]: + while (options['all'] and offset <= count) or offset < options['items']: + print offset, pos, count + for i in qs.order_by('modified')[:chunk]: print pos, i.itemId, i.modified i.update_external() pos -= 1