| Summary: | [nls tooling] "Externalize Strings" throws NPE | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Flavio Donze <flavio.donze> | ||||||
| Component: | Text | Assignee: | Deepak Azad <deepakazad> | ||||||
| Status: | RESOLVED WORKSFORME | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | daniel_megert, deepakazad, remy.suen | ||||||
| Version: | 3.6.1 | ||||||||
| Target Milestone: | --- | ||||||||
| Hardware: | PC | ||||||||
| OS: | Windows XP | ||||||||
| Whiteboard: | |||||||||
| Attachments: |
|
||||||||
|
Description
Flavio Donze
Created attachment 185726 [details]
properties which makes trouble
I am unable to reproduce this. Can you also provide the file from which you are trying to externalize the strings. Also mention what key values you entered in the 'Externalize Strings' dialog. Looking at the code, I do not see how this NPE could occur. Were there some other some other exceptions as well in the error log? (In reply to comment #0) > Root exception: > java.lang.NullPointerException > at > org.eclipse.jdt.internal.corext.refactoring.nls.PropertyFileDocumentModel.unwindEscapeChars(PropertyFileDocumentModel.java:223) > at > org.eclipse.jdt.internal.corext.refactoring.nls.PropertyFileDocumentModel.unwindValue(PropertyFileDocumentModel.java:233) > at > org.eclipse.jdt.internal.corext.refactoring.nls.NLSPropertyFileModifier.addReplaceEdits(NLSPropertyFileModifier.java:169) > at > org.eclipse.jdt.internal.corext.refactoring.nls.NLSPropertyFileModifier.addChanges(NLSPropertyFileModifier.java:99) > at > org.eclipse.jdt.internal.corext.refactoring.nls.NLSPropertyFileModifier.create(NLSPropertyFileModifier.java:76) > at > org.eclipse.jdt.internal.corext.refactoring.nls.NLSRefactoring.createChange(NLSRefactoring.java:240) > at > org.eclipse.ltk.core.refactoring.CreateChangeOperation.run(CreateChangeOperation.java:124) > at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1975) > at > org.eclipse.ltk.internal.ui.refactoring.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:87) > at > org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) > Created attachment 185802 [details]
Configuration Screenshot
This is my configuration.
Strange is already that it says "Entry is missing...", even though they exist.
And "no" there was no other exception, I deleted to log first to get the "clean" exception.
Some more information about my setup:
I also have messages in en, fr and it. But I think Eclipse will only read and work with messages.properties. Should I attach?
As seen in the screen shot the messages are in "com.softmodeler.ui.rcp" in the "com.softmodeler.ui.internal" package.
"com.softmodeler.ui.rcp" depends on "com.softmodeler.ui", which also has a package "com.softmodeler.ui.internal" with messages.properties but the class is called UIMessages. Potential error source?
The exception occurs when Eclipse does not find the entries which are actually there. Otherwise e.g. with new classes, it works.
I can also not reproduce it. If you can reproduce then please attach a test project that allows us to see the issue. |