[master 1/1] Handle New_Repository name collision source spoke (#1125322)

mulkieran installerbot-noreply at redhat.com
Fri Mar 6 14:58:17 UTC 2015


In reply to line 1215 of pyanaconda/ui/gui/spokes/source.py:

It looks like you could be a little more direct and substitute something like the below for lines 1199 -- 1215 (modulo your favorite syntax, of course).

matches = (name_re.match(r[REPO_NAME_COL]) for r in self._repoStore)
matches = [int(m[1]) for m in matches if m is not None]
highest_index = max(matches) if matches else 0
return name + ("_%d" % (highest_index + 1))

-- 
To view this comment on github, visit https://github.com/rhinstaller/anaconda/commit/9af9c255b8392f72c24f139eab96d713060c580c#commitcomment-10073134


More information about the anaconda-patches mailing list