Modify ↓
Opened 6 years ago
Closed 5 years ago
#16921 closed defect (fixed)
Calling SyncEditorLayerIndex.groovy creates unneeded preferences file and then throws NPE doing so
Reported by: | stoecker | Owned by: | team |
---|---|---|---|
Priority: | minor | Milestone: | 19.10 |
Component: | Core | Version: | |
Keywords: | Cc: |
Description (last modified by )
2018-10-30 18:43:15.956 INFO: Missing preference file '/root/.config/JOSM/preferences.xml'. Creating a default preference file. Caught: java.lang.NullPointerException java.lang.NullPointerException at org.openstreetmap.josm.data.preferences.PreferencesWriter.write(PreferencesWriter.java:59) at org.openstreetmap.josm.data.Preferences.save(Preferences.java:359) at org.openstreetmap.josm.data.Preferences.save(Preferences.java:333) at org.openstreetmap.josm.data.Preferences.putSetting(Preferences.java:598) at org.openstreetmap.josm.spi.preferences.AbstractPreferences.put(AbstractPreferences.java:25) at org.openstreetmap.josm.spi.preferences.AbstractPreferences.putInt(AbstractPreferences.java:55) at org.openstreetmap.josm.data.Preferences.save(Preferences.java:347) at org.openstreetmap.josm.data.Preferences.save(Preferences.java:333) at org.openstreetmap.josm.data.Preferences.init(Preferences.java:487) at org.openstreetmap.josm.data.Preferences$init.call(Unknown Source) at SyncEditorLayerIndex.main(SyncEditorLayerIndex.groovy:64) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
Attachments (0)
Change History (8)
comment:1 by , 6 years ago
Description: | modified (diff) |
---|---|
Summary: | Calling SyncEditorLayerIndex.groovy creates uneeded preferences file and ven crash doing so → Calling SyncEditorLayerIndex.groovy creates unneeded preferences file and then throws NPE doing so |
comment:2 by , 6 years ago
comment:3 by , 6 years ago
Is that the reason for - W: No configuration settings found. Using hardcoded default values for all pools.
in nearly every status report?
comment:5 by , 6 years ago
Milestone: | 18.11 → 18.12 |
---|
comment:6 by , 6 years ago
Milestone: | 18.12 |
---|
comment:7 by , 5 years ago
Milestone: | → 19.10 |
---|---|
Priority: | normal → minor |
Note:
See TracTickets
for help on using tickets.
I added the preferences setup code in r13767 as the code relied on having initialized preferences. Maybe there's a better way to fix this (it was the quickest solution at that time)