Custom rotor is always playing end-of-list sound

I have a custom rotor that changes the skim speed of the skim forward/backward feature of my audio player. The rotor works, but it's always playing an end-of-list sound.

Here is the code:

    // Member variables
    private let accessibilitySeekSpeeds: [Double] = [10, 30, 60, 180]  // seconds
    private var accessibilitySeekSpeedIndex: Int = 0

    func seekSpeedRotor() -> UIAccessibilityCustomRotor {
        UIAccessibilityCustomRotor(name: "seek speed") { [weak self] predicate in
            guard let self = self else { return nil }
            
            let speeds = accessibilitySeekSpeeds
            switch predicate.searchDirection {
            case .previous:
                accessibilitySeekSpeedIndex = (accessibilitySeekSpeedIndex - 1 + speeds.count) % speeds.count
            case .next:
                accessibilitySeekSpeedIndex = (accessibilitySeekSpeedIndex + 1) % speeds.count
            @unknown default:
                break
            }
            
            // Return the currently selected speed as an accessibility element
            let accessibilityElement = UIAccessibilityElement(accessibilityContainer: self)
            let currentSpeed = localizedDuration(seconds: speeds[accessibilitySeekSpeedIndex])
            accessibilityElement.accessibilityLabel = currentSpeed + " seek speed"
            UIAccessibility.post(notification: .announcement, argument: currentSpeed + " seek speed")
            return UIAccessibilityCustomRotorItemResult(targetElement: accessibilityElement, targetRange: nil)
        }
    }

The returned accessibility element isn't read out, and instead an end-of-list sound is played. I can announce the change manually using UIAccessibility.post, but it still plays the end-of-list sound.

How can I prevent the rotor from playing the end-of-list sound?

Hello, please take a few extra minutes and paste this issue into a bug report so we can confirm this is tracked in our internal system, to help verify if there is a VoiceOver bug or if something needs to be tweaked with the implementation. Doing this will help us get vital information about the issue like logs from your device. You can file a report here: https://developer.apple.com/bug-reporting/

Once you do, feel free to reply with the Feedback ID number.

Of course. Here's the Feedback ID: FB13797657

Custom rotor is always playing end-of-list sound
 
 
Q