[1.1.0] Mac: App.getClipboard(): java.io.IOException: system clipboard data unavailable --- should be handled internally --- fixed 1.1.0
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SikuliX |
Fix Committed
|
Critical
|
RaiMan |
Bug Description
**** fixed 1.1.0 2015-07-01+
- exceptions handled internally
- empty string returned
- error messages
-------
I am using Sikui 1.1.0 Build:2015-
My application clicks in a text region, selects it and copies it to the clipboard before processing this text further. My application can run and do this hundreds of times successfully and then suddenly I get the following error:-
[log] CLICK on L(718,1044)
[log] ( ? ) TYPE "a"
[log] ( ? ) TYPE "c"
java.io.
at apple.awt.
at sun.awt.
at sun.awt.
at sun.awt.
at org.sikuli.
at sun.reflect.
at sun.reflect.
at java.lang.
at org.python.
at org.python.
at org.python.
at org.python.
at readChatWindow$
.py:494)
at readChatWindow$
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.python.
at org.sikuli.
at org.siku
li.scriptrunner
at org.sikuli.
Looking through past faults there seems to be some references to this. Is there still a known fault? Is there a work around? What is happening? Can some other resource be grabbing the clipboard? Perhaps if I knew what I could disable it.
All help/suggestions welcome
Jonathan.
Changed in sikuli: | |
status: | In Progress → Fix Committed |
importance: | Medium → Critical |
milestone: | 2.0.0 → 1.1.0 |
summary: |
[1.1.0] Mac: App.getClipboard(): java.io.IOException: system clipboard - data unavailable --- should be handled internally + data unavailable --- should be handled internally --- fixed 1.1.0 |
description: | updated |
according to some bug posts in the net, this seems to be a special Mac/Java problem, where there is no solution.
Nothing special with SikuliX.
The recommendation is, to catch the exception and try again or ignore.
so you might do this:
isUnavailable = "#UNAVAILABLE#"
try:
text = App.getClipboard()
catch:
text = isUnavailable
if text == isUnavailable:
# do corrective actions