Bugzilla – Bug 2652
User is not warned if they launch Audacity with a locked pluginsettings.cfg file
Last modified: 2021-02-02 10:19:49 UTC
The user is not warned if they launch Audacity with a locked pluginsettings.cfg file - all seems normal and launches OK. The problem conmes later when thy try to use any effect See P3 Bug #2143 >Effects fail silently (and with buildup of .tmp files) when >pluginsettings.cfg is locked It would be much better (for the user) to trap this at launch with a suitable error message. And that error message should have a "?" help button that links to the FAQ Error page: Effects fail silently (and with buildup of .tmp files) when pluginsettings.cfg is locked
Fix in: https://github.com/audacity/audacity/commit/21296b0 Seems to work fine, but I need Paul's with setting up an exception to exit Audacity a bit more gently.
Tested on W10 with Audacity 3.0.0 21296b0 I get no error/warning message when I launch with my pluginsettings.cfg file locked. Accordingly this gets REOPENED
Tested on W10 with Audacity 3.0.0 21296b0 This now works properly on Windows, with a) an message shown to the user b) help button in the message c) no launch of the effect while the problem remains d) fixing the problem by unlocking and then using the Retry button proceeds to launch the effect e) the Quit Audacity button - "does what it says on the tin"
OOPS - IGNORE Comment #3 - wrong bug thread - this is for Bug #2143
(In reply to Leland Lucius from comment #1) Tested on macOS 11.1 Big Sur with Audacity 3.0.0 21296b0 As on W10, I get no error/warning message when I launch with my pluginsettings.cfg file locked.
Fix in: https://github.com/audacity/audacity/commit/8e93cac
(In reply to Leland Lucius from comment #6) Testing on W10 with Audacity 3.0.0 accd177 On Windows this works fine
(In reply to Leland Lucius from comment #6) Testing on W10 with Audacity 3.0.0 accd177 On Mac the user is correctly blocked with the error message. But 1) keep error message open 2) unlock the file 3) click Retry 4) Observe: Audacity crashes But you can then relaunch Audacity OK But REOPENING this because of the crash
(In reply to Peter Sampson from comment #8) > (In reply to Leland Lucius from comment #6) > Testing on W10 with Audacity 3.0.0 accd177 > > On Mac the user is correctly blocked with the error message. > > But > 1) keep error message open > 2) unlock the file > 3) click Retry > 4) Observe: Audacity crashes > > But you can then relaunch Audacity OK > > But REOPENING this because of the crash Does the crash happen on W10 or Mac? Can you reproduce it? I can't seem to.
(In reply to Leland Lucius from comment #9) >Does the crash happen on W10 or Mac? Can you reproduce it? I can't seem to. OOPS sorry Cut&Paste error ... It happens on Mac, does not happen on Windows. It happens on Mac if i "Lock" the file not when I just make it "Read only"
(In reply to Peter Sampson from comment #10) > (In reply to Leland Lucius from comment #9) > >Does the crash happen on W10 or Mac? Can you reproduce it? I can't seem to. > > OOPS sorry Cut&Paste error ... > > It happens on Mac, does not happen on Windows. > > It happens on Mac if i "Lock" the file not when I just make it "Read only" How are you locking it? And it happens every time?
(In reply to Leland Lucius from comment #11) >How are you locking it? And it happens every time? 1) Finder 2) Right click on file 3) Select Get Info In the top block "General" (you may need to expand it)there is a checkbox for locked. This same crash also happens with a "Locked" and the unlocked pluginregistry.cfg It does not happen with a locked and then unlocked audacity.cfg file And yes, repeatable - every time.
(In reply to Peter Sampson from comment #12) > (In reply to Leland Lucius from comment #11) > >How are you locking it? And it happens every time? > > 1) Finder > 2) Right click on file > 3) Select Get Info > > In the top block "General" (you may need to expand it)there is a checkbox > for locked. > > This same crash also happens with a "Locked" and the unlocked > pluginregistry.cfg > > It does not happen with a locked and then unlocked audacity.cfg file > > And yes, repeatable - every time. That helped. I did get the crash here now. Researching
This is the same problem that was causing bug #1561, though the fix for that one may have been a little heavy handed and could have been fixed the same way as this one. This particular crash is happening because the OnInit() routine was split into two routines and the InitPart2() runs after OnInit() exits. When that happens the "Exist On Frame Delete" flag for the Mac is reset and whenever the first displayed dialog (the configuration file retry dialog in this case) is deleted, Audacity proceeds to exit. Simple fix committed in: https://github.com/audacity/audacity/commit/4f7affad3f73d9fed71fefa4169949a489a40b26
(In reply to Leland Lucius from comment #14) Testing on macOS 11.1 Big Sur with Audacity 3.0.0 392360a This Now works properly with locking via a) the "Locked" checkbox in Finder>Get Info, or b) setting the file "Read Only" in Finder>Get Info Also rechecked that this still works on W10 with this latest build - it does.