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

Auto pasting image when triggered window from Taskbar #6887

Open
2 tasks done
avi12 opened this issue May 23, 2024 · 16 comments
Open
2 tasks done

Auto pasting image when triggered window from Taskbar #6887

avi12 opened this issue May 23, 2024 · 16 comments

Comments

@avi12
Copy link

avi12 commented May 23, 2024

Using a supported version?

  • I have searched searched open and closed issues for duplicates.
  • I am using Signal-Desktop as provided by the Signal team, not a 3rd-party package.

Overall summary

Suppose I put Signal on desktop 1 and I'm on desktop 2 and it's pinned to the Taskbar, if I switch to it with the corresponding Taskbar shortcut, it will focus on the chat and auto-paste what I have in my clipboard

Steps to reproduce

  1. Put Signal on desktop 1
  2. Switch to desktop 2
  3. Suppose Signal is pinned to the 5th place in the Taskbar, press Windows+5
  4. Windows will switch to Signal, focus it and Signal for some reason will paste whatever I have on my clipboard, in this case, an image

Note: if I just Alt+Tab into Signal or move between desktops with Crtl+Windows+Left/Right, it doesn't reproduce the bug. It has to be specifically Windows+<number>

Expected result

It should indeed focus on the Signal window, but without pasting anything

Actual result

It pastes whatever I have on my clipboard. I haven't tested it on other forms of media, like text, but I would like to provide as much logging information as possible before trying to put on the clipboard other forms of media
Edit: Just tested, it also applies if I have text on the clipboard

Screenshots

2024-05-23.13-49-08.explorer.mp4

Signal version

7.10.0

Operating system

Windows 10 22H2

Version of Signal on your phone

No response

Link to debug log

debuglog.txt
https://debuglogs.org/desktop/7.10.0/6716812168d8343e9082830a9916b4a78bb7d0e328300469ce62bac1e7b5cf1e.gz

@ayumi-signal
Copy link
Contributor

That's very interesting! I was unable to reproduce on my Windows 11 machine, but I believe it might be real.

@revital-sa
Copy link

revital-sa commented May 23, 2024

I have the same issue on Windows 10. Started today or yesterday.

Edit: also happens with text.

@nabeelr
Copy link

nabeelr commented Jun 9, 2024

I've experienced this too on Windows 11, 23H2. Signal version 7.11.1.

I thought I had fat fingered something the first few times, but now I've realized it's whatever is in my clipboard, gets dumped into the current chat textbox.

This is a bit of a privacy concern, because it's very easy to accidentally send whatever is in your clipboard to whoever you were last talking to on Signal. Also, Signal should simply NEVER read the clipboard unless the user explicitly asks it to...

Just to add, another way to reproduce it is simply whenever Signal's window is first opened. If you close the Signal window and have it running in the system tray, then open the Signal app by double-clicking on it's icon in the task bar or it's icon in the start menu, this will happen as well.

The key seems to be to close the signal window and re-open it via an icon on the task bar or start menu. Opening it from the system tray will NOT reproduce the issue.

@indutny-signal
Copy link
Contributor

Thank you for the report; this seems frustrating indeed! Unfortunately, so far we have been unable to reproduce this issue on our end (on either Windows 10 or 11). Signal Desktop simply handles clipboard paste events that are generated by the Operating System, and doesn't access the clipboard contents otherwise. Furthermore, we haven't made any changes to the composition input text field for a significant amount of time, so it is surprising that you only started to experience this recently.

To help us narrow it down, could you try focusing on the search bar in the left pane of the Signal Desktop window (you might need to expand it first), and see if the clipboard contents get pasted there too when the cursor is in the search bar?

@nabeelr
Copy link

nabeelr commented Jun 11, 2024

To help us narrow it down, could you try focusing on the search bar in the left pane of the Signal Desktop window (you might need to expand it first), and see if the clipboard contents get pasted there too when the cursor is in the search bar?

It does for me.

@indutny-signal
Copy link
Contributor

@nabeelr oh, very confusing... unlike the composition area, this fields doesn't even support text formatting so it is basically a native field.

At glance this sounds like either an OS regression, or an Electron bug. This might be a long shot, but would you be willing to try reproducing it with an Electron fiddle or Slack/Discord? They are all Electron apps that also have text fields, and I wonder if they suffer from the same issue.

@nabeelr
Copy link

nabeelr commented Jun 11, 2024

Discord doesn't do it, just Signal. I tested with Text, not with images. I just tried with media won't paste into the search text box, but still will in the chat text box, depending on which field had focus last.

OP and I seem to have the same problem, but we are triggering it different ways. They trigger it by using multi-desktop, I trigger it by having signal close to the system tray, then re-opening signal from the taskbar or the start menu.

@indutny-signal
Copy link
Contributor

Thank you for giving it a try! As the last idea, could you try Signal Beta? (You can install beta side-by-side with production Desktop).

@nabeelr
Copy link

nabeelr commented Jun 11, 2024

Yup, happens in the Beta as well.

Here's a video of it happening, and when it does and doesn't happen for me.

I didn't try how OP reproduced it, but this is how I'm able to reproduce it.

https://www.youtube.com/watch?v=patLvT7ZiuQ

@nabeelr
Copy link

nabeelr commented Jun 11, 2024

Aaannddd.... I just lost my whole Signal history on my Desktop...

When uninstalling the Beta, I noticed there were two other versions of Signal installed, one far older, version 1.x... I uninstalled it, and now everything is gone...

This is exhausting.

Edit: Please tell me there is a backup of the message database on Windows somewhere...

@indutny-signal
Copy link
Contributor

@nabeelr oh no! Unfortunately, there is no backup. I guess you already reinstalled from the website, right?

@nabeelr
Copy link

nabeelr commented Jun 11, 2024

I have, just now, yeah... The uninstaller should really warn you that it's going to remove your chat history when it uninstalls... It's rare for an uninstaller to remove user data... and it's generally bad form unless the user gets explicitly warned.

The issue is still occurring...

@indutny-signal
Copy link
Contributor

I'm terribly sorry about this, and thank you for filing another issue!

I think we have narrowed down what's going on significantly, but there is one bound that we could also set if you could give a try to Electron Fiddle. Discord, I suspect, might be running older Electron version than we do, but the Fiddle is on the same major release version so should give comparable results. Thank you so much for your help!

@nabeelr
Copy link

nabeelr commented Jun 12, 2024

I'm terribly sorry about this, and thank you for filing another issue!

Thanks.

Tried Electron Fiddle, it doesn't take focus the same way Signal does when you do Windows + (# position app is pinned).

But I was able to recreate the bug as OP stated on Signal as well.

The issue doesn't occur in Fiddle at all from what I can see...

@indutny-signal
Copy link
Contributor

indutny-signal commented Jun 12, 2024

@nabeelr Looking again at your youtube video, I think you might have been still running regular Signal Desktop application, and not the beta version (which should have Signal Beta in the window title).

That being said, I wonder if this issue on another project might be related to what you experience: microsoft/PowerToys#32971 ? Do you use Power Toys by any chance? If not - could you try disabling advanced paste to see if it stops the issue from occurring?

@nabeelr
Copy link

nabeelr commented Jun 12, 2024

The video was definitely of the regular version and not the beta, but the beta behaved in the same way.

Though, wow, that is a STRIKINGLY similar bug and I do have PowerToys installed, but I don't use advanced paste, and this doesn't happen anywhere else. Nevertheless, I'll try quitting PowerToys when I get home and see if it still happens.

I suspect this is the cause.

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

No branches or pull requests

5 participants