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 168193 - NullPointerException at org.netbeans.modules.python.editor.PythonAstUtils.getNameRange
Summary: NullPointerException at org.netbeans.modules.python.editor.PythonAstUtils.get...
Status: VERIFIED FIXED
Alias: None
Product: python
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: Jenselme
URL: http://statistics.netbeans.org/except...
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-06 20:15 UTC by gentoo_daemon
Modified: 2015-11-27 22:26 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 148657


Attachments
stacktrace (1.24 KB, text/plain)
2009-07-06 20:17 UTC, gentoo_daemon
Details
stacktrace (1.18 KB, text/plain)
2010-05-25 16:38 UTC, paulr5930
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gentoo_daemon 2009-07-06 20:15:51 UTC
Build: NetBeans IDE 6.7 (Build 200906241340)
VM: Java HotSpot(TM) Client VM, 11.0-b16, Java(TM) SE Runtime Environment, 1.6.0_11-b03
OS: Linux, 2.6.27-14-generic, i386

User Comments:
gentoo_daemon: I had the "display documentation next to completion" option enabled. It crashed after I hit ctrl+space to complete.

GUEST: was writing something like that:
self.__wait_for_event

then double clicked od "__wait ofr event" and then press ctrl+v

GUEST: just have entered non-ascii data in class method name :)



Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.modules.python.editor.PythonAstUtils.getNameRange(PythonAstUtils.java:277)
        at org.netbeans.modules.python.editor.PythonOccurrencesMarker.run(PythonOccurrencesMarker.java:236)
        at org.netbeans.modules.python.editor.PythonOccurrencesMarker.run(PythonOccurrencesMarker.java:69)
        at org.netbeans.modules.gsfret.editor.semantic.MarkOccurrencesHighlighter.processImpl(MarkOccurrencesHighlighter.java:173)
        at org.netbeans.modules.gsfret.editor.semantic.MarkOccurrencesHighlighter.run(MarkOccurrencesHighlighter.java:113)
        at org.netbeans.modules.gsfret.editor.semantic.MarkOccurrencesHighlighter.run(MarkOccurrencesHighlighter.java:80)
Comment 1 gentoo_daemon 2009-07-06 20:17:15 UTC
Created attachment 84413 [details]
stacktrace
Comment 2 Exceptions Reporter 2009-08-28 19:41:30 UTC
This issue already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=148657
Comment 3 paulr5930 2010-05-25 16:38:28 UTC
Created attachment 99451 [details]
stacktrace

I was typing in the editor, had some bad syntax at the moment.
Comment 4 Lou Dasaro 2015-09-13 05:04:23 UTC
Because these reports are all many years old, I am going to resolve this as FIXED.
If this bug occurs again, please make sure you are using Netbeans IDE 8.1 with the associated Plugin version 0.150701 or greater before creating a NEW bug.
Thank you.
Comment 5 Jenselme 2015-10-02 15:25:55 UTC
Just encountered it today. Working on a patch now.

Type the following code to reproduce:

class Toto:
def __init__(self):
toto = self.()

The execption should be thrown when you add the opening parenthesis.

Exception: http://statistics.netbeans.org/analytics/exception.do?id=796137
Comment 6 Jenselme 2015-10-02 15:36:20 UTC
changeset:   18334:2f08b52531cc
bookmark:    main
tag:         tip
user:        Julien Enselme <jenselme@netbeans.org>
date:        Fri Oct 02 17:29:02 2015 +0200
summary:     #168193 Fix NullPointerException at org.netbeans.modules.python.editor.PythonAstUtils.getNameRange

Downgrading priority to P4. This should be close with the next release of  nbpython.
Comment 7 Jenselme 2015-11-27 16:50:46 UTC
Presumed fixed in Python .151118 (for IDE 8.1)