From c3c16247b70dfa51feb862270ed03197187ccfa5 Mon Sep 17 00:00:00 2001 From: Jiachen Yang Date: Mon, 11 May 2015 02:40:51 +0900 Subject: [PATCH] escape aurname in url --- nvchecker/source/aur.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nvchecker/source/aur.py b/nvchecker/source/aur.py index e850a32..1b4401b 100644 --- a/nvchecker/source/aur.py +++ b/nvchecker/source/aur.py @@ -3,6 +3,7 @@ import json import logging from tornado.httpclient import AsyncHTTPClient +from tornado.escape import url_escape AUR_URL = 'https://aur.archlinux.org/rpc.php?type=info&arg=' @@ -10,7 +11,7 @@ logger = logging.getLogger(__name__) def get_version(name, conf, callback): aurname = conf.get('aur') or name - url = AUR_URL + aurname + url = AUR_URL + url_escape(aurname) AsyncHTTPClient().fetch(url, partial(_aur_done, name, callback)) def _aur_done(name, callback, res):