From d915b17498c213889bf1917a50b4c437ba7b879b Mon Sep 17 00:00:00 2001 From: Bastian Kleineidam Date: Sun, 10 Apr 2011 10:57:56 +0200 Subject: [PATCH] Prevent getting cached answers for version update check. --- linkcheck/updater.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/linkcheck/updater.py b/linkcheck/updater.py index 144465eb..01305c2e 100644 --- a/linkcheck/updater.py +++ b/linkcheck/updater.py @@ -56,7 +56,9 @@ def check_update (): def get_online_version (): """Download update info and parse it.""" - info, content = get_content(UPDATE_URL) + # prevent getting a cached answer + headers = {'Pragma': 'no-cache'} + info, content = get_content(UPDATE_URL, addheaders=headers) if info is None: None, _('could not download update information') version, url = None, None