oem-config-kde crashes when buttons clicked

Bug #1990196 reported by Erich Eickmeyer
22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
ubiquity (Ubuntu)
In Progress
High
Olivier Gayot
Jammy
Confirmed
High
Unassigned
Kinetic
Won't Fix
High
Unassigned
Lunar
Won't Fix
High
Olivier Gayot

Bug Description

During oem-config-kde mode, after user information has been entered, oem-config-kde keeps the "Back" and "Continue" buttons when these shouldn't appear at this stage. If these are clicked, the installer will crash, this is 100% reproducible:

Traceback (most recent call last):
 File" /usr/lib/ubiquity/ubiquity/frontend/kde_ui.py", line 1073, in on_next_clicked
  ui = self.pages[self.pagesindex].ui
IndexError:list index out of range

This is very bad from a user experience point of view as this can make the system unrecoverable without a complete reinstall, depending on where in the process the installer was when the user clicked on either of these buttons.

This problem exists in both Jammy and Kinetic. See attached screenshots and pictures.

Related branches

Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :
Revision history for this message
Heinrich Schuchardt (xypron) wrote (last edit ):

Hello Erich,

thanks for reporting the issue. I was able to reproduce it with https://cdimage.ubuntu.com/kubuntu/releases/22.04.1/release/kubuntu-22.04.1-desktop-amd64.iso and set the status to 'confirmed'.

Looking at the screenshot VirtualBox_ISOTest_19_09_2022_13_51_25.png it seems there is a layout problem with the upper and lower case letters being too close to each other. I did not see the same while in OEM mode. I guess this would deserve a separate bug report.

Best regards

Heinrich

Changed in ubiquity (Ubuntu Jammy):
status: New → Confirmed
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :

Heinrich,

That's correct, it would require a new report for the upper/lowercase letters. The problem there is really that the window is not conforming to the typical window size one would expect Ubiquity to conform to, which wasn't a problem in other releases i.e. Focal. However, this is a discussion for another bug report. :)

tags: added: foundations-todo
Changed in ubiquity (Ubuntu Jammy):
importance: Undecided → High
Changed in ubiquity (Ubuntu Kinetic):
importance: Undecided → High
Revision history for this message
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:
https://iso.qa.ubuntu.com/qatracker/reports/bugs/1990196

tags: added: iso-testing
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :

Marking as confirmed since it appeared on the iso testing tracker.

Changed in ubiquity (Ubuntu Kinetic):
status: New → Confirmed
Olivier Gayot (ogayot)
Changed in ubiquity (Ubuntu):
assignee: nobody → Olivier Gayot (ogayot)
Revision history for this message
Olivier Gayot (ogayot) wrote (last edit ):

EDIT: this comment make wrong assumptions /!\

After investigating, I found out that the KDE frontend for oem-config used to have a final screen with disabled Back and Continue buttons.

This was removed 12 years ago as part of:

https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/540929

I guess making an empty page with disabled Back and Continue buttons would be the way to go.

Revision history for this message
Olivier Gayot (ogayot) wrote :

Please ignore my last comment. After investigating more, I figured that in a normal install, the Back and Next buttons are completely hidden on the final screen.

The function responsible for hiding the Back & Next buttons (aka. the navigation buttons) is the function start_slideshow.

However, this function only hides the navigation if a slideshow exists - which is not true when running oem-config. When no slideshow exists, it simply shows an empty page but does not hide the navigation.

Olivier Gayot (ogayot)
Changed in ubiquity (Ubuntu):
status: Confirmed → In Progress
Olivier Gayot (ogayot)
tags: removed: foundations-todo
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote (last edit ):

Olivier, thanks for working on this! Targeting lunar since I'm sure this is in Lunar since it has no code difference from Kinetic as of my writing this.

There's a separate bug about enabling the slideshow for end users during the oem-config stage ( LP: #1842047 ), so perhaps there's some overlap here and we might be able to kill two birds with one stone.

Revision history for this message
Michael Mikowski (kfocus) wrote :

Oliver, per #15 I'd like to get this in place for 22.04 LTS production systems. If it's simple enough, can you point us on how to disable the Next and Back buttons on the last slide so we could at least patch it? We have done some work, but a bit of experienced direction would certainly be welcome, and we would of course report back here how well things may have worked.

Revision history for this message
Michael Mikowski (kfocus) wrote :

Bump Olivier (sorry of misspelling earlier!). Are there any pointers you'd suggest per comment #17?

Revision history for this message
Michael Mikowski (kfocus) wrote :

I've blocked moving to non-existent pages by trapping the exception and returning. Anyone see a problem with this? Testing on a VM shows the crash is averted.

In file /usr/lib/ubiquity/ubiquity/frontend/kde_ui.py:

1067 def on_next_clicked(self):
1068 """Callback to control the installation process between steps."""
1069 if not self.allowed_change_step or not self.allowed_go_forward:
1070 return
1071
1072 + # Ignore page where index does not exist.
1073 + try:
1074 + ui = self.pages[self.pagesindex].ui
1075 + except IndexError:
1076 + return
1077 -
1074 - ui = self.pages[self.pagesindex].ui
1078 self.allow_change_step(False)

Revision history for this message
Michael Mikowski (kfocus) wrote :

I just spotted the associated code change above. Will add this to the solution and test.

The catch code in comment #19 prevents the crash when next or continue buttons are pressed, but they are still present.

Revision history for this message
Michael Mikowski (kfocus) wrote :

Test steps taken:

1. Patched kde_ui.py. See patch kde_ui.py.diff.
2. Created two VMs, installed in OEM mode and then prepared-for-shipping and ran through user install on each. Used the same login names each time, and after sign-in, immediately prepared file system audits. See kde_ui.vm-file-audity.diff.

Results: Patched version no longer showed back or next buttons during user setup (good!). All fs diffs look trivial except /boot/initrd.img-5.19.0-32-generic is 543 bytes smaller in the patched system. This is likely normal variation.

Next steps:

Remove exception trap in on_next_clicked function to avoid potential side effects and test again. 2 attachments to follow.

Revision history for this message
Michael Mikowski (kfocus) wrote :
Revision history for this message
Michael Mikowski (kfocus) wrote :

File System Comparison attachment

Revision history for this message
Michael Mikowski (kfocus) wrote :

Olivier, your patch is now tested and in-use. I removed the exception trap from on_next_clicked to avoid any potential side effects. In the abundance of caution, I diffed file systems again, and there were no significant changes between the regular install and the installer with the patch. I hope that is useful. The diff was very similar to above. If you want a copy, let me know.

Revision history for this message
Utkarsh Gupta (utkarsh) wrote :

Ubuntu 22.10 (Kinetic Kudu) has reached end of life, so this bug will not be fixed for that specific release.

Changed in ubiquity (Ubuntu Kinetic):
status: Confirmed → Won't Fix
Revision history for this message
Brian Murray (brian-murray) wrote :

Ubuntu 23.04 (Lunar Lobster) has reached end of life, so this bug will not be fixed for that specific release.

Changed in ubiquity (Ubuntu Lunar):
status: In Progress → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.