#834 closed defect (duplicate)

clarify error message when upload fails due to insufficient servers of happiness

Reported by: zooko Owned by: kevan
Priority: major Milestone: 1.7.0
Component: code-peerselection Version: 1.5.0
Keywords: usability error Cc:
Launchpad Bug:

Description

allmydata.com user gar5 reported:

  allmydata.interfaces.NotEnoughSharesError: peer selection failed for <Tahoe2PeerSelector for upload .....>: placed 0 shares out of 10 total (10 homeless), sent 99 queries to 99 peers, 0 queries placed some shares, 99 placed none, got 0 errors

It seems like there are not enough shares.  Did it really send 99 queries?  If an error caused the operation to abort, why would I see "got 0 errors"?

Hopefully Kevan can think of a better way to express this situation and he can add it to his patch for #778. Maybe saying the number of queries which resulted in "I'm full so I can't hold your share" would help. Something like:

placed 0 shares out of 10 total (10 homeless), sent 99 queries to 99 peers, 0 queries placed some shares, 99 placed none (of which 99 placed none due to the server being full and 0 placed none due to an error)

Change History (7)

comment:1 Changed at 2009-11-21T03:05:27Z by kevan

Hm.

I agree that that message is confusing. I like your error message, too, and I think that it would fix the immediate problem.

Do you think that NotEnoughSharesError is informative enough, given the new behavior? I'm on the fence.

It seemed a lot easier to say NotEnoughSharesError and have it be meaningful with the shares_of_happiness behavior. In that case, you'd only raise the error if you failed to place enough shares on the grid. Now, NotEnoughSharesError can be raised not only for that, but because servers_of_happiness isn't satisfied, which doesn't immediately spring to my mind when I read NotEnoughSharesError. Maybe we could make something like UnhappyGridError -- something that gets raised where we raise NotEnoughSharesError in the peer selection process and elsewhere, where appropriate, when our upload is unsuccessful because servers_of_happiness isn't satisfied. This avoids overloading the meaning of the exception in other cases where it is used -- i.e., when downloading.

comment:2 Changed at 2009-11-21T03:08:24Z by kevan

I'll start working on the message part of this ticket, though.

comment:3 Changed at 2009-11-23T01:36:03Z by kevan

Okay, so I'm updating the patches for #778 with a few things related to this ticket:

  • Your error message is implemented.
  • I added a new exception: UploadHappinessError, which is raised in place of NotEnoughSharesError and NoSharesError during the upload process. (the latter two exceptions are still raised on downloads)
  • I added tests for this behavior.

Any thoughts?

comment:4 Changed at 2009-12-20T21:58:50Z by davidsarah

  • Keywords usability added

comment:5 Changed at 2010-01-16T01:06:50Z by davidsarah

  • Keywords error added

comment:6 Changed at 2010-02-02T03:12:24Z by davidsarah

  • Milestone changed from undecided to 1.7.0

comment:7 Changed at 2010-02-22T23:43:12Z by zooko

  • Resolution set to duplicate
  • Status changed from new to closed

This issue is now tracked by #778.

Note: See TracTickets for help on using tickets.