From: Antonio Ospite Date: Fri, 15 Jan 2016 09:06:34 +0000 (+0100) Subject: smooth-dl.py: fix some pep8 issue X-Git-Url: https://git.ao2.it/smooth-dl.git/commitdiff_plain/00716d449533774cb4ab83bdae6d980848160484?ds=inline smooth-dl.py: fix some pep8 issue smooth-dl.py:38:1: E402 module level import not at top of file smooth-dl.py:39:1: E402 module level import not at top of file smooth-dl.py:40:1: E402 module level import not at top of file smooth-dl.py:41:1: E402 module level import not at top of file smooth-dl.py:42:1: E402 module level import not at top of file smooth-dl.py:43:1: E402 module level import not at top of file smooth-dl.py:44:1: E402 module level import not at top of file smooth-dl.py:45:1: E402 module level import not at top of file smooth-dl.py:46:1: E402 module level import not at top of file smooth-dl.py:57:5: E265 block comment should start with '# ' smooth-dl.py:96:1: E302 expected 2 blank lines, found 1 smooth-dl.py:111:1: E302 expected 2 blank lines, found 1 smooth-dl.py:173:25: E128 continuation line under-indented for visual indent smooth-dl.py:195:80: E501 line too long (84 > 79 characters) smooth-dl.py:246:9: E128 continuation line under-indented for visual indent smooth-dl.py:248:24: E711 comparison to None should be 'if cond is None:' smooth-dl.py:320:13: E127 continuation line over-indented for visual indent smooth-dl.py:333:9: E128 continuation line under-indented for visual indent smooth-dl.py:334:9: E128 continuation line under-indented for visual indent smooth-dl.py:335:9: E128 continuation line under-indented for visual indent smooth-dl.py:336:9: E128 continuation line under-indented for visual indent smooth-dl.py:338:23: E711 comparison to None should be 'if cond is None:' smooth-dl.py:343:21: E128 continuation line under-indented for visual indent smooth-dl.py:345:21: E128 continuation line under-indented for visual indent smooth-dl.py:351:17: E128 continuation line under-indented for visual indent smooth-dl.py:353:17: E128 continuation line under-indented for visual indent smooth-dl.py:355:9: E265 block comment should start with '# ' smooth-dl.py:358:17: E128 continuation line under-indented for visual indent smooth-dl.py:363:23: E128 continuation line under-indented for visual indent smooth-dl.py:364:23: E128 continuation line under-indented for visual indent smooth-dl.py:374:13: E128 continuation line under-indented for visual indent smooth-dl.py:426:17: E128 continuation line under-indented for visual indent smooth-dl.py:427:17: E128 continuation line under-indented for visual indent smooth-dl.py:437:13: E128 continuation line under-indented for visual indent smooth-dl.py:438:13: E128 continuation line under-indented for visual indent smooth-dl.py:439:13: E128 continuation line under-indented for visual indent --- diff --git a/smooth-dl.py b/smooth-dl.py index e3fa256..aa57c6e 100755 --- a/smooth-dl.py +++ b/smooth-dl.py @@ -30,11 +30,6 @@ # basically, write a proper implementation of manifest parsing and chunk # downloading - -__description = "Download videos served using Smooth Streaming technology" -__version = "0.x" -__author_info = "Written by Antonio Ospite http://ao2.it" - import os import re import sys @@ -45,6 +40,10 @@ import tempfile from optparse import OptionParser from urlparse import urlparse, urlunparse +__description = "Download videos served using Smooth Streaming technology" +__version = "0.x" +__author_info = "Written by Antonio Ospite http://ao2.it" + def get_chunk_data(data): @@ -54,7 +53,7 @@ def get_chunk_data(data): data_start = moof_size + 4 + len('mdat') data_size = mdat_size - 4 - len('mdat') - #print len(data[data_start:]), \ + # print len(data[data_start:]), \ # len(data[data_start:data_start + data_size]), data_size assert(len(data[data_start:]) == data_size) @@ -93,6 +92,7 @@ def write_wav_header(out_file, fmt, codec_private_data, data_len): out_file.write("data") out_file.write(struct.pack('