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

xpra process_clipboard_packet traceback #2284

Closed
totaam opened this issue Apr 24, 2019 · 14 comments
Closed

xpra process_clipboard_packet traceback #2284

totaam opened this issue Apr 24, 2019 · 14 comments
Labels

Comments

@totaam
Copy link
Collaborator

totaam commented Apr 24, 2019

Issue migrated from trac ticket # 2284

component: client | priority: major | resolution: fixed

2019-04-24 14:13:55: stdedos created the issue


After recovering #2283 session, attaching to it gives:

Xpra-Python3-x86_64_3.0-[r22449](../commit/d446ac2604dd11ffbd10f7da99765e26b3aaaeda)\xpra_cmd" attach ssh://user@ip/2  --opengl=no

2019-04-24 15:15:01,922 Xpra GTK3 client version 3.0-[r22449](../commit/d446ac2604dd11ffbd10f7da99765e26b3aaaeda) 64-bit
2019-04-24 15:15:01,924  running on Microsoft Windows 10
2019-04-24 15:15:01,984 Warning: failed to import opencv:
2019-04-24 15:15:01,985  No module named 'cv2'
2019-04-24 15:15:01,985  webcam forwarding is disabled
2019-04-24 15:15:02,563 GStreamer version 1.14.4 for Python 3.7.2 64-bit
2019-04-24 15:15:02,831  keyboard settings: layout=us
2019-04-24 15:15:02,833  desktop size is 1600x900 with 1 screen:
2019-04-24 15:15:02,833   Default (423x238 mm - DPI: 96x96) workarea: 1600x860
2019-04-24 15:15:02,833     (Standard monitor types) Generic PnP Monitor (309x174 mm - DPI: 131x131)
2019-04-24 15:15:08,861 enabled remote logging
2019-04-24 15:15:08,863 Xpra GTK2 X11 server version 3.0-22432 64-bit
2019-04-24 15:15:08,864  running on Linux Ubuntu 16.04 xenial
2019-04-24 15:15:08,901 Attached to 172.16.57.121:22
2019-04-24 15:15:08,912  (press Control-C to detach)


(Xpra_cmd.exe:8412): Pango-WARNING **: 15:15:10.147: couldn't load font "Bitstream Vera Sans Not-Rotated 11.7294921875", falling back to "Sans Not-Rotated 11.7294921875", expect ugly output.
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)
2019-04-24 15:15:14,172 Warning: limited clipboard support for CLIPBOARD
2019-04-24 15:15:14,174  g-invoke-error-quark: Class GtkInvisible doesn't implement selection_get (1)
@totaam
Copy link
Collaborator Author

totaam commented Apr 24, 2019

2019-04-24 16:58:52: antoine changed owner from antoine to stdedos

@totaam
Copy link
Collaborator Author

totaam commented Apr 24, 2019

2019-04-24 16:58:52: antoine commented


Likely already fixed as part of #812. Try r22519 or later.

@totaam
Copy link
Collaborator Author

totaam commented May 17, 2019

2019-05-17 08:50:58: stdedos commented


It doesn't look resolved to me:

xpra-server is Ubuntu 16.04.6/r22647, but session is old (I don't remember when it was started, xpra info x | grep -iP 'r\d+' does not help)

Also "now":
I know it's no news that clipboard is broken, but now Ctrl+Shift+C on a gnome-terminal empties both clipboards (local and remote AND middle-click buffer).

Xpra-Python3-x86_64_3.0-[r22449](../commit/d446ac2604dd11ffbd10f7da99765e26b3aaaeda)\xpra_cmd" attach ssh://user@ip/2  --opengl=no

2019-05-15 11:34:56,272 Xpra GTK3 client version 3.0-[r22449](../commit/d446ac2604dd11ffbd10f7da99765e26b3aaaeda) 64-bit
2019-05-15 11:34:56,274  running on Microsoft Windows 10
2019-05-15 11:34:56,342 Warning: failed to import opencv:
2019-05-15 11:34:56,342  No module named 'cv2'
2019-05-15 11:34:56,343  webcam forwarding is disabled
2019-05-15 11:34:57,295 GStreamer version 1.14.4 for Python 3.7.2 64-bit
2019-05-15 11:34:57,727  keyboard settings: layout=us
2019-05-15 11:34:57,731  desktop size is 1600x900 with 1 screen:
2019-05-15 11:34:57,732   Default (423x238 mm - DPI: 96x96) workarea: 1600x860
2019-05-15 11:34:57,733     (Standard monitor types) Generic PnP Monitor (309x174 mm - DPI: 131x131)
2019-05-15 11:35:05,889 enabled remote logging
2019-05-15 11:35:05,890 Xpra GTK2 X11 server version 3.0-22432 64-bit
2019-05-15 11:35:05,891  running on Linux Ubuntu 16.04 xenial
2019-05-15 11:35:05,906 Attached to ip:22
2019-05-15 11:35:05,907  (press Control-C to detach)


(Xpra_cmd.exe:3972): Pango-WARNING **: 11:35:06.552: couldn't load font "Bitstream Vera Sans Not-Rotated 11.7294921875", falling back to "Sans Not-Rotated 11.7294921875", expect ugly output.
2019-05-15 11:35:25,441 Warning: limited clipboard support for CLIPBOARD
2019-05-15 11:35:25,443  g-invoke-error-quark: Class GtkInvisible doesn't implement selection_get (1)
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)

(Xpra_cmd.exe:3972): Gdk-WARNING **: 11:36:24.172: Setting selection property with 0x0000000000000000 ## NULL or 0x0 0 or 0x0000000000000000 == 0
2019-05-15 11:37:11,101 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:11,194 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:37:12,378 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:12,985 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:37:15,142 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:15,829 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:37:16,588 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:16,642 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:37:16,963 server is not responding, drawing spinners over the windows
2019-05-15 11:37:17,241 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:17,321 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:37:17,425 unknown string message: 0xc0b6 / 0x6 / 0x1
2019-05-15 11:37:17,521 unknown string message: 0xc0b6 / 0x7 / 0x0
2019-05-15 11:38:11,353 server is OK again
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)
Traceback (most recent call last):
  File "E:\Xpra\trunk\src/xpra/client/mixins/clipboard.py", line 176, in _process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 542, in process_clipboard_packet
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 505, in _process_clipboard_contents
  File "E:\Xpra\trunk\src/xpra/clipboard/gdk_clipboard.py", line 66, in _munge_wire_selection_to_raw
  File "E:\Xpra\trunk\src/xpra/clipboard/clipboard_core.py", line 425, in _munge_wire_selection_to_raw
Exception: unhanled encoding: ('atoms', 'ATOM', 32)

(Xpra_cmd.exe:3972): Gdk-WARNING **: 11:57:36.179: Setting selection property with 0x0000000000000000 ## NULL or 0x0 0 or 0x0000000000000000 == 0
2019-05-15 12:07:53,373 unknown string message: 0xc0b6 / 0x5 / 0x0

$ xpra info 2 | grep -i clip
client.clipboard.contents-slice-fix=True
client.clipboard.enabled=True
client.clipboard.greedy=True
client.clipboard.notifications=True
client.clipboard.selections=('CLIPBOARD',)
client.clipboard.set-enabled=True
client.clipboard.want-targets=False
client.connection.input.count.clipboard-contents=2
client.connection.input.count.clipboard-enable-selections=1
client.connection.input.count.clipboard-request=2
client.connection.input.count.clipboard-token=2
client.connection.output.count.clipboard-contents=1
client.connection.output.count.clipboard-pending-requests=4
client.connection.output.count.clipboard-request=2
client.connection.output.count.clipboard-token=1
client.connection.receive_alias.25=clipboard-token
client.connection.receive_alias.32=clipboard-pending-requests
client.connection.receive_alias.42=set-clipboard-enabled
client.connection.receive_alias.43=clipboard-loop-uuids
client.connection.receive_alias.51=clipboard-contents
client.connection.receive_alias.52=clipboard-enable-selections
client.connection.receive_alias.55=clipboard-contents-none
client.connection.receive_alias.68=clipboard-request
clipboard.CLIPBOARD.blocked_owner_change=False
clipboard.CLIPBOARD.enabled=True
clipboard.CLIPBOARD.event.get_contents=0
clipboard.CLIPBOARD.event.got_token=23
clipboard.CLIPBOARD.event.request_contents=0
clipboard.CLIPBOARD.event.selection_clear=0
clipboard.CLIPBOARD.event.selection_get=0
clipboard.CLIPBOARD.event.selection_request=0
clipboard.CLIPBOARD.event.sent_token=0
clipboard.CLIPBOARD.greedy_client=True
clipboard.CLIPBOARD.have_token=True
clipboard.CLIPBOARD.last-targets=()
clipboard.CLIPBOARD.loop-uuid=Xpra-Clipboard-Loop-Detection:9289f84b70374a6da0ab13324d688a5b
clipboard.PRIMARY.blocked_owner_change=False
clipboard.PRIMARY.enabled=False
clipboard.PRIMARY.event.get_contents=0
clipboard.PRIMARY.event.got_token=46
clipboard.PRIMARY.event.request_contents=0
clipboard.PRIMARY.event.selection_clear=0
clipboard.PRIMARY.event.selection_get=0
clipboard.PRIMARY.event.selection_request=0
clipboard.PRIMARY.event.sent_token=0
clipboard.PRIMARY.greedy_client=True
clipboard.PRIMARY.have_token=False
clipboard.PRIMARY.last-targets=()
clipboard.PRIMARY.loop-uuid=Xpra-Clipboard-Loop-Detection:aceca2dbeb7b4653b5166e7b3c37fbfa
clipboard.SECONDARY.blocked_owner_change=False
clipboard.SECONDARY.enabled=False
clipboard.SECONDARY.event.get_contents=0
clipboard.SECONDARY.event.got_token=2
clipboard.SECONDARY.event.request_contents=0
clipboard.SECONDARY.event.selection_clear=0
clipboard.SECONDARY.event.selection_get=0
clipboard.SECONDARY.event.selection_request=0
clipboard.SECONDARY.event.sent_token=0
clipboard.SECONDARY.greedy_client=True
clipboard.SECONDARY.have_token=False
clipboard.SECONDARY.last-targets=()
clipboard.SECONDARY.loop-uuid=Xpra-Clipboard-Loop-Detection:ae3c2cc839c24254b27756853eac0364
clipboard.can-receive=True
clipboard.can-send=True
clipboard.filters=()
clipboard.max_recv_size=-1
clipboard.max_send_size=-1
clipboard.max_size=4194304
clipboard.pending=()
clipboard.requests=22
clipboard.type=X11Clipboard
clipboard.want_targets=False
features.clipboard=True
features.clipboard-direction=both
features.clipboard.contents-slice-fix=True
features.clipboard.enable-selections=True
features.clipboard.loop-uuids.CLIPBOARD=Xpra-Clipboard-Loop-Detection:9289f84b70374a6da0ab13324d688a5b
features.clipboard.loop-uuids.PRIMARY=Xpra-Clipboard-Loop-Detection:aceca2dbeb7b4653b5166e7b3c37fbfa
features.clipboard.loop-uuids.SECONDARY=Xpra-Clipboard-Loop-Detection:ae3c2cc839c24254b27756853eac0364
features.clipboards=('CLIPBOARD', 'PRIMARY', 'SECONDARY')
network.packet-handlers.ui=('buffer-refresh', 'button-action', 'clipboard-contents', 'clipboard-contents-none', 'clipboard-enable-selections', 'clipboard-loop-uuids', 'clipboard-pending-requests', 'clipboard-request', 'clipboard-token', 'close-window', 'configure-window', 'damage-sequence', 'desktop_size', 'encoding', 'exit-server', 'focus', 'force-ungrab', 'info-request', 'input-devices', 'key-action', 'key-repeat', 'keymap-changed', 'layout-changed', 'map-window', 'min-quality', 'min-speed', 'notification-action', 'notification-close', 'pointer-position', 'quality', 'resume', 'rpc', 'screenshot', 'server-settings', 'set-bell', 'set-clipboard-enabled', 'set-cursors', 'set-keyboard-sync-enabled', 'set-notify', 'set_deflate', 'shutdown-server', 'speed', 'start-command', 'suspend', 'unmap-window', 'wheel-motion', 'window-signal')

@totaam
Copy link
Collaborator Author

totaam commented May 17, 2019

2019-05-17 08:57:09: antoine commented


I know it's no news that clipboard is broken
It is, clipboard is supposed to be fine.

r22449
That's too old and this stacktrace is probably already fixed in newer builds.
As for losing clipboard contents on exit, this was already discussed in a different ticket.

@totaam
Copy link
Collaborator Author

totaam commented May 17, 2019

2019-05-17 10:15:44: stdedos commented


Replying to [comment:3 Antoine Martin]:

r22449
That's too old and this stacktrace is probably already fixed in newer builds.

Same with r22633-attaching-client

As for losing clipboard contents on exit, this was already discussed in a different ticket.

Would you please add the ID here?


However, I am not talking about "any" exit:

  • Select text in win10 xpra-client gnome-terminal (ubuntu 16.04.6)
  • Ctrl+Shift+C
  • Switch to e.g. win10 VS Code
  • Ctrl+C
  • (Notice no text is coming out)
  • Switch to win10 xpra-client gnome-terminal (ubuntu 16.04.6)
  • Open e.g. nano
  • Ctrl+Shift+V
  • (Notice no text is coming out)
  • mouse-middle-click
  • (Notice no text is coming out either)

@totaam
Copy link
Collaborator Author

totaam commented May 26, 2019

2019-05-26 12:55:29: antoine changed status from new to assigned

@totaam
Copy link
Collaborator Author

totaam commented May 26, 2019

2019-05-26 12:55:29: antoine changed owner from stdedos to antoine

@totaam
Copy link
Collaborator Author

totaam commented May 26, 2019

2019-05-26 12:55:29: antoine commented


I am seeing problems with the MS Windows client where the first clipboard update doesn't take. Copy the same text again and it does paste properly.
The -d clipboard output shows the exact same data both times!
set_clipboard_text('somestring').

@totaam
Copy link
Collaborator Author

totaam commented May 27, 2019

2019-05-27 08:00:04: @totaam changed status from assigned to new

@totaam
Copy link
Collaborator Author

totaam commented May 27, 2019

2019-05-27 08:00:04: @totaam changed owner from antoine to stdedos

@totaam
Copy link
Collaborator Author

totaam commented May 27, 2019

2019-05-27 08:00:04: @totaam commented


Fixed in r22796: we just retry a few times until MS Windows accepts the value!
(no idea why waiting a few milliseconds helps, but it does)

See also #2309: clipboard data type from MS Windows clients was invalid.

New beta builds posted.

If you still have problems, please include the -d clipboard output.
If not, then please close this ticket.

@totaam
Copy link
Collaborator Author

totaam commented Jun 11, 2019

2019-06-11 17:49:15: antoine changed status from new to closed

@totaam
Copy link
Collaborator Author

totaam commented Jun 11, 2019

2019-06-11 17:49:15: antoine set resolution to fixed

@totaam totaam closed this as completed Jun 11, 2019
@totaam
Copy link
Collaborator Author

totaam commented Jun 19, 2019

2019-06-19 10:12:40: stdedos commented


It appears fixed in 22922 (and clipboard also working)

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

No branches or pull requests

1 participant