unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Re: bug#43879: Problem with graphical installer
       [not found]   ` <363c246d-90b2-1a8d-9b7b-6092e0836cc9@disroot.org>
@ 2020-10-31 12:04     ` Miguel Ángel Arruga Vivas
  2020-10-31 14:39       ` Marinus Savoritias
                         ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Miguel Ángel Arruga Vivas @ 2020-10-31 12:04 UTC (permalink / raw)
  To: Marinus Savoritias; +Cc: guix-devel, 43879


[-- Attachment #1.1: Type: text/plain, Size: 1543 bytes --]

Hi,

I CC the list, as we are currently on freeze, but this might require a
fix or at least a big explanation somewhere, my bad for not answering
soon enough. :-(

Marinus Savoritias <marinus.savoritias@disroot.org> writes:
> Hi,
>
> The steps that I followed were:
>
> 1. Use guided installation using full disk with graphical installer
>
> 2. I selected use entire disk and not a separate /home
>
> 3. It gave me the warning that its going to format the disk.

Testing this I think this warning may be the confusion source.  "All
data will be lost" doesn't include in this case the old ESP partition
(the one in /boot/efi) as that one is not removed when it exists.

> [...] I curiously found that the files from the previous installation
> of Gentoo were there. Even though the installer said that it formatted
> the disk.

To clarify this I propose the attached patch.

> I was using the default that the guided installation uses. I didn't
> change anything there.

Probably it's too late to add new options to that list, or a new
selection step when the partitioning is guided asking if esp should be
kept, as the tests have to be updated too.

> At that point as I said I formatted the disk separately to make sure
> it was properly formatted this time but the same thing happened.
>
> The only way I could work around the bug was by selecting the manual
> partitioning instead of guided in the graphical installer.

I'm throwing a guess here: did you format the root partition but not
/boot/efi the second time?

Happy hacking!
Miguel


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: list-formatted-partitions.patch --]
[-- Type: text/x-patch, Size: 2772 bytes --]

From 2c7f127fbf51de89500a6310d6d1ed130587d111 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?=
 <rosen644835@gmail.com>
Date: Sat, 31 Oct 2020 12:15:35 +0100
Subject: [PATCH] installer: Report to the user the formatted partitions.

* gnu/installer/newt/partitions.scm (define-module): Use (ice-9 format).
(draw-formatting-page): Add parameter partitions and provide the list of
formatted partitions to the user.
(run-partitioning-page): Provide user-partitions to draw-formatting-page.
---
 gnu/installer/newt/partition.scm | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/gnu/installer/newt/partition.scm b/gnu/installer/newt/partition.scm
index 3b891d693a..bb452a4925 100644
--- a/gnu/installer/newt/partition.scm
+++ b/gnu/installer/newt/partition.scm
@@ -25,6 +25,7 @@
   #:use-module (gnu installer newt page)
   #:use-module (gnu installer newt utils)
   #:use-module (guix i18n)
+  #:use-module (ice-9 format)
   #:use-module (ice-9 match)
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26)
@@ -56,11 +57,17 @@
                   #:button-callback-procedure button-exit-action)))
     (car result)))
 
-(define (draw-formatting-page)
+(define (draw-formatting-page partitions)
   "Draw a page asking for confirmation, and then indicating that partitions
 are being formatted."
-  (run-confirmation-page (G_ "We are about to format your hard disk.  All \
-its data will be lost.  Do you wish to continue?")
+  ;; TRANSLATORS: The ~{ and ~} format specifiers are used to iterate the list
+  ;; of device names of the user partitions that will be formatted.
+  (run-confirmation-page (format #f (G_ "We are about to write the configured \
+partition table to the disk and format the partitions listed below.  All its \
+data will be lost.  Do you wish to continue?~%~{ - ~a~%~}")
+                                 (map user-partition-file-name
+                                      (filter user-partition-need-formatting?
+                                              partitions)))
                          (G_ "Format disk?")
                          #:exit-button-procedure button-exit-action)
   (draw-info-page
@@ -773,7 +780,7 @@ by pressing the Exit button.~%~%")))
          (user-partitions (run-page non-install-devices))
          (user-partitions-with-pass (prompt-luks-passwords
                                      user-partitions))
-         (form (draw-formatting-page)))
+         (form (draw-formatting-page user-partitions)))
     ;; Make sure the disks are not in use before proceeding to formatting.
     (free-parted non-install-devices)
     (format-user-partitions user-partitions-with-pass)
-- 
2.28.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 658 bytes --]

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: bug#43879: Problem with graphical installer
  2020-10-31 12:04     ` bug#43879: Problem with graphical installer Miguel Ángel Arruga Vivas
@ 2020-10-31 14:39       ` Marinus Savoritias
  2020-10-31 14:41       ` Marinus Savoritias
                         ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Marinus Savoritias @ 2020-10-31 14:39 UTC (permalink / raw)
  To: Miguel Ángel Arruga Vivas, Marinus Savoritias; +Cc: guix-devel, 43879



On 10/31/20 1:04 PM, Miguel Ángel Arruga Vivas wrote:
> Hi,
> 
> I CC the list, as we are currently on freeze, but this might require a
> fix or at least a big explanation somewhere, my bad for not answering
> soon enough. :-(
> 
> Marinus Savoritias <marinus.savoritias@disroot.org> writes:
>> Hi,
>>
>> The steps that I followed were:
>>
>> 1. Use guided installation using full disk with graphical installer
>>
>> 2. I selected use entire disk and not a separate /home
>>
>> 3. It gave me the warning that its going to format the disk.
> 
> Testing this I think this warning may be the confusion source.  "All
> data will be lost" doesn't include in this case the old ESP partition
> (the one in /boot/efi) as that one is not removed when it exists.
> 
>> [...] I curiously found that the files from the previous installation
>> of Gentoo were there. Even though the installer said that it formatted
>> the disk.
> 
> To clarify this I propose the attached patch.

Agreed on this part. I think there should be a clarification.

> 
>> I was using the default that the guided installation uses. I didn't
>> change anything there.
> 
> Probably it's too late to add new options to that list, or a new
> selection step when the partitioning is guided asking if esp should be
> kept, as the tests have to be updated too.
> 
>> At that point as I said I formatted the disk separately to make sure
>> it was properly formatted this time but the same thing happened.
>>
>> The only way I could work around the bug was by selecting the manual
>> partitioning instead of guided in the graphical installer.
> 
> I'm throwing a guess here: did you format the root partition but not
> /boot/efi the second time?

If you mean the workaround I found in the end no. I deleted both of the 
partitions. I also deleted both partitions when I tried to do it 
separately from the installation.

That is what makes this bug so interesting. Because even if you delete 
both the partitions with parted. And then start the graphical guix 
installation it doesn't solve anything.

The only way to solve it is to format both the partitions manually with 
the installer.

Marinus

> 
> Happy hacking!
> Miguel
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug#43879: Problem with graphical installer
  2020-10-31 12:04     ` bug#43879: Problem with graphical installer Miguel Ángel Arruga Vivas
  2020-10-31 14:39       ` Marinus Savoritias
@ 2020-10-31 14:41       ` Marinus Savoritias
  2020-10-31 14:52       ` Marinus Savoritias
  2020-11-01 19:47       ` Mathieu Othacehe
  3 siblings, 0 replies; 6+ messages in thread
From: Marinus Savoritias @ 2020-10-31 14:41 UTC (permalink / raw)
  To: Miguel Ángel Arruga Vivas, Marinus Savoritias; +Cc: guix-devel, 43879



On 10/31/20 1:04 PM, Miguel Ángel Arruga Vivas wrote:
> Hi,
> 
> I CC the list, as we are currently on freeze, but this might require a
> fix or at least a big explanation somewhere, my bad for not answering
> soon enough. :-(
> 
> Marinus Savoritias <marinus.savoritias@disroot.org> writes:
>> Hi,
>>
>> The steps that I followed were:
>>
>> 1. Use guided installation using full disk with graphical installer
>>
>> 2. I selected use entire disk and not a separate /home
>>
>> 3. It gave me the warning that its going to format the disk.
> 
> Testing this I think this warning may be the confusion source.  "All
> data will be lost" doesn't include in this case the old ESP partition
> (the one in /boot/efi) as that one is not removed when it exists.
> 
>> [...] I curiously found that the files from the previous installation
>> of Gentoo were there. Even though the installer said that it formatted
>> the disk.
> 
> To clarify this I propose the attached patch.

Agreed on this part. I think there should be a clarification.

> 
>> I was using the default that the guided installation uses. I didn't
>> change anything there.
> 
> Probably it's too late to add new options to that list, or a new
> selection step when the partitioning is guided asking if esp should be
> kept, as the tests have to be updated too.
> 
>> At that point as I said I formatted the disk separately to make sure
>> it was properly formatted this time but the same thing happened.
>>
>> The only way I could work around the bug was by selecting the manual
>> partitioning instead of guided in the graphical installer.
> 
> I'm throwing a guess here: did you format the root partition but not
> /boot/efi the second time?

If you mean the workaround I found in the end no. I deleted both of the 
partitions. I also deleted both partitions when I tried to do it 
separately from the installation.

That is what makes this bug so interesting. Because even if you delete 
both the partitions with parted. And then start the graphical guix 
installation it doesn't solve anything.

The only way to solve it is to format both the partitions manually with 
the installer.

Marinus

> 
> Happy hacking!
> Miguel
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug#43879: Problem with graphical installer
  2020-10-31 12:04     ` bug#43879: Problem with graphical installer Miguel Ángel Arruga Vivas
  2020-10-31 14:39       ` Marinus Savoritias
  2020-10-31 14:41       ` Marinus Savoritias
@ 2020-10-31 14:52       ` Marinus Savoritias
  2020-11-01 19:47       ` Mathieu Othacehe
  3 siblings, 0 replies; 6+ messages in thread
From: Marinus Savoritias @ 2020-10-31 14:52 UTC (permalink / raw)
  To: Miguel Ángel Arruga Vivas, Marinus Savoritias; +Cc: guix-devel, 43879



On 10/31/20 1:04 PM, Miguel Ángel Arruga Vivas wrote:
> Hi,
> 
> I CC the list, as we are currently on freeze, but this might require a
> fix or at least a big explanation somewhere, my bad for not answering
> soon enough. :-(
> 
> Marinus Savoritias <marinus.savoritias@disroot.org> writes:
>> Hi,
>>
>> The steps that I followed were:
>>
>> 1. Use guided installation using full disk with graphical installer
>>
>> 2. I selected use entire disk and not a separate /home
>>
>> 3. It gave me the warning that its going to format the disk.
> 
> Testing this I think this warning may be the confusion source.  "All
> data will be lost" doesn't include in this case the old ESP partition
> (the one in /boot/efi) as that one is not removed when it exists.
> 
>> [...] I curiously found that the files from the previous installation
>> of Gentoo were there. Even though the installer said that it formatted
>> the disk.
> 
> To clarify this I propose the attached patch.

Agreed on this part. I think there should be a clarification.

> 
>> I was using the default that the guided installation uses. I didn't
>> change anything there.
> 
> Probably it's too late to add new options to that list, or a new
> selection step when the partitioning is guided asking if esp should be
> kept, as the tests have to be updated too.
> 
>> At that point as I said I formatted the disk separately to make sure
>> it was properly formatted this time but the same thing happened.
>>
>> The only way I could work around the bug was by selecting the manual
>> partitioning instead of guided in the graphical installer.
> 
> I'm throwing a guess here: did you format the root partition but not
> /boot/efi the second time?

If you mean the workaround I found in the end no. I deleted both of the 
partitions. I also deleted both partitions when I tried to do it 
separately from the installation.

That is what makes this bug so interesting. Because even if you delete 
both the partitions with parted. And then start the graphical guix 
installation it doesn't solve anything.

The only way to solve it is to format both the partitions manually with 
the installer.

Marinus

> 
> Happy hacking!
> Miguel
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug#43879: Problem with graphical installer
  2020-10-31 12:04     ` bug#43879: Problem with graphical installer Miguel Ángel Arruga Vivas
                         ` (2 preceding siblings ...)
  2020-10-31 14:52       ` Marinus Savoritias
@ 2020-11-01 19:47       ` Mathieu Othacehe
  2020-11-02 11:17         ` Miguel Ángel Arruga Vivas
  3 siblings, 1 reply; 6+ messages in thread
From: Mathieu Othacehe @ 2020-11-01 19:47 UTC (permalink / raw)
  To: Miguel Ángel Arruga Vivas; +Cc: guix-devel, Marinus Savoritias, 43879


Hello Miguel,

> +  ;; TRANSLATORS: The ~{ and ~} format specifiers are used to iterate the list
> +  ;; of device names of the user partitions that will be formatted.
> +  (run-confirmation-page (format #f (G_ "We are about to write the configured \
> +partition table to the disk and format the partitions listed below.  All its \
> +data will be lost.  Do you wish to continue?~%~{ - ~a~%~}")
> +                                 (map user-partition-file-name
> +                                      (filter user-partition-need-formatting?
> +                                              partitions)))

"All its data will be lost" refers to the hard drive. Maybe we should
say "Their data will be lost", referring to the partitions?

Otherwise, looks nice.

Thanks,

Mathieu


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug#43879: Problem with graphical installer
  2020-11-01 19:47       ` Mathieu Othacehe
@ 2020-11-02 11:17         ` Miguel Ángel Arruga Vivas
  0 siblings, 0 replies; 6+ messages in thread
From: Miguel Ángel Arruga Vivas @ 2020-11-02 11:17 UTC (permalink / raw)
  To: Mathieu Othacehe; +Cc: guix-devel, Marinus Savoritias, 43879

[-- Attachment #1: Type: text/plain, Size: 374 bytes --]

Hi Mathieu,

Mathieu Othacehe <othacehe@gnu.org> writes:
> "All its data will be lost" refers to the hard drive. Maybe we should
> say "Their data will be lost", referring to the partitions?

Thanks for the review, I overlooked that.

> Otherwise, looks nice.

Pushed as bc9e66f0feb25c77898222cfe5f3ef484dcee95e with the message
changed as suggested.

Happy hacking!
Miguel

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 658 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-11-02 11:17 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <8b7e2678-d9b0-698b-7e91-2b6145b3de7f@disroot.org>
     [not found] ` <87blgynuqr.fsf@gmail.com>
     [not found]   ` <363c246d-90b2-1a8d-9b7b-6092e0836cc9@disroot.org>
2020-10-31 12:04     ` bug#43879: Problem with graphical installer Miguel Ángel Arruga Vivas
2020-10-31 14:39       ` Marinus Savoritias
2020-10-31 14:41       ` Marinus Savoritias
2020-10-31 14:52       ` Marinus Savoritias
2020-11-01 19:47       ` Mathieu Othacehe
2020-11-02 11:17         ` Miguel Ángel Arruga Vivas

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).