diff --git a/modules/allrecipes/pages.py b/modules/allrecipes/pages.py index 220e964022b20e467766d92a0e6b19b5a2ad80c1..c249043319e903a900162f043fcfbb8dbd0b817f 100644 --- a/modules/allrecipes/pages.py +++ b/modules/allrecipes/pages.py @@ -18,7 +18,7 @@ # along with weboob. If not, see . -from weboob.capabilities.recipe import Recipe, Comment +from weboob.capabilities.recipe import Recipe from weboob.capabilities.base import NotAvailable, NotLoaded from weboob.tools.browser import BasePage diff --git a/modules/cuisineaz/pages.py b/modules/cuisineaz/pages.py index beda21d2f9581cb1e13a87752968b3d33fe5b97d..1066feaf6ffdf1429480b48843fd3b1517255f5b 100644 --- a/modules/cuisineaz/pages.py +++ b/modules/cuisineaz/pages.py @@ -104,7 +104,12 @@ def get_recipe(self, id): cooking_time = int(l_cooktime[0].text.split()[0]) l_nbpers = self.parser.select(main, 'td#recipeQuantity span') if len(l_nbpers) > 0: - nb_person = int(l_nbpers[0].text.split()[0]) + rawnb = l_nbpers[0].text.split()[0] + if '/' in rawnb: + nbs = rawnb.split('/') + nb_person = (int(nbs[0]) + int(nbs[1])) / 2 + else: + nb_person = int(rawnb) ingredients = [] l_ing = self.parser.select(main, 'div#ingredients li.ingredient')