Summarize data

Please, check my code!
I forgot to include some kind of readme.st. To test custom command:
python manage.py summarize [date YYYY-MM-DD] [--nodeletion]
If you pass no parameters it summarizes current date minus 15 days (single day and no a 15-days period)
Anyway we only use WEEK. I did it to give some semantic to the code. I'll
left WEEK = 1 for simplicity.

On Sat, Oct 4, 2014 at 1:22 AM, Fidel Ramos <notifications@github.com>
wrote:

> In okapiweb/management/commands/summarize.py:
>
> > +from urlparse import urlparse
> > +
> > +from pymongo import errors
> > +from pymongo import MongoClient
> > +
> > +from okapiweb.requestinfo.models import Datas
> > +from okapiweb import settings
> > +
> > +logging.basicConfig(format='%(asctime)s %(levelname)s %(message)s')
> > +logger = logging.getLogger(__name__)
> > +logger.setLevel(logging.INFO)
> > +
> > +
> > +class Command(BaseCommand):
> > +    TIMEOUT = 5000
> > +    YEAR, WEEK, WEEKDAY = range(0, 3)
>
> I don't think you should put more than one variable declaration in one
> line just to save lines:
>
> YEAR = 0WEEK = 1WEEKDAY = 2
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/redbeacon/okapi-web/pull/23/files#r18424493>.
>



-- 
Alejandro Garcia
Software Engineer at RedBeacon.com