Clean up TODOs that are no longer relevant.

This commit is contained in:
Augie Fackler 2009-04-13 21:19:13 -05:00
parent d2873486ef
commit ae5062ada9
7 changed files with 2 additions and 15 deletions

View File

@ -216,8 +216,6 @@ class HgChangeReceiver(delta.Editor):
while paths_need_discovery:
p = paths_need_discovery.pop(0)
path_could_be_file = True
# TODO(augie) Figure out if you can use break here in a for loop, quick
# testing of that failed earlier.
ind = 0
while ind < len(paths_need_discovery) and not paths_need_discovery:
if op.startswith(p):
@ -633,7 +631,6 @@ class HgChangeReceiver(delta.Editor):
revlog.nullid)
if parents[0] in closed_revs and branch in self.branches_to_delete:
continue
# TODO this needs to be fixed with the new revmap
extra = util.build_extra(rev.revnum, branch,
open(self.uuid_file).read(),
self.subdir)

View File

@ -513,9 +513,10 @@ def svn_server_pull_rev(ui, svn, hg_editor, r):
for f in excluded:
files_touched.remove(f)
if parentctx.node() != node.nullid or files_touched:
# TODO(augie) remove this debug code? Or maybe it's sane to have it.
for f in files_touched:
if f:
# this is a case that really shouldn't ever happen, it means something
# is very wrong
assert f[0] != '/'
current_ctx = context.memctx(hg_editor.repo,
[parentctx.node(), revlog.nullid],

View File

@ -112,7 +112,6 @@ class Revision(object):
"""
def __init__(self, revnum, author, message, date, paths, strip_path=''):
self.revnum, self.author, self.message = revnum, author, message
# TODO parse this into a datetime
self.date = date
self.paths = {}
if paths:

View File

@ -24,7 +24,6 @@ class TestBasicRepoLayout(test_util.TestBase):
def test_fresh_fetch_two_revs(self):
repo = self._load_fixture_and_fetch('two_revs.svndump')
# TODO there must be a better way than repo[0] for this check
self.assertEqual(node.hex(repo[0].node()),
'434ed487136c1b47c1e8f952edb4dc5a8e6328df')
self.assertEqual(node.hex(repo['tip'].node()),
@ -33,7 +32,6 @@ class TestBasicRepoLayout(test_util.TestBase):
def test_branches(self):
repo = self._load_fixture_and_fetch('simple_branch.svndump')
# TODO there must be a better way than repo[0] for this check
self.assertEqual(node.hex(repo[0].node()),
'434ed487136c1b47c1e8f952edb4dc5a8e6328df')
self.assertEqual(node.hex(repo['tip'].node()),
@ -48,7 +46,6 @@ class TestBasicRepoLayout(test_util.TestBase):
def test_two_branches_with_heads(self):
repo = self._load_fixture_and_fetch('two_heads.svndump')
# TODO there must be a better way than repo[0] for this check
self.assertEqual(node.hex(repo[0].node()),
'434ed487136c1b47c1e8f952edb4dc5a8e6328df')
self.assertEqual(node.hex(repo['tip'].node()),
@ -63,14 +60,12 @@ class TestBasicRepoLayout(test_util.TestBase):
def test_many_special_cases_replay(self):
repo = self._load_fixture_and_fetch('many_special_cases.svndump')
# TODO there must be a better way than repo[0] for this check
self._many_special_cases_checks(repo)
def test_many_special_cases_diff(self):
repo = self._load_fixture_and_fetch('many_special_cases.svndump',
stupid=True)
# TODO there must be a better way than repo[0] for this check
self._many_special_cases_checks(repo)
def _many_special_cases_checks(self, repo):
@ -156,7 +151,6 @@ class TestStupidPull(test_util.TestBase):
self.repo_path,
self.wc_path,
True)
# TODO there must be a better way than repo[0] for this check
self.assertEqual(node.hex(repo[0].node()),
'434ed487136c1b47c1e8f952edb4dc5a8e6328df')
self.assertEqual(node.hex(repo['tip'].node()),

View File

@ -80,7 +80,6 @@ def outgoing_revisions(ui, repo, hg_editor, reverse_map, sourcerev):
return outgoing_rev_hashes
def build_extra(revnum, branch, uuid, subdir):
# TODO this needs to be fixed with the new revmap
extra = {}
branchpath = 'trunk'
if branch:

View File

@ -142,7 +142,6 @@ def rebase(ui, repo, extrafn=None, sourcerev=None, **opts):
if parent_rev == target_rev:
ui.status('Already up to date!\n')
return 0
# TODO this is really hacky, there must be a more direct way
return hgrebase.rebase(ui, repo, dest=node.hex(target_rev.node()),
base=node.hex(sourcerev),
extrafn=extrafn)

View File

@ -255,8 +255,6 @@ def pull(orig, ui, repo, source="default", *args, **opts):
passwd = opts.get('password', '')
svn = svnwrap.SubversionRepo(svn_url, user, passwd)
author_host = "@%s" % svn.uuid
# TODO these should be configurable again, but I'm torn on how.
# Maybe this should be configured in .hg/hgrc for each repo? Seems vaguely reasonable.
tag_locations = ['tags', ]
authors = opts.pop('svn_authors', None)
filemap = opts.pop('svn_filemap', None)