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.
Summary: | ClassNotFound exception - Cannot invoke Encapsulate field hint | ||
---|---|---|---|
Product: | platform | Reporter: | Tomas Hurka <thurka> |
Component: | Module System | Assignee: | Jesse Glick <jglick> |
Status: | VERIFIED FIXED | ||
Severity: | blocker | CC: | jlahoda, jtulach |
Priority: | P2 | Keywords: | REGRESSION |
Version: | 5.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | |
Bug Depends on: | |||
Bug Blocks: | 54123 | ||
Attachments: | Testcase (patch) that shows the problem. |
Description
Tomas Hurka
2005-05-18 09:37:07 UTC
This a regression caused by integration of issue #54123. Not a core problem. Modules are responsible for declaring their dependencies correctly. Track down which module is attempting to use a package which is forbidden to it, and fix the problem. (I cannot offer any better suggestion without a stack trace.) As far as I know, the problem is that: 1. the refactoring module declares public packages for friends (Java hints is not a friend for refactoring module). 2. the Java hints module declares implementation dependency on the refactoring module. 3. the Java hints module is not granted the access to classes from the refactoring module in spite of it declares the implementation dependency. I suppose that the implementation dependecy should allow unrestricted access to all module's classes. I am attaching a test case the shows the problem. Created attachment 22187 [details]
Testcase (patch) that shows the problem.
I guess Yarda's patch for issue #54123 was wrong then. It would incorrectly refuse access in the case that a module with an impl dep on a module with friend packages tried to access one of those friend packages without being a friend. Easy to correct though. Nonetheless please fix the java/hints -> refactoring dep to use normal friend access, not impl deps. Should be fixed now. BTW thanks Jan for the test. committed * Up-To-Date 1.66 core/src/org/netbeans/core/modules/ModuleManager.java committed * Up-To-Date 1.42 core/test/unit/src/org/netbeans/core/modules/ModuleManagerTest.java committed * Up-To-Date 1.27 core/test/unit/src/org/netbeans/core/modules/build.xml added * Up-To-Date 1.1 core/test/unit/src/org/netbeans/core/modules/jars/uses-api-impl-dep-for-friends.mf Thanks for fixing this so quickly that I really could not do it sooner. Oh no problem. It was actually pretty easy with the test already written. :-) Can someone verify that it is working correctly for java/hints? Verified. |