Audacity Bug Summary
••• Introduction •••
••• Keywords •••
    Audacity 3.0.3 development began 19th April 2021

Audacity Bugzilla



Bug 2084 - Enh: Auto-select behaviour changed from previous version and not documented.
Enh: Auto-select behaviour changed from previous version and not documented.
Status: RESOLVED FIXED
Product: Audacity
Classification: Unclassified
Component: Application Core
2.3.2
Per OS All
: P4 Enhancement
Assigned To: Default Assignee for New Bugs
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-03-26 05:45 UTC by Peter Sampson
Modified: 2019-03-31 16:09 UTC (History)
7 users (show)

See Also:
Steps To Reproduce:
Use Case-1 1) check "Auto-select, if selection required" on, in Tracks Behaviors prefs 2) get two tracks 3) make a selection in one of the tracks 4) clear the selection by clicking in the dark gray background 5) apply EQ (or any other effect) 6) observe that the effect is applied to the selection that was made in step 2 and to both tracks (and not the whole project) -------------------------------- Use Case-2 1) check "Auto-select, if selection required" on, in Tracks Behaviors prefs 2) get two tracks 3) make a selection in one of the tracks 4) clear the selection by clicking a point selection in one of the tracks 5) apply EQ (or any other effect) 6) observe that the effect is applied to the whole track that was clicked in at step 4 (and not the whole project)
Release Note:
First Git SHA:
Group: ---
Workaround:
Closed: 2019-03-31 00:00:00
petersampsonaudacity: Regression+
petersampsonaudacity: Test‑OK‑Win+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Sampson 2019-03-26 05:45:52 UTC
This is a regression on 2.1.3 

The preferences setting for "Auto-select, if selection required" is not honored if the user makes a selection after a selection has been made and subsequently cleares that selection and then appiles any effect - what happen is that Audacity works the effect on the previously cleared selection.

If you just create or imprt a track and then apply an effect with "Auto-select" on
having made no slections at all, the the select-all is honored properly.

This was originally reported on the Forum:
https://forum.audacityteam.org/viewtopic.php?f=63&t=104324&p=366667

------------------------------------------------------

We have had this bug for a 15 months now - and this is the first report of this issue.  So I suspect that very few users are using the "Select-all" setting. 

Accordingly, my solution to this problem would be to simply remove the setting for "Auto-select, if selection required" from preferences.  

Note that the chief proponent of retaining "Auto select ..." is no longer with us (RIP Gale) - so there may be little or no opposition to this approach.  Many of us regard auto-select as dangerous anyway.

For any user who may subsequently complain the workarond is simple "use Ctrl+A"
Comment 1 Cliff Scott 2019-03-26 08:20:20 UTC
I disagree with Peter regarding removing the preference. I personally use it quite a bit. Just not in the way that caused the bug. It's very handy for things like Normalize, Limiter, Compressor, etc. Those effects that one normally use on the whole track.
Comment 2 Steve Daulton 2019-03-26 08:35:38 UTC
I also think we should retain the feature for now. I rarely use it myself because of the silly way that it selects all tracks of all types, but I probably would use the feature if some options were added (such as "Select all audio", or an "intelligent" mode that selects all tracks of the type that has focus).
Comment 3 Peter Sampson 2019-03-26 10:37:01 UTC
I think I can see what may be causing Use Case-1

The Manual states
>Auto-select, if selection required: If you select no audio before applying an
>effect, the effect will be automatically applied to all audio in all tracks. 
>This also applies to other menu items requiring an audio selection to be made.
> 
>If you have a Time selection, made by using the Selection Toolbar, but with no
>audio tracks selected, then the Auto-select will operate on just that time 
>range in all audio tracks.

At Step-4 in Use Case-1 when the selection in the track is cleared by clicking in the dark gray background the selection is visibly removed for the waveforms - BUT is retained as a Time selection in the Timeline.  Thus Audacity is obeying the second part of the Manual entry.
Comment 4 Peter Sampson 2019-03-26 12:04:44 UTC
Reducing to P2

The Wiki states:
>"P1 bugs prevent a new release. These will include most reproducible crashes, 
>most things that cause data loss and most regressions."

so it only says "most" ...

>"P1's would affect large numbers of users, if released."

so one user in a year and half doesn't exactly evidence a "large numbers of users" affected.
Comment 5 Steve Daulton 2019-03-27 07:23:15 UTC
(In reply to Peter Sampson from comment #4)
I've lowered this to P4 because, having gone through the "steps to reproduce", I think it is a "feature" rather than a "bug", thus any complaint about the behaviour is an "enhancement" rather than a "fix". I am tempted to close this as "not a bug", though I think that it would be useful to improve this "auto select" functionality.

Note that a "selection" has two parts:
a) A "selection region"
b) A "list of tracks"

Either part may be empty - that is, 
1) a "selection" may have a time region but no selected tracks.
In this case the selection is visible only in the Timeline and Selection Toolbar.
or
2) may have a list of tracks but no time region.
In this case, the selection is visible only in the colour of the track control panels.

The current behaviour appears to retain either part, if it exists.

The old behaviour would discard an exiting selection unless both parts exist. I would argue that this is a bug as it is discarding the user's actions.

---

Use Case-1
1) check "Auto-select, if selection required" on, in Tracks Behaviors prefs
2) get two tracks
3) make a selection in one of the tracks
4) clear the selection by clicking in the dark gray background

Note: Step 4 does NOT clear the selected region, it only clears the selection from the current track.

5) apply EQ (or any other effect)
6) observe that the effect is applied to the selection that was made in step 2 and to both tracks (and not the whole project)

Yes, the existing selection ("region") was retained. This is a "more intelligent" behaviour than blindly discarding the existing selection.

---

Use Case-2
1) check "Auto-select, if selection required" on, in Tracks Behaviors prefs
2) get two tracks
3) make a selection in one of the tracks
4) clear the selection by clicking a point selection in one of the tracks

The original selection has been removed, but now we have a "track selection" with no "time selection".

5) apply EQ (or any other effect)
6) observe that the effect is applied to the whole track that was clicked in at step 4 (and not the whole project)

Yes, the existing selection ("track selection") created in step 4 was retained.
Comment 7 Cliff Scott 2019-03-27 15:18:34 UTC
Tested on MacOS 10.13.6 with build b8aea7 and in both cases the whole project is selected and the effect is applied to all as described in the manual. 

To force it to apply to less than the whole project the effect dialog has to be canceled and the desired track(s) selected then the effect applied.
Comment 8 Steve Daulton 2019-03-27 16:47:41 UTC
(In reply to James Crook from comment #6)
While this is, imo, an improvement, in cases where non-audio tracks are present, it can produce some unexpected and undesirable results.

From my discussion with Peter, the intended behaviour that we would like to see is exactly:

"When an audio effect or analyzer  (not generator or tool) is launched and there is no selected audio, all audio in the current project will be selected."

I shall reopen this bug for now, with the intention of a speedy resolution.
Comment 9 Peter Sampson 2019-03-28 06:26:38 UTC
Given that the bug title has changed to be a documentation issue, I have today updated the text in the Manual to describe current 2.3.2 behavior.
https://alphamanual.audacityteam.org/man/Tracks_Behaviors_Preferences#Behaviors

The image remains to be updated for the revised descriptor for "Select all …"
but that is done later via James' magicke spelles - I have set a P1 in the Manual for that.


There remains a residual under discussion where, ideally, we would like just all the audio to be selected by the use of the "Select all.." preference.
Comment 10 James Crook 2019-03-29 18:33:43 UTC
(for the residual enh request, that it should only select audio)

DEVEL - FIX MADE 
https://github.com/audacity/audacity/commit/09dab612fed1110905b7ae6d7454b2e4d7ea47b9
Comment 11 Cliff Scott 2019-03-29 23:32:23 UTC
Tested with build 09dab6 on MacOS 10.13.6 and only the audio is selected as expected. The label track is ignored.
Comment 12 Peter Sampson 2019-03-30 05:12:01 UTC
Testing on W10 with audacity-2.3.2-alpha-205-09dab612fed1110905b7ae6d7454b2e4d7ea47b9

This now works fine if you have a mix of multiple tracks and multiple label tracks - which is fine for 99% of our users base - but once you throw a Note/MIDI track into the mix things go awry.

A) Use-Case-1
1) turn on "Select all audio..."
2) get an audio track, a Note track and a label track
3) ensure no selection is present
4) apply an effect (Amplify say)
5) note that not only is the audio track selected but the MIDI track is also (wrongly)selected - the Label track is (correctly not selected)
6) the Amplify proceeeds, but acts only on the audio track (MIDI tracks can't be amplified anyway)

Step 5 is wrong becase Note/MIDI tracks are *not* audio tracks


B) Use-Case-2
1) turn on "Select all audio..."
2) get an audio track, a Note track and a label track
3) select just the Note/MIDI track
4) apply an effect (Amplify say)
5) note that not only is the Note track selected but the audio track is also (wrongly) selected - the Label track is (correctly not selected)
6) the Amplify proceeeds but acts only on the audio track (MIDI tracks can't be amplified anyway)

Step 5 is wrong here as the user already has a selection present, but Audacity fails to recognize the selection and proceeds with a "Select all audio..."


There is an addiotional fringe case

C) Use-Case-3
1) turn on "Select all audio..."
2) get an audio track, a Note track and a label track
3) select just the Label track
4) apply an effect (Amplify say)
5) note that not only is the Label track selected but the audio track is also (wrongly - or mabe correctly?) selected - the Note track is also (incorrectly) selected)
6) the Amplify proceeds but acts only on the audio track (MIDI tracks can't be amplified anyway)

Step 5 is wrong here as the user already has a selection present, a label track - so in this case it might be judged "correct" ("designed") behavior for the audio track to be selected and acted upon - but the Note track should *not* form part of this selection as it is not audio (but this bit is Use Case-1).

However it could be argued that the auto-select should not proceed in this case - in contrast, with auto-select turned off trying to Amplify just a selected label track results in an error message
Comment 13 Peter Sampson 2019-03-30 08:24:33 UTC
Testing on W10 with audacity-2.3.2-alpha-206-939bbc95a245f2134257abc8e29e8c6f0d66bcc3

This looks to be sufficiently fixed on Windows


A) With nothing selected and with "Select all audio..." turned on
only audio tracks are selected - Note Tracks and Label tracks are not selected.

B) IF Label Track(s) or Note Track(s) are selected and no audio tracks are selected the all the audio tracks are auto-selected.
I think this is fine - as the pref descriptor states "Select all audio, if selection required" - so "it does what it says on the tin"

This leaces my Use Cases 2 and 3 from my Comment #12 still extant - but I think that that is acceptable and "desired" behavior - so I am happy that this is "fixed" for Windows.  

And note that the original user-reported bug in Comment #0 that kicked off this thread remains "fixed" - I just re-tested that too.
Comment 14 Steve Daulton 2019-03-31 11:47:57 UTC
While there are still some edge cases where this feature does not do exactly "what it says on the tin", I'm in agreement that in the circumstances (it was a badly conceived feature in the first place, with no clear specification of what it should do or how it would work), it is now sufficiently close to "what it says on the tin", and sufficiently "reasonable behaviour" to now be closed.

For completeness, a couple of edge case of where it does not exactly "do what it says on the tin":

1) If a non-audio track (only) is selected, and an audio effect is launched, then all audio PLUS the currently selected non-audio track will be selected.

2) If a non-audio track is longer than all audio tracks and no audio is selected, then launching an audio effect will select all audio tracks PLUS the selection will extend to the end of the non-audio track.

So yes it does do what it says (hence the bug closed), though in some cases it will select more than the project audio.
Comment 15 James Crook 2019-03-31 16:09:56 UTC
For the record... comment #14 part 1 fixed with 
https://github.com/audacity/audacity/commit/0c4f611b5c9e81323d1f4e4ad095b03f7efd9a11

Part 2 seems to need a bit more template foo than I currently have.