Surface import failure error when importing via url
What does this MR do and why?
Current state
Scenario: User starts a URL import and while the repo is being imported (and the project is being created) the user navigated away.
If a project import has just failed but the user navigated away from the import in progress page, yet stays within the created project, they don't see a failure error.
Note: currently when a URL import is in progress, the project is still created whether the import of the Repository failed or not. So the user can still go to the /<just-created-project> page and settings. This is why we're making it more clear to the user that the repo import has failed.
The fix
Modifies the _importing_alert.haml to alert the user that an import has failed as long as they are within the <group>/<just-created-project> page
References
Screenshots or screen recordings
| Before | After |
|---|---|
|
|
|
|
How to set up and validate locally
- Navigate to one of your top level groups
- Click
create project=>Import project=>Repository by URL - You need a valid git repo url. Paste the https
.gitlink as the url, enter the correct user name but the wrong password - Type in a name for the project. Pick your group under
"Choose a group or namespace"and clickCreate project - You should see the Import in progress page for a time, then you are redirected as the import has failed.
- You should see a dismissible banner when the import failed notifying that the import failed.
- Navigate to the settings page for that project and the dismissable alert should be there as well
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Related to #195997



