Bug: Flag hotkeys (Cmd+1-7) stop working in Preview pane after switching profiles on macOS

Anki version: 25.02.7 (macOS build)
Operating system: macOS 15.5
Reproducible since: multiple previous releases (exact version unknown)


Steps to reproduce

  1. Launch Anki.
  2. Open a second profile via Profiles ► Switch Profile.
  3. Go to Browse.
  4. In the card list, select any card or note so it loads in the Preview pane on the right.
  5. While the focus remains inside the Preview pane, press Cmd+1Cmd+7 to apply a flag.

Actual behaviour

  • Nothing happens—no flag is applied while focus is in the Preview pane.
  • If you click back into the card/note row in the list and use the same hotkeys, the flag is applied as expected.
  • Closing Anki completely and relaunching restores normal flag-hotkey behaviour until the next time you switch profiles.

Expected behaviour

Flag hotkeys (Cmd+number) should work in the Preview pane immediately after switching profiles, exactly as they do when Anki is first opened.

Notes

  • This bug has existed for a long time and is still present in 25.02.7.
  • Only profile switching seems to trigger the issue; a full restart clears it temporarily.
  • I’ve confirmed it occurs with a clean profile.

Happy to provide additional details if needed. Thanks for taking a look!

Are you sure those shortcuts work in the Preview window to begin with? I’ve never seen that happen in Windows. The normal Browse shortcuts like flag, mark, suspend, etc. only work in the Browse window. So if it’s working in MacOS in the first place, that’s the odd one out.

And we should clarify – Preview opens in a separate window unless you’re using an add-on that causes a different behavior. Is it possible that your add-on isn’t loading properly after profile switching? If you can reproduce this behavior in safe mode, then there’s more to consider.

[There definitely are add-ons that don’t load quite the same after profile switching – Review Heatmap is one of them. But I’ve never tracked down whether that is an add-on issue or an Anki issue.]

Thank you for your note. I tried again in Safe Mode: on macOS, the Preview pane accepts shortcuts like Cmd + 1-7 (flags), Cmd + J, etc.—but only until I use Switch Profile. After switching profiles, these shortcuts stop working in the Preview pane, though they still function in the list. A full relaunch resolves the issue. So, it’s not related to any add-ons; it appears to be a macOS-specific quirk that occurs after switching profiles.

But if you still have a “Preview pane” that is an integrated part of the Browse window – isn’t that being produced by an add-on? Or maybe this is a MacOS-only feature that I just never seen. :person_shrugging:t4:

Maybe there is a problem with my expression, I am referring to this:

Okay, that is the separate window I was talking about. If you’ve gotten those shortcuts to work in that window then we’ll have to wait and see if anyone else with MacOS can reproduce what you’re seeing.

Go to Anki > About – click “Copy Debug Info” – and paste that entire result here.

Anki 25.02.7 (1b882285) (ao)
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1
Platform: macOS-15.5-arm64-arm-64bit

===Add-ons (active)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
AJT Autocopy [‘1995103628’, 2023-11-05T20:15, ‘None’, mod]
AJT Browser Play Button [‘182970692’, 2025-03-08T05:14, ‘None’, ‘’]
AJT Japanese Furigana Pitch Accent Native pronunciations [‘1344485230’, 2024-12-20T19:18, ‘None’, mod]
AJT Merge Notes Merge and Duplicate notes [‘1425504015’, 2024-09-18T04:35, ‘None’, mod]
Add note ID Fixed by Shige [‘8897764’, 2024-01-14T04:28, ‘None’, mod]
Advanced Browser [‘874215009’, 2024-10-27T23:20, ‘None’, mod]
Advanced Copy Fields [‘1898445115’, 2024-01-09T02:01, ‘v0.4.01’, ‘’]
AnkiCC [‘158877706’, 2024-04-16T00:01, ‘None’, ‘’]
AwesomeTTS - Add speech to your flashcards [‘1436550454’, 2025-05-30T07:12, ‘None’, mod]
Enhance main window - add many columns to home decks Customized by Shige [‘911023479’, 2025-05-16T06:49, ‘None’, mod]
FSRS Helper Postpone Advance Load Balance Easy Days Disperse Siblings [‘759844606’, 2025-06-15T12:58, ‘None’, mod]
HyperTTS - Add speech to your flashcards [‘111623432’, 2025-06-14T00:19, ‘None’, mod]
Review Heatmap [‘1771074083’, 2022-06-30T10:43, ‘None’, ‘’]
Transfer Scheduling Info Advanced [‘1249258442’, 2024-08-02T11:39, ‘None’, ‘’]

===IDs of active AnkiWeb add-ons===
111623432 1249258442 1344485230 1425504015 1436550454 158877706 1771074083 182970692 1898445115 1995103628 759844606 874215009 8897764 911023479

===Add-ons (inactive)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
Adjust Sound Volume Enhanced by egg rolls [‘2095265391’, 2025-01-15T18:56, ‘None’, mod]
Anki Preview Reloader [‘571150035’, 2025-02-01T05:22, ‘1.0.2’, ‘’]
AnkiConnect [‘2055492159’, 2025-06-13T11:01, ‘None’, ‘’]
AnkiWebView Inspector [‘31746032’, 2023-06-28T04:26, ‘None’, ‘’]

1 Like

Thank you for the report; I’ve logged this on Bug: Flag hotkeys (Cmd+1-7) stop working in Preview pane after switching profiles on macOS · Issue #4141 · ankitects/anki · GitHub