2
2
import glob
3
3
import json
4
4
5
- from pythonforandroid .logger import (info , info_notify , Err_Style , Err_Fore )
5
+ from pythonforandroid .logger import (info , info_notify , warning , Err_Style , Err_Fore )
6
6
from pythonforandroid .util import current_directory , BuildInterruptingException
7
7
from shutil import rmtree
8
8
@@ -130,21 +130,7 @@ def get_distribution(cls, ctx, name=None, recipes=[],
130
130
# If there was a name match but we didn't already choose it,
131
131
# then the existing dist is incompatible with the requested
132
132
# configuration and the build cannot continue
133
- < << << << HEAD
134
133
if name_match_dist is not None and not allow_replace_dist :
135
- error ('Asked for dist with name {name} with recipes ({req_recipes}) and '
136
- 'NDK API {req_ndk_api}, but a dist '
137
- 'with this name already exists and has either incompatible recipes '
138
- '({dist_recipes}) or NDK API {dist_ndk_api}' .format (
139
- name = name ,
140
- req_ndk_api = ndk_api ,
141
- dist_ndk_api = name_match_dist .ndk_api ,
142
- req_recipes = ', ' .join (recipes ),
143
- dist_recipes = ', ' .join (name_match_dist .recipes )))
144
- error ('No compatible dist found, so exiting.' )
145
- exit (1 )
146
- == == == =
147
- if name_match_dist is not None :
148
134
raise BuildInterruptingException (
149
135
'Asked for dist with name {name} with recipes ({req_recipes}) and '
150
136
'NDK API {req_ndk_api}, but a dist '
@@ -155,7 +141,6 @@ def get_distribution(cls, ctx, name=None, recipes=[],
155
141
dist_ndk_api = name_match_dist .ndk_api ,
156
142
req_recipes = ', ' .join (recipes ),
157
143
dist_recipes = ', ' .join (name_match_dist .recipes )))
158
- > >> >> >> Replaced many exit (1 )s with exceptions
159
144
160
145
# If we got this far, we need to build a new dist
161
146
dist = Distribution (ctx )
0 commit comments