Anki opens but all windows are blank

Just successfully installed a new copy of Anki into Catalina on a Mac Powerbook.

I found my old decks (from December 2019, not all that long ago) and was able to import them. I can see them when I go to Tools > Study Deck and Tools > Add.

But when I click on the “Study” or “Add” buttons nothing happens. There’s a blank open window instead.

I get another blank open window when I go to Anki > About. Here’s the error message I can copy when I go that route. I have no add-ons with this brand-new copy of Anki.

Thoughts? Thanks!

Anki 2.1.42 (8eebfe18) Python 3.8.6 Qt 5.14.2 PyQt 5.14.2
Platform: Mac 10.15.6
Flags: frz=True ao=False sv=1
Add-ons, last update check: 2021-03-31 18:15:54


===Add-ons (active)===
(add-on provided name [Add-on folder, installed at, version, is config changed])


===IDs of active AnkiWeb add-ons===


===Add-ons (inactive)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
1 Like
  1. Disable all addons.
  2. Update Anki to latest version

This is a fresh version of Anki, just downloaded yesterday. It’s the latest version.
I have no add-ons that I’m aware of, I simply downloaded the program, installed it, and then tried to either 1) create a new deck and 2) open up my old decks.

Googled around this afternoon and this seems to be a rather common issue. Resolution seems to be confounded by the fact that some users on Catalina can make Anki work just fine, as if that implies the rest of us are doing something wrong.

But again, this is a fresh installation, no add-ons, install seemed to go well … Anki just throws completely blank pages when opened, even after importing old decks. In my case, even on the “About” page.

This is some kind of bug, folks … :slight_smile:

Can you upload a screenshot of blank window?

Yes need screenshot, has worked fine on my 10.15 for months now.

I’ll do ya one better, friends …

Here’s a video of the fail: Anki Fail on Vimeo

thanks so much for your interest & attention. I’m sure other 10.15 users will appreciate this being resolved; the most common outcome it seemed on those other threads concerning this issue I found today was that after a few back and forths they just seemed to give up. I myself was considering a switch to Brainscape, as I have a deadline for this project … even at the cost of giving up a good dozen decks I’d already created a few years back.

So yes, hats off and thanks (bows deeply.)

1 Like

If you believe it’s a bug, then submit an issue Issues · ankitects/anki · GitHub

If you create a new profile and a new deck, do you see this also happening? If not there’s something odd in your specific deck. If still an issue, I would look at either the installation or the system setup itself. I’ve had zero issues with 10.15 here.

Does the following help?

https://changes.ankiweb.net/#/known-issues?id=blank-screens-and-egpus-on-macs

Is there any updates on this issue? Here is what I have found while playing around.

Devices:
Macbook pro 2016 Catalina 10.15.7
Anki JUST WORKS

Hackintosh with Catalina 10.15.7 (AMD RX580 Radeon GPU - NOT EGPU)
It produces this blank screen just as the OP as.

I found out that following this guide and running Anki from Python WORKS: Running from Python - Frequently Asked Questions

So what is the difference between what I download on Github and the pip/python installed version? Is it a newer version of Qt or something?

This solution doesnt work for me because this is not the user experience that I want. I don’t want to have to use command line just to launch anki. I want it to be an APP just like everything else on my computer.

BTW the other workaround that I have been using is to use a very old version 2.1.35 (Alternative). Only the alternative version works!

Its really concerning that there are so many dead threads on this topic. [SemmelweisLives] even predicted it.

This might be of interest, since the question seems similar.

Ugh. I’m also running into this. One machine, with no add-ons, has a blank screen:

Anki 2.1.49 (dc80804a) Python 3.8.6 Qt 5.14.2 PyQt 5.14.2
Platform: Mac 10.16
Flags: frz=True ao=False sv=3
Add-ons, last update check: 2021-11-11 09:46:29
macOS Big Sur 11.6
Mac Pro (Rack, 2019)
3.3 GHz 12-Core Intel Xeon W
AMD Radeon Pro Vega II Duo 32 GB

Confusingly, my other Mac, isn’t exhibiting the same problem: same version of Anki, same version of macOS; but it’s an ARM M1 SOC instead of an Intel Xeon:

Anki 2.1.49 (dc80804a) Python 3.8.6 Qt 5.14.2 PyQt 5.14.2
Platform: Mac 10.16
Flags: frz=True ao=True sv=3
Add-ons, last update check: 2021-11-10 15:00:56
macOS Big Sur 11.5.2
MacBook Air (M1, 2020)
Apple M1

1 Like

Did you try changing the video driver to software in the preferences?

Yep! Exactly same results. I’ve also wiped out all my local Anki config — no add-ons, no user profile, no system configuration, nothing. Downloaded a fresh pre-compiled copy from GitHub, etc.

Any other debugging steps I can take?

1 Like

The only other thing I can think of is trying the test build with the newer toolkit: New toolkit and packaging test (round 2)

Dang, still no luck, wtf.

With the intel-qt6 build, same results. Night mode, the preferences interface, the add-ons interface, all work — just not the main window. (And presumably reviews, though I can’t get there to test that.

I’m a fairly competent developer, although not experienced with Python, nor Qt — if there’s any further steps I can take, I’m happy to invest the time. (I really need my Anki back! If nothing else, I’m gonna get bitten by a Beeminder goal if I don’t get my addons working soon! :rofl:)

Please start the qt6 build from Terminal.app with /Applications/Anki.app/Contents/MacOS/anki - maybe the text it outputs may give a hint as to the issue.

You could also try adjusting the video settings to see if it makes a difference, eg

QTWEBENGINE_CHROMIUM_FLAGS="–ignore-gpu-blocklist"
flags listed at List of Chromium Command Line Switches « Peter Beverloo

QSG_INFO=1
QSG_RHI_PREFER_SOFTWARE_RENDERER=1

1 Like

Fascinating. The following error is repeated dozens of times, and does not appear when the qt6 build is launched on my M1 Macbook:


❯ ~ [7m 38s] /Applications/Anki.app/Contents/MacOS/anki           
Anki starting...
Initial setup...
Running with temporary Qt5 compatibility shims.
Run with DISABLE_QT5_COMPAT=1 to confirm compatibility with Qt6.
Preparing to run...
qt.webenginecontext: 

GLImplementation: core_profile
Surface Type: OpenGL
Surface Profile: CoreProfile
Surface Version: 4.1
Using Default SG Backend: yes
Using Software Dynamic GL: no
Using Angle: no

Init Parameters:
  *  application-name Anki 
  *  browser-subprocess-path /Applications/Anki.app/Contents/Frameworks/QtWebEngineCore.framework/Helpers/QtWebEngineProcess.app/Contents/MacOS/QtWebEngineProcess 
  *  disable-features DnsOverHttpsUpgrade,ConsolidatedMovementXY,InstalledApp,BackgroundFetch,WebOTP,WebPayments,WebUSB,PictureInPicture 
  *  disable-speech-api  
  *  enable-features TracingServiceInProcess 
  *  enable-threaded-compositing  
  *  gpu-preferences SAAAAAAAAAAoAAAAAAAAAAAAAAAAAAAAAABgAAAAAAAoAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAYAwAAAAAAABgDAAAAAAAACAEAACAAAAAAAQAAAAAAAAgBAAAAAAAAEAEAAAAAAAAYAQAAAAAAACABAAAAAAAAKAEAAAAAAAAwAQAAAAAAADgBAAAAAAAAQAEAAAAAAABIAQAAAAAAAFABAAAAAAAAWAEAAAAAAABgAQAAAAAAAGgBAAAAAAAAcAEAAAAAAAB4AQAAAAAAAIABAAAAAAAAiAEAAAAAAACQAQAAAAAAAJgBAAAAAAAAoAEAAAAAAACoAQAAAAAAALABAAAAAAAAuAEAAAAAAADAAQAAAAAAAMgBAAAAAAAA0AEAAAAAAADYAQAAAAAAAOABAAAAAAAA6AEAAAAAAADwAQAAAAAAAPgBAAAAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAYAAAAQAAAAAAAAAAAAAAAHAAAAEAAAAAAAAAAAAAAACAAAABAAAAAAAAAAAAAAAAoAAAAQAAAAAAAAAAAAAAALAAAAEAAAAAAAAAAAAAAADQAAABAAAAAAAAAAAAAAAA4AAAAQAAAAAAAAAAEAAAAAAAAAEAAAAAAAAAABAAAABgAAABAAAAAAAAAAAQAAAAcAAAAQAAAAAAAAAAEAAAAIAAAAEAAAAAAAAAABAAAACgAAABAAAAAAAAAAAQAAAAsAAAAQAAAAAAAAAAEAAAANAAAAEAAAAAAAAAABAAAADgAAABAAAAAAAAAABAAAAAAAAAAQAAAAAAAAAAQAAAAGAAAAEAAAAAAAAAAEAAAABwAAABAAAAAAAAAABAAAAAgAAAAQAAAAAAAAAAQAAAAKAAAAEAAAAAAAAAAEAAAACwAAABAAAAAAAAAABAAAAA0AAAAQAAAAAAAAAAQAAAAOAAAAEAAAAAAAAAAHAAAAAAAAABAAAAAAAAAABwAAAAYAAAAQAAAAAAAAAAcAAAAHAAAAEAAAAAAAAAAHAAAACAAAABAAAAAAAAAABwAAAAoAAAAQAAAAAAAAAAcAAAALAAAAEAAAAAAAAAAHAAAADQAAABAAAAAAAAAABwAAAA4AAAAIAAAAAAAAAAgAAAAAAAAA 
  *  in-process-gpu  
  *  use-gl core_profile 

Starting main loop...
[61126:48387:1202/084531.121265:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.123325:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.123344:ERROR:gpu_channel_manager.cc(771)] ContextResult::kFatalFailure: Failed to create shared context for virtualization.
[61126:48387:1202/084531.123353:ERROR:shared_image_stub.cc(470)] SharedImageStub: unable to create context
[61126:48387:1202/084531.123366:ERROR:gpu_channel.cc(449)] GpuChannel: Failed to create SharedImageStub
[61126:48387:1202/084531.124454:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.125649:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.125670:ERROR:gpu_channel_manager.cc(771)] ContextResult::kFatalFailure: Failed to create shared context for virtualization.
[61126:48387:1202/084531.125676:ERROR:shared_image_stub.cc(470)] SharedImageStub: unable to create context
[61126:48387:1202/084531.125684:ERROR:gpu_channel.cc(449)] GpuChannel: Failed to create SharedImageStub
[61126:48387:1202/084531.127800:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.129710:ERROR:gl_context_cgl.cc(115)] Error creating context.
[61126:48387:1202/084531.129726:ERROR:gpu_channel_manager.cc(771)] ContextResult::kFatalFailure: Failed to create shared context for virtualization.
[61126:48387:1202/084531.129732:ERROR:shared_image_stub.cc(470)] SharedImageStub: unable to create context
[61126:48387:1202/084531.129739:ERROR:gpu_channel.cc(449)] GpuChannel: Failed to create SharedImageStub

This can be temporarily bypassed (as documented on this GitHub Issue for another qt-using project that fails to render on macOS) with the following invocation:

QTWEBENGINE_CHROMIUM_FLAGS="--disable-gpu" /Applications/Anki.app/Contents/MacOS/anki

I’m happy to provide extra debugging feedback when I can, although I won’t have access to this computer for some period of time … if anybody else runs across this issue, I adapted ahihi’s script to “patch” (… sort of) Anki so that you can successfully launch it from the Finder:

Download, set as executable, execute, and rebuild the LaunchServices database:

/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister\
   -kill -r -domain local -domain system -domain user
3 Likes

Thank you @ELLIOTTCABLE! this workaround works for me as well! I periodically check on Anki to see if they fixed things in their own distribution or if Qt fixed the upstream bug and of course it never is.

At least you have found a workaround that works an allows me to launch the app without running from command line. Pretty excited to finally see a newer version of Anki