mutable: revise a couple of error messages
at brian and zooko's suggestion, reword an error message encountered when multiple writers are racing to make overlapping changes to a directory
This commit is contained in:
parent
1869d7c29b
commit
d25d3065d1
|
@ -1221,13 +1221,13 @@ class Publish:
|
||||||
for oldplace in current_share_peers.get(shnum, []):
|
for oldplace in current_share_peers.get(shnum, []):
|
||||||
(peerid, seqnum, R) = oldplace
|
(peerid, seqnum, R) = oldplace
|
||||||
if seqnum >= self._new_seqnum:
|
if seqnum >= self._new_seqnum:
|
||||||
self.log("somebody has a newer sequence number than what we were uploading",
|
self.log("the sequence number has changed unexpectedly",
|
||||||
level=log.WEIRD)
|
level=log.WEIRD)
|
||||||
self.log(format="peerid=%(peerid)s, theirs=%(seqnum)d, mine=%(new_seqnum)d",
|
self.log(format="peerid=%(peerid)s, theirs=%(seqnum)d, mine=%(new_seqnum)d",
|
||||||
peerid=idlib.shortnodeid_b2a(peerid),
|
peerid=idlib.shortnodeid_b2a(peerid),
|
||||||
seqnum=seqnum,
|
seqnum=seqnum,
|
||||||
new_seqnum=self._new_seqnum)
|
new_seqnum=self._new_seqnum)
|
||||||
raise UncoordinatedWriteError("somebody has a newer sequence number than us")
|
raise UncoordinatedWriteError("the sequence number has changed unexpectedly")
|
||||||
target_map.add(shnum, oldplace)
|
target_map.add(shnum, oldplace)
|
||||||
shares_per_peer.add(peerid, shnum)
|
shares_per_peer.add(peerid, shnum)
|
||||||
if shnum in shares_needing_homes:
|
if shnum in shares_needing_homes:
|
||||||
|
|
Loading…
Reference in New Issue