FileNotFoundError: [Errno 2] No such file or directory: 'Xvfb'

Hi Guys,

I got the below error while running my C3_W3 Assignment at my local (Macbook M2), anyone has seen that and has a solution?

FileNotFoundError: [Errno 2] No such file or directory: ‘Xvfb’

Python:3.11.4, pyvirtualdisplay: 3.0

Thank you

Hi @GavinXu

Welcome to the community.

You likely need to install either the xvfb package, or possibly the xvfbwrapper:

Yes I installed the xvfbwrapper, but it does not work
Successfully installed xvfbwrapper-0.2.9

Do you installed using brew?

brew install --cask xquartz

@elirod
It does not work either

I have the same problem. Hasn’t solved yet.

The solution can be found at python 3.x - pyvirtual display and xvfb on MacOS latest - Stack Overflow