When trying to create an instance, show an error message if no flavors exist
Overview
As issue #950 (closed) states, trying to create a flavor in a project with no flavors assigned results in a perpetual loading spinner. This is because the flavors in a project are modeled as a list, which is empty initially. It is presumed that an empty list represents uninitialized flavors. Thus, the app cannot distinguish between a project with uninitialized flavors and a project where flavors have been initialized, but none are available.
With changes in this MR, the flavors in a project are now modeled using RemoteDataPlusPlus
, so it is possible to distinguish between uninitialized flavors and a project with no flavors. We use this to display an error message in the case where no flavors are available.
How to Test
Attempt to create an instance in a project with no flavors assigned, or where are existing flavors are disallowed. @cmart created test-flavorless-project-for-exo-issue-950
for this purpose.
Screenshots
Without changes in this MR, attempting to create an instance in a project with no flavors results in a perpetual loading spinner.
With changes in this MR, attempting to create an instance in a project with no flavors results in an error message.
Closes #950 (closed)