After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 700470 - setup -> summary -> setup -> summary transition broken
setup -> summary -> setup -> summary transition broken
Status: RESOLVED FIXED
Product: gnome-boxes
Classification: Applications
Component: wizard
3.8.x
Other Linux
: Normal normal
: 3.22
Assigned To: GNOME Boxes maintainer(s)
GNOME Boxes maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2013-05-16 16:29 UTC by Christophe Fergeau
Modified: 2016-03-31 13:22 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
installer: Don't emit 'user_wants_to_create' when disabling toggle (2.39 KB, patch)
2013-05-21 00:37 UTC, Zeeshan Ali
rejected Details | Review
wizard: Unref VMCreator instance on cancellation (791 bytes, patch)
2013-05-21 00:37 UTC, Zeeshan Ali
committed Details | Review
vm-creator: Make sure to clean up installer media (784 bytes, patch)
2013-05-21 00:37 UTC, Zeeshan Ali
committed Details | Review
Don't clean up on error to setup unattended install (1.34 KB, patch)
2013-05-21 00:38 UTC, Zeeshan Ali
rejected Details | Review
installer: Delay clean-up of temp. unattended files (1.54 KB, patch)
2013-05-21 00:38 UTC, Zeeshan Ali
rejected Details | Review
Don't jump to next page on express install untoggled (1.15 KB, patch)
2013-05-21 14:31 UTC, Zeeshan Ali
needs-work Details | Review
installer: Introducing clean_up_preparation_cache method (3.10 KB, patch)
2013-05-21 19:34 UTC, Zeeshan Ali
committed Details | Review
Don't jump to next page on express install untoggled (1.27 KB, patch)
2013-05-22 13:41 UTC, Zeeshan Ali
committed Details | Review

Description Christophe Fergeau 2013-05-16 16:29:31 UTC
When doing that, something fails and it goes out of the wizard.
Comment 1 Christophe Fergeau 2013-05-16 16:29:46 UTC
NB: doing an express install
Comment 2 Zeeshan Ali 2013-05-19 18:34:34 UTC
Working on this..
Comment 3 Zeeshan Ali 2013-05-21 00:37:49 UTC
Created attachment 244884 [details] [review]
installer: Don't emit 'user_wants_to_create' when disabling toggle

While its a good idea to signal the wizard that user wants to setup the VM
already and for wizard to automatically move to next page when user
toggle's off the express install but we must ensure we don't do this when
we toggle it off ourselves in case of errors from installer setup.

Without this patch, we end up launching the VM if installer setup fails
for some reason.
Comment 4 Zeeshan Ali 2013-05-21 00:37:53 UTC
Created attachment 244885 [details] [review]
wizard: Unref VMCreator instance on cancellation
Comment 5 Zeeshan Ali 2013-05-21 00:37:57 UTC
Created attachment 244886 [details] [review]
vm-creator: Make sure to clean up installer media
Comment 6 Zeeshan Ali 2013-05-21 00:38:01 UTC
Created attachment 244887 [details] [review]
Don't clean up on error to setup unattended install

The cleaned-up files still might be needed if user goes back in wizard
and still chooses to select unattended install.

We allow user to do that because he/she might manage to somehow work
around the problem by choosing different setup parameters.
Comment 7 Zeeshan Ali 2013-05-21 00:38:05 UTC
Created attachment 244888 [details] [review]
installer: Delay clean-up of temp. unattended files

Clean-up the unattended files in the method meant for cleanups, clean_up.
Now that we ensure that clean_up is always called, this patch is not
expected to cause unattended files to leak.

This combined with last few patches, fixes the issue of
setup->review->setup->review wizard transition, while keeping express
installation selected, resulting in an error.
Comment 8 Zeeshan Ali 2013-05-21 00:40:53 UTC
These patches are on top of patch in bug#700477. I'll rebase if needed.
Comment 9 Christophe Fergeau 2013-05-21 13:44:10 UTC
Review of attachment 244884 [details] [review]:

It would probably be better to never move to the next page when changing that switch, I've found that behaviour quite weird during my testing, and this would hopefully avoid the need for that ugly patch.
Comment 10 Zeeshan Ali 2013-05-21 13:49:45 UTC
Review of attachment 244884 [details] [review]:

I disagree. This behavior although hard on us is one of those simple small things that you could do to make your user really happy. However, I'd defer to UI designers here.
Comment 11 Christophe Fergeau 2013-05-21 13:53:36 UTC
Review of attachment 244884 [details] [review]:

While this might be nice if you know exactly what the switch does, moving to the next page as soon as it's changed makes things much harder to undo if you clicked on it by mistake, if you just wanted to see what happens when using it, ...
Comment 12 Zeeshan Ali 2013-05-21 14:14:59 UTC
Review of attachment 244884 [details] [review]:

OK so jimmac agrees with you so I'll revert the patch that introduce this change instead.
Comment 13 Zeeshan Ali 2013-05-21 14:31:01 UTC
Created attachment 244927 [details] [review]
Don't jump to next page on express install untoggled

While I thought this is a good idea, teuf and jimmac agree that this is
weird and unexpected behavior. Moreover, it complicates the code and
requires hacks to not mistrigger this.

Without this patch, we end up launching the VM if installer setup fails
for some reason.
Comment 14 Christophe Fergeau 2013-05-21 14:31:54 UTC
Review of attachment 244887 [details] [review]:

I'm not sold on that one, as prepare_for_installation() is able to recreates the files that are being cleaned up, calling clean_up() here should not be an issue.
Comment 15 Christophe Fergeau 2013-05-21 14:41:27 UTC
Review of attachment 244888 [details] [review]:

There's a big difference between these unattended_files/secondary_unattended_files and the rest of the data cleaned up by clean_up(). The unattended_files variables hold files that are needed to generate the actual unattended installation floppy/cd, so they are no longer needed once the unattended installation media have been successfully created/have started to be used.
On the other hand, clean_up() currently takes care of deleting the unattended installation media that need to be alive for the whole duration of the install.

If the current cleanup in prepare_for_installation is causing issues when going backward/forward in the wizard, then I'd prefer that we have a 2nd cleanup method that is called when the installation starts rather than when the installation ends, as the UnattendedFile classes may hold open some mounts, ...

If having the cleanup in prepare_for_installation does not cause issues, I'd rather it stays there so that we cleanup things as soon as we on longer need them.
Comment 16 Christophe Fergeau 2013-05-21 14:42:04 UTC
Review of attachment 244927 [details] [review]:

eia
Comment 17 Zeeshan Ali 2013-05-21 15:34:55 UTC
Review of attachment 244888 [details] [review]:

You got a point, especially with open mounts. I'll look into this..
Comment 18 Zeeshan Ali 2013-05-21 19:34:01 UTC
Created attachment 244989 [details] [review]
installer: Introducing clean_up_preparation_cache method

Add a separate method for cleaning up any cache created by 'prepare'
method that need to be kept around until VM is created and launched. This
is kept separate from 'clean_up' method as that is meant to clean data
that is needed until VM is completely installed. To ensure
clean_up_preparation_cache is always called, we also call it from
'clean_up' method.

This fixes the issue of setup->review->setup->review wizard transition,
while keeping express installation selected, resulting in an error.
Comment 19 Christophe Fergeau 2013-05-22 10:25:08 UTC
Review of attachment 244989 [details] [review]:

Can you add more details to the end of the log about what was causing the error? Looks good otherwise, thanks.
Comment 20 Christophe Fergeau 2013-05-22 12:52:19 UTC
Review of attachment 244927 [details] [review]:

Actually, NACK, this breaks with Windows which support unattended installs. This commit needs to revert part of 0461f032, removing the line is not enough.
Comment 21 Zeeshan Ali 2013-05-22 13:41:55 UTC
Created attachment 245038 [details] [review]
Don't jump to next page on express install untoggled

v2: Ensure sensitivity of 'Continue' button is still updated on toggling express install.
Comment 22 Zeeshan Ali 2013-05-22 15:02:09 UTC
Attachment 244885 [details] pushed as 92948bb - wizard: Unref VMCreator instance on cancellation
Attachment 244886 [details] pushed as 4270fca - vm-creator: Make sure to clean up installer media
Attachment 244989 [details] pushed as 533c916 - installer: Introducing clean_up_preparation_cache method
Attachment 245038 [details] pushed as 9d37899 - Don't jump to next page on express install untoggled