phylotastic / phylotastic-portal

Web tool (ruby on rails) providing access to phylotastic services for acquiring species trees.
https://github.com/phylotastic/phylotastic/wiki
1 stars 3 forks source link

Provide meaningful error messages #331

Open ducvan0212 opened 6 years ago

ducvan0212 commented 6 years ago

The services from Abu side return following error code:

screen shot 2018-08-16 at 8 46 40 am

@arlin would you please help me translate the error codes to meaningful messages to display in the portal?

ducvan0212 commented 6 years ago

For now, I added the error in portal. It looks like this (the second line)

screen shot 2018-08-16 at 9 45 17 am
epontell commented 6 years ago

The "Please try again in an hour" does not make sense - if the error is due to the size of the list, that will not change in one hour

ducvan0212 commented 6 years ago

@epontell @arlin I updated error messages.

screen shot 2018-08-16 at 4 21 49 pm

And for Chas's list, the error is

screen shot 2018-08-16 at 4 21 31 pm
arlin commented 6 years ago

@ducvan0212, the portal is an interactive web tool, so we want to provide users with guidance at the level of how they interact with the portal (by clicking buttons, selecting files, entering text, etc), not at the level of how the portal interacts internally with web services.

In the case of Chas's list, for instance, we might want to say "Getting a tree from this list failed because we could not find enough taxa in OpenTree's synthetic tree (at least 2 are needed). This usually means that your list includes taxa that are extinct or have an uncertain placement. Try another source of names."

arlin commented 6 years ago

@ducvan0212 could you please move this ticket into the In Progress column on the tracker?

arlin commented 6 years ago

@ducvan, I suggest the following error message for > 1000 names: "Your source has > 1000 names. To maintain performance, we currently do not process lists this large. Please find another source with fewer names."

arlin commented 6 years ago

With respect to the other errors in the table above, these should not be appearing in the portal. The behavior expected from a client is that it will validate commands before sending inoperable commands to services. Therefore we should never see low-level errors about missing arguments.

ducvan0212 commented 6 years ago

@DucVan, I suggest the following error message for > 1000 names: "Your source has > 1000 names. To maintain performance, we currently do not process lists this large. Please find another source with fewer names."

I updated the message.

screen shot 2018-08-17 at 3 18 13 pm
ducvan0212 commented 6 years ago

In the case of Chas's list, for instance, we might want to say "Getting a tree from this list failed because we could not find enough taxa in OpenTree's synthetic tree (at least 2 are needed). This usually means that your list includes taxa that are extinct or have an uncertain placement. Try another source of names."

Updated as well

screen shot 2018-08-17 at 3 21 55 pm
arlin commented 6 years ago

The first sentence is not necessary and introduces a distinction that the user may not understand.

arlin commented 6 years ago

In both cases, the first sentence is not necessary. Let's try to keep these messages as succinct as possible.

ducvan0212 commented 6 years ago

I removed the first sentence on both cases

screen shot 2018-08-17 at 3 23 42 pm screen shot 2018-08-17 at 3 23 53 pm