diff --git a/pym/update/profile.py b/pym/update/profile.py index edab59e..0a0da5b 100644 --- a/pym/update/profile.py +++ b/pym/update/profile.py @@ -241,10 +241,6 @@ class ProfileRepository(): return True return False - def is_like_local(self, local_path, rep_name): - - pass - @property def directory(self): """ diff --git a/pym/update/variables/update.py b/pym/update/variables/update.py index f5bed4e..f027647 100644 --- a/pym/update/variables/update.py +++ b/pym/update/variables/update.py @@ -942,7 +942,6 @@ class VariableClUpdateTemplatesLocate(Variable): def choice(self): descr = lambda x: self.descriptionMap.get(x, _("%s overlay templates" % x)) - a = self.get() return [(x, descr(x)) for x in self.get()] @@ -1093,17 +1092,17 @@ class VariableClUpdateProfileUrl(Variable): value = self.url_by_shortname(value) return self.normalize_url(value) - # def check(self, value): - # if not value: - # return True - # try: - # branch = self.Get(self.branch) - # self.Get(self.storage).get_profiles(value, branch) - # except GitError as e: - # raise VariableError(str(e)) - # if not self.Get(self.profiles_shortname): - # raise VariableError(_("Repository %s has no profiles") % - # value) + def check(self, value): + if not value: + return True + try: + branch = self.Get(self.branch) + self.Get(self.storage).get_profiles(value, branch) + except GitError as e: + raise VariableError(str(e)) + if not self.Get(self.profiles_shortname): + raise VariableError(_("Repository %s has no profiles") % + value) # def get(self): # try: @@ -1364,11 +1363,6 @@ class VariableClUpdateProfileSystem(Variable): return True if not dv.Get('os_linux_name'): raise VariableError("") - a = list(dv.Get('cl_update_rep_name')) - # if repo_name not in list(dv.Get('cl_update_rep_name')): - # raise VariableError( - # _("Overlay %s is not specified " - # "in cl_update_rep_name") % repo_name) except (DataVarsError, VariableError) as e: if str(e): message = ". " + str(e)