MX Package Installer has a difficulty writing file in /tmp  [Solved]

Help with the version of MX KDE officially released by the Development Team.
When asking for help, use Quick System Info from MX Tools. It will be properly formatted using the following steps.
1. Click on Quick System Info in MX Tools
2. Right click in your post and paste.
Message
Author
User avatar
Adrian
Developer
Posts: 9274
Joined: Wed Jul 12, 2006 1:42 am

Re: MX Package Installer has a difficulty writing file in /tmp

#21 Post by Adrian »

I seem to have a question that is supposed to pop up of mx_version >= 19 and of x86_64, doesn't this work?

Code: Select all

    // For 64-bit OS check if user wants AHS repo
    if (mx_version >= 19 && shell->getOut("uname -m", true) == "x86_64") {
        if (QMessageBox::Yes
            == QMessageBox::question(this, tr("Enabling AHS"), tr("Do you use AHS (Advanced Hardware Stack) repo?"))) {
            shell->runAsRoot(R"(sed -i '/^\s*#*\s*deb.*ahs\s*/s/^#*\s*//' /etc/apt/sources.list.d/mx.list)", true);
        }
    }

User avatar
fehlix
Developer
Posts: 12992
Joined: Wed Apr 11, 2018 5:09 pm

Re: MX Package Installer has a difficulty writing file in /tmp

#22 Post by fehlix »

Adrian wrote: Fri Oct 18, 2024 3:52 pm I seem to have a question that is supposed to pop up of mx_version >= 19 and of x86_64, doesn't this work?

Code: Select all

    // For 64-bit OS check if user wants AHS repo
    if (mx_version >= 19 && shell->getOut("uname -m", true) == "x86_64") {
        if (QMessageBox::Yes
            == QMessageBox::question(this, tr("Enabling AHS"), tr("Do you use AHS (Advanced Hardware Stack) repo?"))) {
            shell->runAsRoot(R"(sed -i '/^\s*#*\s*deb.*ahs\s*/s/^#*\s*//' /etc/apt/sources.list.d/mx.list)", true);
        }
    }
Not if I have an empty or otherwise completely messed up mx.list. So “reset” should reset and not rely on what crap is currently in mx.list
+++EDIT+++
Or, at least if _ahs_ was detected no need to ask further.

User avatar
Adrian
Developer
Posts: 9274
Joined: Wed Jul 12, 2006 1:42 am

Re: MX Package Installer has a difficulty writing file in /tmp

#23 Post by Adrian »

That's prompted after the list is restored, user is prompted to enable it or not... since the detection seem unreliable I think in the seldom cases people need to restore their sources they should be able to respond to a simple question if they want or not to enable AHS sources.

User avatar
fehlix
Developer
Posts: 12992
Joined: Wed Apr 11, 2018 5:09 pm

Re: MX Package Installer has a difficulty writing file in /tmp

#24 Post by fehlix »

Adrian wrote: Fri Oct 18, 2024 4:16 pm That's prompted after the list is restored, user is prompted to enable it or not... since the detection seem unreliable I think in the seldom cases people need to restore their sources they should be able to respond to a simple question if they want or not to enable AHS sources.
Not needed if ahs is detected.
Try it: Reset, and enable ahs. Now reset again. Why do you want bother people to ask whether they want ahs, if ahs is clearly detected already?
Also the detection of ahs is very reliable apt's print-uris will tell, and clearly lists identfied components like ahs as such, and no network required to query.

User avatar
Adrian
Developer
Posts: 9274
Joined: Wed Jul 12, 2006 1:42 am

Re: MX Package Installer has a difficulty writing file in /tmp

#25 Post by Adrian »

@fehlix I pushed the change to the repo https://github.com/MX-Linux/mx-repo-man ... 050358eb43

User avatar
fehlix
Developer
Posts: 12992
Joined: Wed Apr 11, 2018 5:09 pm

Re: MX Package Installer has a difficulty writing file in /tmp

#26 Post by fehlix »

Adrian wrote: Fri Oct 18, 2024 5:21 pm @fehlix I pushed the change to the repo https://github.com/MX-Linux/mx-repo-man ... 050358eb43
maybe, the ahs-check and enabling the ahs-deb line, would be better done on the extracted mx.list within the tempdir
- before the move - otherwise after moving orig mx.list the ahs-check always fails - and ahs would be kept disabled.

User avatar
Adrian
Developer
Posts: 9274
Joined: Wed Jul 12, 2006 1:42 am

Re: MX Package Installer has a difficulty writing file in /tmp

#27 Post by Adrian »

You just said:
the detection of ahs is very reliable apt's print-uris will tell, and clearly lists identfied components like ahs as such, and no network required to query.
Which is which...

User avatar
fehlix
Developer
Posts: 12992
Joined: Wed Apr 11, 2018 5:09 pm

Re: MX Package Installer has a difficulty writing file in /tmp

#28 Post by fehlix »

Adrian wrote: Fri Oct 18, 2024 9:12 pm You just said:
the detection of ahs is very reliable apt's print-uris will tell, and clearly lists identfied components like ahs as such, and no network required to query.
Which is which...
I'll have a look .. there is something else ... :snail:

User avatar
fehlix
Developer
Posts: 12992
Joined: Wed Apr 11, 2018 5:09 pm

Re: MX Package Installer has a difficulty writing file in /tmp

#29 Post by fehlix »

OK, now with some more "fixes" , so it will handle existing double slashes when changing repos (I know localize-repo is now fixed - but anyway) also only prompts for AHS repo, if not already detected it is in use or not, i.e. only in cases user removed mx.list or completely commented out all lines, or otherwise no mx-repo was enabled.
Send PR @Adrian

Post Reply

Return to “MX KDE Official Release”