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 187431 - NullPointerException at org.netbeans.modules.php.editor.model.impl.ModelVisitor.extendedElements
Summary: NullPointerException at org.netbeans.modules.php.editor.model.impl.ModelVisit...
Status: VERIFIED FIXED
Alias: None
Product: php
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: All All
: P3 normal (vote)
Assignee: rmatous
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-10 13:14 UTC by jonavogt
Modified: 2010-07-08 15:17 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 170559


Attachments
stacktrace (2.14 KB, text/plain)
2010-06-10 13:15 UTC, jonavogt
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jonavogt 2010-06-10 13:14:57 UTC
This issue was reported manually by jonavogt.
It already has 5 duplicates 


Build: NetBeans IDE Dev (Build 2010-06-10_09-03-53 )
VM: OpenJDK Client VM, 14.0-b16, OpenJDK Runtime Environment, 1.6.0_18-b18
OS: Linux

User Comments:
jonavogt: Switched Tabs after coming from external

jonavogt: Tested other version

jonavogt: Codecompletion kicked in

jonavogt: NB is not useable... Everwhere you type you'll get this or a similar error... Even
completly crashed my NB




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.php.editor.model.impl.ModelVisitor.extendedElements(ModelVisitor.java:202)
   at org.netbeans.modules.php.editor.model.Model.getExtendedElements(Model.java:70)
   at org.netbeans.modules.php.editor.parser.PHPParseResult.getModel(PHPParseResult.java:92)
   at org.netbeans.modules.php.editor.parser.PHPParseResult.getModel(PHPParseResult.java:82)
   at org.netbeans.modules.php.editor.verification.PHPHintsProvider.computeHints(PHPHintsProvider.java:86)
   at org.netbeans.modules.csl.hints.infrastructure.HintsTask$1.run(HintsTask.java:118)
Comment 1 jonavogt 2010-06-10 13:15:03 UTC
Created attachment 99978 [details]
stacktrace
Comment 2 rmatous 2010-06-10 14:07:20 UTC
Seems like PhpClass.getType return null. Probably it is allowed to return null here. Tomasi, can you check, thanks
Comment 3 rmatous 2010-06-10 14:08:03 UTC
testing for null:
http://hg.netbeans.org/web-main/rev/b676f1173ca5
Comment 4 Tomas Mysik 2010-06-10 14:27:32 UTC
(In reply to comment #2)
> Seems like PhpClass.getType return null. Probably it is allowed to return null
> here. Tomasi, can you check, thanks

It is valid. BTW this needs to be a candidate for 6.9.1.

This bug is similar to bug #187087.
Comment 5 Tomas Mysik 2010-06-10 14:29:56 UTC
(In reply to comment #4)
> (In reply to comment #2)
> > Seems like PhpClass.getType return null. Probably it is allowed to return
> > null here. Tomasi, can you check, thanks
> 
> It is valid. BTW this needs to be a candidate for 6.9.1.

BTW it is PhpVariable.getType(), not PhpClass (so the null is correct).
Comment 6 rmatous 2010-06-10 14:34:17 UTC
this problem doesn't exists in 6.9, I think. Needs to be fixed in 6.9.1 just in case if #186858 should be transplanted into 6.9.1 also
Comment 7 jonavogt 2010-06-10 15:13:04 UTC
Used tried the latest hudson build, I still get a org.netbeans.modules.parsing.spi.ParseException. I checked my reports and saw that there a couple of exceptions that have that error.

170560 170561 170606 for me they look related to this bug. and the last one comes from the latest build.
Comment 8 rmatous 2010-06-11 09:04:16 UTC
not every ParseException is related

should be really fixed in recent builds:
http://bertram.netbeans.org/hudson/job/PHP-build/

but naturally if it happens to you again then reopen it and please attach the exception(or simply use exception reporter) because then we can fix it, thank you
Comment 9 rbalada 2010-06-16 08:57:01 UTC
Please verify bugfix for this bug, so it can be included in release691 repository.

Thanks,
-R
Comment 10 Petr Blaha 2010-06-17 11:51:52 UTC
verified
Comment 11 rbalada 2010-06-21 14:10:17 UTC
main #b676f1173ca5 transplanted to main #d208dc31d572
Comment 12 Jaromir Uhrik 2010-07-08 15:17:49 UTC
Unable to reproduce. Verified in the latest 6.9.1 build:
Product Version: NetBeans IDE 6.9.1 Dev (Build 201007062301)
Java: 1.6.0_20; Java HotSpot(TM) 64-Bit Server VM 16.3-b01-279
System: Mac OS X version 10.5.8 running on x86_64; MacRoman; en_US (nb)