projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f8780e6
)
[compat] Simplify kwarg detection code
author
Philipp Hagemeister
<phihag@phihag.de>
Fri, 12 Dec 2014 11:42:33 +0000
(12:42 +0100)
committer
Philipp Hagemeister
<phihag@phihag.de>
Fri, 12 Dec 2014 11:42:35 +0000
(12:42 +0100)
This enables nuitka to compile youtube-dl.
youtube_dl/compat.py
patch
|
blob
|
history
diff --git
a/youtube_dl/compat.py
b/youtube_dl/compat.py
index f4a85443eda5086c004040183d1779a7059c0c2e..46d438846787e9a95ea8631c869f96341d4ccb9c 100644
(file)
--- a/
youtube_dl/compat.py
+++ b/
youtube_dl/compat.py
@@
-297,7
+297,9
@@
else:
# Old 2.6 and 2.7 releases require kwargs to be bytes
try:
- (lambda x: x)(**{'x': 0})
+ def _testfunc(x):
+ pass
+ _testfunc(**{'x': 0})
except TypeError:
def compat_kwargs(kwargs):
return dict((bytes(k), v) for k, v in kwargs.items())