From 0de5dbf311307136047eb17c30c3f766558ef417 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 6 Oct 2008 11:26:55 -0700 Subject: [PATCH] Fix #1136 (Error in .91 Fetch news) --- src/calibre/web/feeds/recipes/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/web/feeds/recipes/__init__.py b/src/calibre/web/feeds/recipes/__init__.py index 3dcb7cb09c..375996bf37 100644 --- a/src/calibre/web/feeds/recipes/__init__.py +++ b/src/calibre/web/feeds/recipes/__init__.py @@ -13,7 +13,7 @@ recipes = [ 'daily_telegraph', ] -import re, imp, inspect, time +import re, imp, inspect, time, os from calibre.web.feeds.news import BasicNewsRecipe, CustomIndexRecipe, AutomaticNewsRecipe from calibre.ebooks.lrf.web.profiles import DefaultProfile, FullContentProfile from calibre.ebooks.lrf.web import builtin_profiles @@ -56,7 +56,7 @@ def compile_recipe(src): @return: Recipe/Profile class or None, if no such class was found in C{src} ''' global _tdir, _crep - if _tdir is None: + if _tdir is None or not os.path.exists(_tdir): _tdir = path(PersistentTemporaryDirectory('_recipes')) temp = _tdir/('recipe%d.py'%_crep) _crep += 1