Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New username feature breaks Mobile install #25

Closed
Undef-a opened this issue Jul 10, 2023 · 5 comments · Fixed by #26
Closed

New username feature breaks Mobile install #25

Undef-a opened this issue Jul 10, 2023 · 5 comments · Fixed by #26

Comments

@Undef-a
Copy link

Undef-a commented Jul 10, 2023

On testing the new release while packing for Debian I noticed that the Mobile module now cannot get past the User Password screen. No matter whether the default username is left unchanged or replaced with a custom one the user cannot continue the install.

The following log line is seen on pressing "continue":

qrc:/user_pass.qml:138: TypeError: Cannot assign to read-only property "username"

Looking at the code, this is exactly what I'd expect.

  1. Q_PROPERTY( QString username READ username CONSTANT FINAL )
    is marked CONSTANT FINAL, so attempting to write it from QML will always fail.
  2. There is no setUsername( QString username ) function defined in https://github.com/calamares/calamares-extensions/blob/calamares/modules/mobile/Config.cpp
  3. There is no code in
    { { "sh", "-c", m_cmdPasswd + " " + m_username }, m_password + "\n" + m_password + "\n" },
    to deal with the new username. Even if 1 and 2 were working correctly the UsersJob would fail because the custom user does not exist on the system.

@nmschulte: Sorry I couldn't review the PR at the time. Are you interested in taking on the last bit to get username changing working? Otherwise I'll probably propose a patch to disable the feature.

@nmschulte
Copy link
Contributor

Thanks for the details; I'll look into this soon, yes.

@nmschulte
Copy link
Contributor

3. Even if 1 and 2 were working correctly the UsersJob would fail because the custom user does not exist on the system.

How is the user setup presently? I guess m_username doesn't control the created user, but identifies it so the password can be managed?

@Undef-a
Copy link
Author

Undef-a commented Jul 11, 2023 via email

@nmschulte
Copy link
Contributor

nmschulte commented Jul 11, 2023

I haven't tested #26, but it's where my mind's at currently about it ; I haven't checked any Mobian images yet either for initial content.

@saedmohmed
Copy link

#25 (comment)

algitbot pushed a commit to alpinelinux/aports that referenced this issue Aug 8, 2023
Backport patches to fix a regression from the 1.3.0 release that cause
the mobile installer to be stuck at the "new user" screen.

Related: calamares/calamares-extensions#26
Related: calamares/calamares-extensions#25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants