1
0
mirror of https://codeberg.org/polarisfm/youtube-dl synced 2024-11-26 02:14:32 +01:00

[YoutubeDL] PEP 8

This commit is contained in:
Sergey M․ 2017-07-15 07:02:14 +07:00
parent ea3f20494f
commit 961ea474b6
No known key found for this signature in database
GPG Key ID: 2C393E0F18A9236D

View File

@ -20,13 +20,14 @@ import re
import shutil
import subprocess
import socket
import string
import sys
import time
import tokenize
import traceback
import random
from string import ascii_letters
from .compat import (
compat_basestring,
compat_cookiejar,
@ -679,7 +680,7 @@ class YoutubeDL(object):
# correspondingly that is not what we want since we need to keep
# '%%' intact for template dict substitution step. Working around
# with boundary-alike separator hack.
sep = ''.join([random.choice(string.ascii_letters) for _ in range(32)])
sep = ''.join([random.choice(ascii_letters) for _ in range(32)])
outtmpl = outtmpl.replace('%%', '%{0}%'.format(sep)).replace('$$', '${0}$'.format(sep))
# outtmpl should be expand_path'ed before template dict substitution