Community
Participate
Working Groups
Build ID: I20090313-0100 Steps To Reproduce: 1. Go to "Install new software" 2. Click the "Add..." button to add a new site. 3. Enter an invalid site location and confirm with "OK" The invalid location is rightaway added to Available Software Sites and triggers an error dialog. Possible solutions: 1.) Add a "Test connection" button, just as in the "Available Software Sites" preferences page. 2.) Automatically test the connection. Cancel adding the site, if no repository can be found there. 3.) Automatically test the connection. Give the user the option to either cancel or confirm adding the site. Solutions 2 or 3 are better from an UI point of view.
We do automatically test the connection (we try to load the repository after the add.) Depending on the network performance, the kind of site, etc., it may take some time for the failure to occur. When we do report a failure, we don't remove the repo. I like the idea of having the error notification dialog do something special. We could offer choices like - remove the repo - change the address (underneath we are removing and opening up the add dialog again) - ignore it for now (what happens today) I wouldn't want to put "Test Connection..." in any other workflows because this is the one place where we load a repository while the user waits (ie, it's not in a background job).
marking M7, if we are doing to do something for 3.5 it needs to be soon. I'm going to explore the path where we offer to let the user fix or delete the site
renaming bug to reflect what is planned. This also relates somewhat to bug 267887.
Fixed in HEAD >20090421. The original request was to always test a connection (load the repo) when the user adds it and let the user cancel the add if the repo is not valid. We intentionally don't do this (for history see bug 204184, bug 225062, bug 272066). So I turned this bug into focusing on this question. "Once we discover that a repository is invalid, what can we do about it to help the user?" This also relates to the question "what are the ways a repository can be invalid and does the user task change depending on the reason?" (discussed in bug 271681). What I have done is catch the case where the repository location is invalid (using the codes REPOSITORY_NOT_FOUND and REPOSITORY_INVALID_LOCATION). In these cases, I notify the user that the site could not be contacted and offer them a chance to correct the location. The correction is only offered once for each location, although if the user keeps trying invalid locations, they would get prompted for each new invalid location. The intention is to help correct simple typos. Today, the user has to remove the site and try again. Note that this correction will not be offered if the error is more specific (authentication failure, read failure, etc.). We only do this when we have a reasonable suspicion that the location itself is incorrect. If we see this prompt coming up when we know it's an alternate problem with the site, this would indicate a problem in the level of detail being surfaced in the transport exceptions.