Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pyautogui.screenshot() method is not working on Mac OS 13.2.1 #94

Open
bwomsm1 opened this issue Feb 28, 2023 · 5 comments
Open

pyautogui.screenshot() method is not working on Mac OS 13.2.1 #94

bwomsm1 opened this issue Feb 28, 2023 · 5 comments

Comments

@bwomsm1
Copy link

bwomsm1 commented Feb 28, 2023

I am facing a problem that started with Mac OS 13.2.1 and was not happening on Mac OS 12.6.3 which that the call to pyautogui.screenshot() is not taking a screen shot.

script to reproduce the problem:

import pyautogui
import numpy
import cv2

images = pyautogui.screenshot()
frames = numpy.array(images)
frames_RGB = cv2.cvtColor(frames, cv2.COLOR_BGR2RGB)

Please advice. Thanks!

@a-alak
Copy link

a-alak commented May 26, 2023

What error are you getting? I have an error with the Pillow version check, which I have fixed locally. Will open an issue to push the fix.

@rnbrady
Copy link

rnbrady commented Jun 15, 2023

Also having issues. I'm using PyScreeze 0.1.29 with Python 3.11.4 on MacOS 13.3.1.

First issue is that passing filename as string does not result in saving to disk (this is an OS screenshot):

Screenshot 2023-06-15 at 12 25 34

I can save to disk in a separate step but the screenshot that gets saved should look like the one above, but instead is just an empty desktop with no applications:

sc1a

Here's an OS screenshot afterwards:

Screenshot 2023-06-15 at 12 26 39

@Existance29
Copy link

@rnbrady have you given iTerm screen recording permissions in the system settings? This is quite a common issue and fix

@rnbrady
Copy link

rnbrady commented Jul 2, 2023

@Existance29 I hadn't. Thank you so much for this tip.

@addisonlee
Copy link

addisonlee commented Oct 9, 2024

Also having issues. I'm using PyScreeze 0.1.29 with Python 3.11.4 on MacOS 13.3.1.

First issue is that passing filename as string does not result in saving to disk (this is an OS screenshot):

@rnbrady I just submitted a PR #128 to fix your first issue. The problem occurs if your Pillow version is >= 6.2.1.

Note however that the PR is not related to your 2nd issue or the OP's issue, but it's possible those were permission errors as mentioned by @Existance29.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants