This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 224866 - NetBeans stops being able to receive keyboard input
Summary: NetBeans stops being able to receive keyboard input
Status: REOPENED
Alias: None
Product: platform
Classification: Unclassified
Component: JDK Problems (show other bugs)
Version: 7.3
Hardware: PC Linux
: P2 normal with 1 vote (vote)
Assignee: Antonin Nebuzelsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-14 18:19 UTC by recurse
Modified: 2017-11-14 18:30 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE log (48.70 KB, text/plain)
2013-01-14 18:19 UTC, recurse
Details
Thread dump generated using ctrl-\ (19.25 KB, text/plain)
2013-01-15 18:32 UTC, recurse
Details
Thread dump (32.07 KB, application/octet-stream)
2016-01-14 00:33 UTC, fer77
Details

Note You need to log in before you can comment on or make changes to this bug.
Description recurse 2013-01-14 18:19:39 UTC
Product Version = NetBeans IDE 7.3 Beta 2 (Build 201211062253)
Operating System = Linux version 3.6.11-1.fc17.x86_64 running on amd64
Java; VM; Vendor = 1.7.0_09
Runtime = Java HotSpot(TM) 64-Bit Server VM 23.5-b02

I often get this problem. After using NetBeans for a while (several seconds to a few minutes), it sometimes stops being able to receive keyboard input. Everything else seems normal, including mouse input and the response to it. It seems that a similar issue has appeared in previous versions before but supposedly fixed. I can link to those issues if necessary. I don't have a reliable way of reproducing this but it happens a lot and is the reason I have to close NetBeans >50% of the time.
Comment 1 recurse 2013-01-14 18:19:44 UTC
Created attachment 130197 [details]
IDE log
Comment 2 Antonin Nebuzelsky 2013-01-15 13:00:59 UTC
Please, attach a full thread dump generated when the problems appears to this issue and reopen. Thanks.
http://wiki.netbeans.org/GenerateThreadDump
Comment 3 recurse 2013-01-15 18:32:13 UTC
Created attachment 130255 [details]
Thread dump generated using ctrl-\
Comment 4 Antonin Nebuzelsky 2013-01-18 14:44:42 UTC
The thread dump does not seem to point to the problem.

Possibly the two exceptions in the messages.log could help indicate the cause.

INFO [org.netbeans.spi.lexer.MutableTextInput]: !!WARNING!! Missing READ-LOCK when accessing TokenHierarchy: ...

INFO [dlight.libs.common.logger]: Should not be called from UI thread

Reassigning to editor for evaluation.
Comment 5 Stanislav Aubrecht 2013-01-18 14:53:32 UTC
Reporter, is there blinking cursor when clicking into editor window?
Does it affect the editor window only or other text fields as well?
Does the IDE react to keyboard shortcuts? e.g. Ctrl+Tab?
Comment 6 recurse 2013-01-20 11:12:59 UTC
Yes, there's a blinking cursor, and I can even make selections with the mouse.

As far as I can tell, nothing at all responds to the keyboard but everything responds to the mouse. Ctrl-tab doesn't work. Alt-F also doesn't work, though I can still bring out the "open file" dialog with the mouse, but the dialog that pops up doesn't respond to the keyboard, either.
Comment 7 Stanislav Aubrecht 2013-01-21 09:57:44 UTC
Looks like a JDK problem but without reliable steps to reproduce it'll next to impossible to fix...
Comment 8 Miloslav Metelka 2013-01-21 10:45:19 UTC
Sorry, but the lexer warning could only lead to some shifted offsets but it certainly does not cause this focus related problem so editor/lexer category is wrong. As Standa pointed out this looks like a JDK problem so reassigning there.
Comment 9 Stanislav Aubrecht 2013-01-22 09:12:15 UTC
There is another keyboard input related issue: http://netbeans.org/bugzilla/show_bug.cgi?id=225115
Comment 10 Antonin Nebuzelsky 2013-06-21 14:28:35 UTC
Which window manager are you using in your Linux setup?

The following JDK bug describes such problems with enlightment window manager:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=8009224

If that's the case, can you confirm that last JDK8 builds work for you without the problem?
https://jdk8.java.net/download.html
Comment 11 rtuck99 2015-01-12 16:06:26 UTC
It's possible that this issue is related to JDK bug

http://bugs.java.com/bugdatabase/view_bug.do?bug_id=6506617

I just experienced this problem. I was able to use the workaround described there - restart ibus-daemon with 

ibus exit
ibus-daemon &
Comment 12 fer77 2016-01-14 00:30:25 UTC
I got this issue, I am using Netbeans 8 for C++ in Linux, details below:

Netbeans 8.0.2
Product Version: NetBeans IDE 8.0.2 (Build 201411181905)
Java: 1.8.0_40; OpenJDK 64-Bit Server VM 25.40-b14
Runtime: OpenJDK Runtime Environment 1.8.0_40-b10
System: Linux version 3.16.6-2-desktop running on amd64; UTF-8; en_US (nb)
OpenSUSE 13.2 x64

Output windows can process keyboard input, but no source editor can, last time it worked during this session I was navigating with some bookmarks.

Attached thread dump

selfsampler4522238628608715272.npss.7z
Comment 13 fer77 2016-01-14 00:31:19 UTC
I got this issue, I am using Netbeans 8 for C++ in Linux, details below:

Netbeans 8.0.2
Product Version: NetBeans IDE 8.0.2 (Build 201411181905)
Java: 1.8.0_40; OpenJDK 64-Bit Server VM 25.40-b14
Runtime: OpenJDK Runtime Environment 1.8.0_40-b10
System: Linux version 3.16.6-2-desktop running on amd64; UTF-8; en_US (nb)
OpenSUSE 13.2 x64

Output windows can process keyboard input, but no source editor can, last time it worked during this session I was navigating with some bookmarks.

Attached thread dump

selfsampler4522238628608715272.npss.7z
Comment 14 fer77 2016-01-14 00:33:23 UTC
Created attachment 158122 [details]
Thread dump

Adding thread dump for my "test case" http://wiki.netbeans.org/GenerateThreadDump
(see reference in comments to file selfsampler4522238628608715272.npss.7z)
Comment 15 h4kuna 2017-01-18 09:41:51 UTC
I have same problem. In the moment Netbeans looks like everithing is ok, cursor blinking, bud doesn't accept event from keyboard, only events from mouse. I must restart two-three times per day.

Product Version: NetBeans IDE 8.2 (Build 201609300101)
Updates: NetBeans IDE is updated to version NetBeans 8.2 Patch 1
Java: 1.8.0_101; Java HotSpot(TM) 64-Bit Server VM 25.101-b13
Runtime: Java(TM) SE Runtime Environment 1.8.0_101-b13
System: Linux version 3.13.0-107-generic running on amd64; UTF-8; cs_CZ (nb)
User directory: /home/milan/.netbeans/8.2
Cache directory: /home/milan/.cache/netbeans/8.2
Comment 16 jsbjair 2017-09-02 14:12:16 UTC
(In reply to rtuck99 from comment #11)
> It's possible that this issue is related to JDK bug
> 
> http://bugs.java.com/bugdatabase/view_bug.do?bug_id=6506617
> 
> I just experienced this problem. I was able to use the workaround described
> there - restart ibus-daemon with 
> 
> ibus exit
> ibus-daemon &

I have the same problem too, all keyboard input stop to function, but this solution works, and wasn't needed to restart the IDE. 

Product Version: NetBeans IDE 8.2 (Build 201609300101)
Atualizações: Atualizações disponíveis para a versão NetBeans 8.2 Patch 2
Java: 1.8.0_111; Java HotSpot(TM) 64-Bit Server VM 25.111-b14
Runtime: Java(TM) SE Runtime Environment 1.8.0_111-b14
System: Linux version 3.13.0-117-generic running on amd64; UTF-8; pt_BR (nb)
User directory: /home/jair/.netbeans/8.2
Cache directory: /home/jair/.cache/netbeans/8.2
Comment 17 mircea273 2017-11-14 18:30:26 UTC
(In reply to jsbjair from comment #16)

This fix (ibus restart) worked for me too.

Product Version: NetBeans IDE 8.2 (Build 201705191307)
Updates: NetBeans IDE is updated to version NetBeans 8.2 Patch 2
Java: 1.8.0_121; Java HotSpot(TM) 64-Bit Server VM 25.121-b13
Runtime: Java(TM) SE Runtime Environment 1.8.0_121-b13
System: Linux version 3.19.0-93-generic running on amd64; UTF-8; en_US (nb)