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

I got a weird bug #237

Open
luis-arch opened this issue Jan 4, 2023 · 2 comments
Open

I got a weird bug #237

luis-arch opened this issue Jan 4, 2023 · 2 comments

Comments

@luis-arch
Copy link

luis-arch commented Jan 4, 2023

In the following code, I try to determine whether the clipboard has changed, so as to execute the function of the clipboard change.
But the clipboard change function is called many times without any change in the clipboard itself. I didn't encounter problems during the debugging process, but when I actually ran the code, an error occurred.
I feel like I'm making a very basic problem, but I can't figure out what I'm doing wrong.
The python version I am running is 3.6. The version of pyperclip running is 1.8.2.

image

@dutkulang
Copy link

the issue is in your code not with pyperclip

@timbr0wn
Copy link

You may want to try the pyperclip.waitForNewPaste() function, which blocks until the text on the clipboard has changed.

It also has a optional timeout parameter which can be set to your desired timeout, in seconds.

If not provided, the timeout defaults to None.

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

3 participants