projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bf0ff93
)
[utils] Apply 2.6 xpath craziness
author
Philipp Hagemeister
<phihag@phihag.de>
Sat, 13 Sep 2014 07:11:14 +0000
(09:11 +0200)
committer
Philipp Hagemeister
<phihag@phihag.de>
Sat, 13 Sep 2014 07:11:14 +0000
(09:11 +0200)
This fixes ARD on 2.6
youtube_dl/utils.py
patch
|
blob
|
history
diff --git
a/youtube_dl/utils.py
b/youtube_dl/utils.py
index 7536b3b364c5718380f9481fc5c5add87cc775a8..24778807813ec0b6303b6daf849c047b950b98e3 100644
(file)
--- a/
youtube_dl/utils.py
+++ b/
youtube_dl/utils.py
@@
-305,6
+305,9
@@
def xpath_with_ns(path, ns_map):
def xpath_text(node, xpath, name=None, fatal=False):
+ if sys.version_info < (2, 7): # Crazy 2.6
+ xpath = xpath.encode('ascii')
+
n = node.find(xpath)
if n is None:
if fatal: