Skip to content

Commit ac8df83

Browse files
committed
[crystax] Detect removed recipes for rebuild_updated_recipes
1 parent 7c1223e commit ac8df83

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

ci/rebuild_updated_recipes.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
from pythonforandroid.graph import get_recipe_order_and_bootstrap
2929
from pythonforandroid.toolchain import current_directory
3030
from pythonforandroid.util import BuildInterruptingException
31+
from pythonforandroid.recipe import Recipe
3132
from ci.constants import TargetPython, CORE_RECIPES, BROKEN_RECIPES
3233

3334

@@ -78,6 +79,18 @@ def main():
7879
recipes -= CORE_RECIPES
7980
logger.info('recipes to build: {}'.format(recipes))
8081
context = Context()
82+
83+
# removing the deleted recipes for the given target (if any)
84+
for recipe_name in recipes.copy():
85+
try:
86+
Recipe.get_recipe(recipe_name, context)
87+
except ValueError:
88+
# recipe doesn't exist, so probably we remove it
89+
recipes.remove(recipe_name)
90+
logger.warning(
91+
'removed {} from recipes because deleted'.format(recipe_name)
92+
)
93+
8194
# forces the default target
8295
recipes_and_target = recipes | set([target_python.name])
8396
try:

0 commit comments

Comments
 (0)