#1458 closed defect (worksforme)
Clipboard is unreliable with thunderbird editor area
Reported by: | psycho_zs | Owned by: | psycho_zs |
---|---|---|---|
Priority: | minor | Milestone: | 2.1 |
Component: | clipboard | Version: | trunk |
Keywords: | Cc: |
Description
Running thunderbird on server, copying or pasting text from/into thunderbird's editor area not working most of the time.
In the test I've copied text from leafpad on the client to leafpad on server (successful), then another text from leafpad on the client to thunderbird on server (previous data is pasted). Then again (unsuccessful), then pasted to leafpad on server (successful), then pasted to thunderbird (after pasted to leafpad, successful).
So after using clipboard for the first time, I'm only being able to paste to thunderbird after I paste to something else.
Attachments (5)
Change History (17)
Changed 4 years ago by
Attachment: | client_clipboard.log added |
---|
Changed 4 years ago by
Attachment: | server_clipboard.log added |
---|
comment:1 Changed 4 years ago by
Component: | client → clipboard |
---|---|
Milestone: | → 2.0 |
Status: | new → assigned |
comment:2 Changed 4 years ago by
Owner: | changed from Antoine Martin to psycho_zs |
---|---|
Status: | assigned → new |
I cannot reproduce.
The clipboard works for me everytime, in both directions.
I've tried on Fedora 25 and Debian Stretch.
Maybe something is interfering with the clipboard on your client system? See wiki/Clipboard.
I cannot use the sample log files provided as I have no way of knowing which part of the log file relate to what: the communication is done via the X11 server's "selections", so all the events look pretty much the same.
comment:3 Changed 4 years ago by
Please provide more succinct or annotated log samples, otherwise I will have to close this ticket as "worksforme".
comment:4 Changed 4 years ago by
I've isolated two events: I copy text from leafpad on client and unsuccessfully try to paste it into thunderbird on server. No clipboard manager running. Copied text was: 2:36: copy from leafpad client to tb server
Attaching this part of server log and client output...
comment:5 Changed 4 years ago by
OK, so that's quite a bit clearer.
We see lots of:
process clipboard request, request_id=11, selection=CLIPBOARD, local name=CLIPBOARD, target=TARGETS
That's the application requesting the list of targets for the clipboard. (the list of formats we can supply for this clipboard)
We dutifully respond every time with the list:
['TIMESTAMP', 'TARGETS', 'MULTIPLE', 'GTK_TEXT_BUFFER_CONTENTS', \ 'application/x-gtk-text-buffer-rich-text', 'UTF8_STRING', 'TEXT', 'STRING', \ 'text/plain;charset=utf-8', 'text/plain']
But then we get a request that doesn't make any sense:
process clipboard request, request_id=14, selection=CLIPBOARD, local name=CLIPBOARD, target=application/x-moz-nativehtml
As it uses a target ("application/x-moz-nativehtml") we have not advertised.
And when forward it to the application, it responds with "no data":
unpack(..) type=, format=0, data=<type 'NoneType'>:0
Which is expected since we're requesting a target it knows nothing about.
And this rings a bell:
- ticket:883#comment:11 : firefox also requesting "x-moz-nativehtml" when it shouldn't
- ticket:834#comment:6 : same issue, contains a hack-nativehtml-to-string.patch which can substitute the target with one that is actually going to work
The patch above was not applicable as it is: some applications may provide the "x-moz-nativehtml" target, so we should only translate this target if it isn't going to work.
r15589 does that, it also exposes the targets we have last sent via xpra info:
$ xpra info | grep last-targets
@psycho_zs: does that work for you now?
comment:7 Changed 4 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:8 Changed 4 years ago by
Formatting is lost on paste, e.g. when copying from LibreOffice? on client to Thunderbird on server.
Also I can not paste anything formatted copied from Firefox. And clipboard stops working after such attempt. E.g. when copying a random couple dozen lines from this ticket page.
BTW, this can be related: #1458
comment:10 Changed 4 years ago by
Milestone: | 2.0 → 2.1 |
---|
Formatting is lost on paste, e.g. when copying from LibreOffice?? on client to Thunderbird on server.
Also I can not paste anything formatted copied from Firefox.
That's a different issue, please file another ticket and link back here.
It could well be because we are now filtering the invalid target application/x-moz-nativehtml
.
And clipboard stops working after such attempt. E.g. when copying a random couple dozen lines from this ticket page.
Works for me, though after repeated copying I saw one of those two warnings in the server log and the clipboard was then disabled (as per the message):
clipboard disabled: more than %s clipboard requests per second!
Warning: loop nesting too deep: 10 you may have a clipboard forwarding loop, disabling the clipboard
That's because thunderbird and Firefox make dozens of clipboard requests for a single paste... so r16146 tolerates more clipboard requests per second before giving up: waiting for sustained requests and tolerating more bursts, r16147 also raises the loop nesting limit to 20.
This should help a bit, but don't expect miracles: what those apps are doing with the clipboard is really pushing it.
comment:11 Changed 4 years ago by
Resolution: | → worksforme |
---|---|
Status: | reopened → closed |
comment:12 Changed 5 weeks ago by
this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1458
From the log samples: xpra X11 version 2.0-r15223 64-bit on Linux Debian 9.0 stretch.
Oh god, another clipboard bug..