update some comments where plain cut+paste was confusing
This commit is contained in:
parent
031a88c25f
commit
0abcbe3339
|
@ -407,11 +407,13 @@ class Dirnode(GridTestMixin, unittest.TestCase,
|
||||||
def _start(res):
|
def _start(res):
|
||||||
self._start_timestamp = time.time()
|
self._start_timestamp = time.time()
|
||||||
d.addCallback(_start)
|
d.addCallback(_start)
|
||||||
# json-1.7.1 (as shipped on Ubuntu 'gutsy') rounds all
|
# a long time ago, we used simplejson-1.7.1 (as shipped on Ubuntu
|
||||||
# floats to hundredeths (it uses str(num) instead of repr(num)).
|
# 'gutsy'), which had a bug/misbehavior in which it would round
|
||||||
# json-1.7.3 does not have this bug. To prevent this bug
|
# all floats to hundredeths (it used str(num) instead of
|
||||||
# from causing the test to fail, stall for more than a few
|
# repr(num)). To prevent this bug from causing the test to fail,
|
||||||
# hundrededths of a second.
|
# we stall for more than a few hundrededths of a second here.
|
||||||
|
# simplejson-1.7.3 does not have this bug, and anyways we've
|
||||||
|
# moved on to stdlib "json" which doesn't have it either.
|
||||||
d.addCallback(self.stall, 0.1)
|
d.addCallback(self.stall, 0.1)
|
||||||
d.addCallback(lambda res: n.add_file(u"timestamps",
|
d.addCallback(lambda res: n.add_file(u"timestamps",
|
||||||
upload.Data("stamp me", convergence="some convergence string")))
|
upload.Data("stamp me", convergence="some convergence string")))
|
||||||
|
|
|
@ -556,7 +556,7 @@ class DirectoryNodeHandler(RenderMixin, rend.Page, ReplaceMeMixin):
|
||||||
raise
|
raise
|
||||||
cs = {}
|
cs = {}
|
||||||
for name, (file_or_dir, mddict) in children.iteritems():
|
for name, (file_or_dir, mddict) in children.iteritems():
|
||||||
name = unicode(name) # json-2.0.1 returns str *or* unicode
|
name = unicode(name) # json returns str *or* unicode
|
||||||
writecap = mddict.get('rw_uri')
|
writecap = mddict.get('rw_uri')
|
||||||
if writecap is not None:
|
if writecap is not None:
|
||||||
writecap = str(writecap)
|
writecap = str(writecap)
|
||||||
|
|
Loading…
Reference in New Issue