#15310 closed enhancement (fixed)
The Great Deprecation Cleanup
Reported by: | Don-vip | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 17.12 |
Component: | Core | Version: | |
Keywords: | deprecation | Cc: | jBeata, floscher, michael2402 |
Description (last modified by )
With #15229 + #15182 + #13036 we have deprecated a lot of public APIs.
December 2017 will be time to get rid of them to start 2018 on a clean state :)
Attachments (1)
Change History (58)
comment:1 by , 7 years ago
Description: | modified (diff) |
---|
comment:2 by , 7 years ago
Description: | modified (diff) |
---|
comment:3 by , 7 years ago
follow-up: 5 comment:4 by , 7 years ago
Yes I guessed it would be a huge task. I plan to add this indicator to JOSM-integration job, based on a binary analysis of jar files and not the source code, so we can spot Github plugins too.
By the way I see an increase of plugin incompatibilities (i.e: bug reports coming!). Are you sure you deprecated the preference events without changing a signature?
comment:5 by , 7 years ago
follow-up: 8 comment:6 by , 7 years ago
Cc: | added |
---|
OK. Only these plugins are flagged as currently not binary compatible:
josm-config
: unmaintained, I'm going to remove it from list (Mapbox does not reply to my messages)auto_tools
: https://github.com/mapbox/auto-tools/issues/21ImproveOsm
: jBeataOpenStreetCam
: jBeatascoutsigns
: jBeatafreemapkapor
: https://github.com/FreemapSlovakia/freemapKaPor/issues/9matsim
: https://github.com/matsim-org/josm-matsim-plugin/issues/65
comment:7 by , 7 years ago
The latest version of josm-matsim-plugin
is now successfully compiled against JOSM 12885 (plugin.main.version=12881) without using deprecated methods from JOSM core.
follow-up: 11 comment:8 by , 7 years ago
Replying to Don-vip:
OK. Only these plugins are flagged as currently not binary compatible:
josm-config
: unmaintained, I'm going to remove it from list (Mapbox does not reply to my messages)auto_tools
: https://github.com/mapbox/auto-tools/issues/21ImproveOsm
: jBeataOpenStreetCam
: jBeatascoutsigns
: jBeatafreemapkapor
: https://github.com/FreemapSlovakia/freemapKaPor/issues/9matsim
: https://github.com/matsim-org/josm-matsim-plugin/issues/65
How can you tell?
follow-up: 12 comment:10 by , 7 years ago
jBeata, thanks for updating the Telenav plugins! We try to avoid breaking changes, but sometimes it is not possible. Judging from the plugins in the main repository, I did not expect the refactored API to be used that much.
If we can fix plugins that are broken by JOSM core changes until the subsequent monthly release, this would be ideal. Then the users of the tested versions will not experience any problems, as long as they update their plugins regularly.
Please let us know if you have any suggestions to make this easier.
comment:11 by , 7 years ago
comment:12 by , 7 years ago
Replying to bastiK:
jBeata, thanks for updating the Telenav plugins! We try to avoid breaking changes, but sometimes it is not possible. Judging from the plugins in the main repository, I did not expect the refactored API to be used that much.
If we can fix plugins that are broken by JOSM core changes until the subsequent monthly release, this would be ideal. Then the users of the tested versions will not experience any problems, as long as they update their plugins regularly.
Please let us know if you have any suggestions to make this easier.
No problem, I have added support for also josm-latest for Telenav plugins, but I have encountered some issues with JOSM versioning system. So as a quick fix we have updated the josm-tested library and merged the changes from the josm-latest branch. I'm sending an email with more details to Vincent, since I'm not sure what we did wrong. Sorry for the inconvenience.
comment:13 by , 7 years ago
Let's make a cut:
All methods, classes and fields that are marked deprecated in version 12921 will be removed at the end of December 2017.
For anything deprecated from now on (after r12921), the time of removal is decided later.
comment:14 by , 7 years ago
I think I will have updated all OSM-SVN plugins by the end of the month.
comment:16 by , 7 years ago
step 1 done: removed almost all deprecated APIs except heading()/getDx()/getDy()
(see #14120, need help), everything related to colors (there is migration code and I don't know if we must update it or remove it; Paul I let this to you) and everything related to directories (change quite recent).
Let's see which plugins break now.
follow-up: 29 comment:17 by , 7 years ago
Paul, can you please also take a look to Plugin.copy(String, String)
? It calls a deprecated API, so I didn't remove it. I don't know if you prefer to update the method body or deprecate it as well. It's called only by a single plugin.
comment:19 by , 7 years ago
OK we have the following plugin breakages:
ImproveWay 45 CADTools 33 kendzi3d 30 markseen 18 SeaChart 15 ContourOverlappingMerge 13 tofix 11 osm-obj-info 8 globalsat 8 austriaaddresshelper 7 geotools 6 TombPlugin 4 EasyPresets 3 kartverketimport 2 changesetID 2 ColorPlugin 1
comment:21 by , 7 years ago
A bunch of solved GitHub issues:
https://github.com/kendzi/kendzi3d/issues/71
https://github.com/kendzi/ContourOverlappingMerge/issues/1
https://github.com/kendzi/TombPlugin/issues/19
https://github.com/risicle/josm-markseen/issues/1
Unresolved issues:
https://github.com/mapbox/osm-obj-info/issues/6
https://github.com/aarthykc/changesetID/issues/13
https://github.com/maripo/JOSM_easypresets/issues/28
https://github.com/maripo/JOSM_quicklabel/issues/1
https://github.com/ROTARIUANAMARIA/CADTools/issues/3
comment:25 by , 7 years ago
Another plugin having issues:
https://github.com/gidema/josm-openservices/issues/79
comment:29 by , 7 years ago
Replying to Don-vip:
Paul, can you please also take a look to
Plugin.copy(String, String)
? It calls a deprecated API, so I didn't remove it. I don't know if you prefer to update the method body or deprecate it as well. It's called only by a single plugin.
We can deprecate the method, but it doesn't matter. (Please go ahead, I have no time for JOSM at the moment.)
comment:31 by , 7 years ago
Replying to stoecker:
In 13187/josm:
This affects the mapillary plugin
URL:http://josm.openstreetmap.de/svn/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2017-12-03 18:09:08 +0100 (Sun, 03 Dec 2017) Build-Date:2017-12-03 17:11:49 Revision:13190 Relative:URL: ^/trunk Identification: JOSM/1.5 (13190 de) Windows 10 64-Bit OS Build number: Windows 10 Pro 1709 (16299) Memory Usage: 1485 MB / 3641 MB (996 MB allocated, but free) Java version: 1.8.0_151-b12, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM Screen: \Display0 1680x1050 Maximum Screen Size: 1680x1050 VM arguments: [-Djava.security.manager, -Djava.security.policy=file:<java.home>\lib\security\javaws.policy, -DtrustProxy=true, -Djnlpx.home=<java.home>\bin, -Djnlpx.origFilenameArg=C:\Program Files (x86)\josm-latest-mehr-RAM.jnlp, -Djnlpx.remove=true, -Djava.util.Arrays.useLegacyMergeSort=true, -Djnlpx.heapsize=1024m,4096m, -Djnlpx.splashport=57894, -Djnlpx.jvm=<java.home>\bin\javaw.exe] Dataset consistency test: No problems found Plugins: ... + Mapillary (v1.5.8) ... Last errors/warnings: - E: Fehler beim Laden des Bildes 'Xmas_event.png' - W: Amenity: Could not get presets icon Xmas_event.png - W: No configuration settings found. Using hardcoded default values for all pools. - W: Warnung: Das Absuchen der Datei 'site-svn.openstreetmap.org-_applications_editors_josm_plugins_opendata_modules.txt' nach Modulinformationen ist fehlgschlagen. Überspringe. - E: Handled by bug report queue: org.openstreetmap.josm.plugins.PluginException: In der Erweiterung Mapillary ist ein Fehler aufgetreten.. Ursache: java.lang.reflect.InvocationTargetException. Ursache: java.lang.IllegalArgumentException: No icon provided === REPORTED CRASH DATA === BugReportExceptionHandler#handleException: No data collected. Warning issued by: BugReportExceptionHandler#handleException === STACK TRACE === Thread: AWT-EventQueue-2 (48) of javawsApplicationThreadGroup org.openstreetmap.josm.plugins.PluginException: In der Erweiterung Mapillary ist ein Fehler aufgetreten. at org.openstreetmap.josm.plugins.PluginProxy.handlePluginException(PluginProxy.java:60) at org.openstreetmap.josm.plugins.PluginProxy.mapFrameInitialized(PluginProxy.java:71) at org.openstreetmap.josm.gui.MainPanel.updateContent(MainPanel.java:78) at org.openstreetmap.josm.gui.MainPanel$1.beforeFirstLayerAdded(MainPanel.java:155) at org.openstreetmap.josm.gui.layer.MainLayerManager.realAddLayer(MainLayerManager.java:263) at org.openstreetmap.josm.gui.layer.LayerManager.lambda$addLayer$0(LayerManager.java:217) at org.openstreetmap.josm.gui.util.GuiHelper.runInEDTAndWaitWithException(GuiHelper.java:234) at org.openstreetmap.josm.gui.layer.LayerManager.addLayer(LayerManager.java:217) at org.openstreetmap.josm.gui.layer.LayerManager.addLayer(LayerManager.java:206) at org.openstreetmap.josm.actions.NewAction.actionPerformed(NewAction.java:31) ... Caused by: java.lang.IllegalArgumentException: No icon provided at org.openstreetmap.josm.gui.SideButton.<init>(SideButton.java:43) at org.openstreetmap.josm.plugins.mapillary.gui.MapillaryMainDialog.<init>(MapillaryMainDialog.java:60) at org.openstreetmap.josm.plugins.mapillary.gui.MapillaryMainDialog.getInstance(MapillaryMainDialog.java:139) at org.openstreetmap.josm.plugins.mapillary.MapillaryPlugin.mapFrameInitialized(MapillaryPlugin.java:104) ... 50 more }}
by , 7 years ago
Attachment: | mapillary.JPG added |
---|
comment:32 by , 7 years ago
follow-up: 34 comment:33 by , 7 years ago
Actually because of still limited space consideration in this menu I'd prefer if they add images...
In core are help/next.png
, help/previous.png
already there and the other buttons e.g. could get a red and blue circle?
comment:34 by , 7 years ago
Cc: | added |
---|
Replying to stoecker:
In core are help/next.png, help/previous.png already there and the other buttons e.g. could get a red and blue circle?
@floscher: what do you think?
follow-up: 36 comment:35 by , 7 years ago
Cc: | removed |
---|
Why not allow buttons without icons? Not all developers are graphic designers.
comment:36 by , 7 years ago
Replying to Zverikk:
Why not allow buttons without icons? Not all developers are graphic designers.
Because this menu very often is small and thus the texts get cut. That's the reason why there is a SideButton class at all, so that these menus use the space as optimal as possible.
comment:38 by , 7 years ago
Cc: | added |
---|
comment:41 by , 7 years ago
Beside the two arrows above e.g. following two images could be used:
https://commons.wikimedia.org/wiki/File:Blue_sphere.svg
https://commons.wikimedia.org/wiki/File:Nuvola_apps_krec.svg
They have LGPL license.
comment:42 by , 7 years ago
Fixed in https://github.com/JOSM/Mapillary/commit/b2996cbb57152f14fbe924dcad6725934166f4b2
@floscher: can you please make the release?
comment:43 by , 7 years ago
https://github.com/JOSM/Mapillary/releases/tag/v1.5.9 has been released, so this issue is gone.
One last issue to fix, the performance tests are broken since r13173 but I have difficulties to fix them.
@team: I'd love to get some help here :)
comment:44 by , 7 years ago
Just wanted to give you a short heads-up:
I finished my master thesis last month and should have more free time next year.
I'll have some days time to help cleaning up stuff during the next week, so feel free to assign me a topic (otherwise, I'll search through the ticket list). I'm looking forward to cleaning up some modern code after patching some 13+ year old swing applications at work :D
comment:45 by , 7 years ago
Cc: | added |
---|
comment:46 by , 7 years ago
be nice with old apps, JOSM goes on its 11th year ;)
I'd like some help on two topics if you have some time:
- I have broken performance tests and can't find how to fix them (again a problem of fixtures/state)
- I don't know how to fix the bearing/heading and dx/dy deprecation warnings in plugins
comment:47 by , 7 years ago
OK, then I'll focus on the MapViewState issues ;-)
Do you have a specific plugin file for the deprecation warnings?
comment:48 by , 7 years ago
Sure, you can take a look at Jenkins:
CommandLine.java:294, Java Compiler (javac), Priority: Normale getDx() in ImageryLayer has been deprecated CommandLine.java:294, Java Compiler (javac), Priority: Normale getDy() in ImageryLayer has been deprecated Correlator.java:132, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated OffsetDialogButton.java:146, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated OffsetDialogButton.java:255, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated ImproveWayAccuracyAction.java:462, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated IRSRectifyPlugin.java:56, Java Compiler (javac), Priority: Normale getDx() in ImageryLayer has been deprecated IRSRectifyPlugin.java:57, Java Compiler (javac), Priority: Normale getDy() in ImageryLayer has been deprecated TagRoundaboutAction.java:244, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated TagRoundaboutAction.java:252, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated TagRoundaboutAction.java:253, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated TagRoundaboutAction.java:435, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated TagRoundaboutAction.java:436, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated TagRoundaboutAction.java:546, Java Compiler (javac), Priority: Normale heading(LatLon) in LatLon has been deprecated
Congratulations for your thesis :) Do we have to call you Doctor now? :)
comment:49 by , 7 years ago
I'm not into the heading formula, but from what I understand heading()
should just be -bearing()
, see #12524
No, I won't get a doctors degree.
comment:52 by , 7 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
This ticket is fixed, the remaining deprecated methods come from #14120.
Replying to Don-vip:
Right now, there are 1687 deprecation warnings in the public plugin repository.