source: josm

Revision Log Mode:


Legend:

Added
Modified
Copied or renamed
Diff Rev Age Author
(edit) @18964   3 months GerdP

fix #23440: Validation results may not be refreshed on upload
The patch checks if the validator dialog is already showing. If yes, it is always updated.
An empty dialog is only suppressed when there was no dialog showing and there are no errors and the validation was triggered by the upload action.

(edit) @18963   3 months taylor.smock

Fix #23444: NPE in org.openstreetmap.josm.gui.MapViewState$MapViewEastNorthPoint.<init>

This occurs when an incomplete way is loaded into JOSM (by an .osm file, for
example). This is fixed by checking to see if the way is usable (not incomplete,
not deleted, and more importantly for this ticket, no nodes are incomplete).

This additionally fixes some pmd issues and sonarlint issues.

(edit) @18962   3 months GerdP

see #23397: Improve the results of partial validations

  • don't call endTest() in static method CrossingWays.isSelfCrossing(), this fixes the failing unit test AlignInCircleActionTest
(edit) @18961   3 months GerdP

see #23397: Improve the results of partial validations

  • correct last minute change so that it doesn't use empty collection to filter irrelevant warnings
  • correct usage of isPrimitiveUsable() so that CrossingWays.Boundaries works again (old unit test failed)
  • add unit tests to check partial validation of DuplicateWay and CrossingWays gives expected results
(edit) @18960   3 months GerdP

fix #23397: Improve the results of partial validations

  • pass also parent ways and relations of uploaded/selected objects to the testers, child objects are already added, this allows to find e.g. overlapping polygons problems with tags in members of relations
  • let CrossingWays find a problem if at least one of the crossing ways is in the partial selection.
  • let DuplicatWays find a problem if at least one of the duplicated ways is in the partial selection
  • add code to filter the detected issues so that those issues which are clearly not related to the original list of objects are removed. A few issues from mapcss tests may remain.
  • add new preference validator.partial.add.parents to disable the addition of parent objects, default is enabled
  • add new preference validator.partial.removeIrrelevant to disable the filtering of irrelevant errors, default is enabled
  • duplicated code to call AggregatePrimitivesVisitor was moved to ValidationTask
(edit) @18959   3 months GerdP

fix #23442: Follow line bug when holding F

  • make sure that the node returned by DrawAction.getCurrentBaseNode() is either first or last node of the selected way.
(edit) @18958   4 months taylor.smock

Fix #23418: Improve unit test consistency when run with non-English locales

This also fixes some tests that fail when run individually.

(edit) @18957   4 months GerdP

see #20405: simplify code

(edit) @18956   4 months GerdP

fix #20405: History browser for complex relations requires lots of memory

  • avoid to create equal instances of RelationMemberData. This is simple and very effective when relations have many versions as most members are the same in each version
(edit) @18955   4 months GerdP

see #23427: remove obsolete and unintended code from experiment

(edit) @18954   4 months GerdP

fix #23427 load session performance strongly depends on order of layers
The patch

  • removes the duplicated code regarding XPath and calls existing method OsmDataSessionImporter.extractFileName() instead
  • improves that method to first try to find a "file" node given the current element before falling back to the possibly very slow XPath evaluate call (not sure if the XPath part is still needed, it is never used in my example).
(edit) @18953   4 months taylor.smock

remove TLD from IANA

(edit) @18952   4 months GerdP

see #23430: Resetting preference validator.selectionFilter results in broken validator

  • improve performance: only call tree.setFilter() when really needed, as it always triggers buildTree()
(edit) @18951   4 months GerdP

fix #23430: Resetting preference validator.selectionFilter results in broken validator

  • always set filter when selection was changed
  • updateSelection when preferences were changed so that a change of the preference validator.selectionFilter is applied immediately
(edit) @18950   4 months taylor.smock

ValidatorCLI: Fix an NPE when run prior to any call to Territories.initialize

There is currently no good way to see if the Territories data is initialized.
This does mean that tests will take a little bit longer.

(edit) @18949   4 months GerdP

Improve reaction time when user presses cancel while a session is loaded

(edit) @18948   4 months GerdP

fix #23423 Memory leak: Markerlayer doesn't remove MouseListener

  • add removeMouseListener() call in destroy()
(edit) @18947   4 months GerdP

fix memory leak, ImgDisplay.destroy() was only called when at least one image was viewed

(edit) @18946   4 months GerdP

see #23359: revert changes from r18924 as they are now obsolete

(edit) @18945   4 months GerdP

fix #22819: JOSM shows geotagged images in the wrong location

  • if a new image should be shown, make sure that we don't show the previous one. Instead, show only the loading message.
(edit) @18944   4 months GerdP

fix #22806 Cannot disable tabs in image viewer and #22860 Geotagged Images dialog confuses tabs
If preference geoimage.viewer.show.tabs=false is set, make sure that only the recent image is selected

(edit) @18943   4 months GerdP

fix #23417: Load images from Wikimedia Commons can cause crash report

  • disable the action when last layer was closed

This requires special action in layerRemoving(), so default listeners in JosmAction are no longer needed

(edit) @18942   4 months GerdP

fix #23419: Memory leak in SessionSaveAction

  • don't keep references to the layers
(edit) @18941   4 months GerdP

fix #23408

  • fix crash when lots of GeoImageLayer layers are closed without and no data layer is open
  • don't show save layers dialog when no save or upload action is available.
(edit) @18940   4 months GerdP

see #23415/r18939 ( MarkerLayerTest still failed)

  • restore most of the old behaviour of destroy() and destroyInstance() as it was before r18937
  • don't call destroy inside updateLayers() as this code is also used in unit tests
  • check in layerRemoving() if dialog should be destroyed

Hope this now fixes all unit tests. Some of them fail on my machine because the expect to run in English while my machine is configured to German. Have to find out where this can be changed...

(edit) @18939   4 months taylor.smock

See #23415/r18938: Use titleBar instead of dialogsPanel

(edit) @18938   4 months taylor.smock

See #23415: Fix unit tests from r18937

(edit) @18937   4 months GerdP

fix #23415 and #23414, patch 23415-v2.patch

  • fixes issues where the wrong image is shown
  • properly destroys the toggle dialog and the toggle action when no more geotagged image layer is available
  • make sure that the title is updated when no image is selected (instead of possibly showing an image name from a closed layer
(edit) @18936   4 months taylor.smock

Fix #23416: When GitHub CI fails, the hs_err dumps should be included in the test artifacts

(edit) @18935   4 months taylor.smock

Fix #23399: Simplify way crashes

This was primarily caused by selection updates occurring while the commands were generated. The fixes could be any of the following:

  • Synchronized collections
  • New list
  • Avoiding selection updates

The last option was taken for the following reasons:

  • Avoiding a StackOverflow exception when many ways are being simplified
  • Reduced memory allocations (>11GB to <250MB)
  • Reduced CPU cycles
(edit) @18934   4 months taylor.smock

Fix #23362: Cannot close ImageViewerDialog when multiple image layers are available

(edit) @18933   4 months taylor.smock

i18n update

(edit) @18932   4 months stoecker

fix some CI warnings

(edit) @18931   4 months stoecker

pmd

(edit) @18930   4 months stoecker

checkstyle

(edit) @18929   4 months stoecker

proper interface

(edit) @18928   4 months stoecker

fix #23373 - Taiwan maps nowadays use another certificate

(edit) @18927   4 months taylor.smock

Fix #23316: MarkerLayer should return an empty list instead of a list with a single null value when the entry is null

(edit) @18926   4 months taylor.smock

Fix #23367: Don't try to load too many tiles

In this case, we are catching an ArithmeticException when an integer overflow occurs.

Additionally, fix some lint issues and update some dependencies:

  • org.openstreetmap.jmapviewer:jmapviewer: 2.18 -> 2.19
  • ch.poole:OpeningHoursParser: 0.27.1 -> 0.28.0
  • nl.jqno.equalsverifier:equalsverifier: 3.15.4 -> 3.15.5
  • com.google.errorprone:error_prone_core: 2.23.0 -> 2.24.0
(edit) @18925   5 months taylor.smock

See #23290 comment 10: Fix missing s in region for payment cards

(edit) @18924   5 months taylor.smock

Fix #23359: Don't keep images in memory when the ImageViewerDialog is closed

(edit) @18923   5 months taylor.smock

Fix #16485: Ensure windows lose always-on-top status when JOSM loses focus

Also fix some spotbugs/sonarlint issues.

(edit) @18922   5 months taylor.smock

Fix #23302: Create a preference for address duplicate detection to include buildings and POIs (patch by zyphlar, modified)

Modifications are as follows:

  • Add test case
(edit) @18921   5 months taylor.smock

Fix #23308: Fix a false positive for "Water area inside water area" validation (patch by gaben, modified)

A coastline as an area follows the right-side rule like coastlines as a way.
This means that a water area inside the area, as defined for almost every other
area tag, may be valid, depending upon the directionality of the coastline way.

Modifications are as follows:

  • Look for water areas inside oceans (coastline is drawn in clockwise direction)
    • This is anticipated to be a rare occurrence since most coastlines are expected to be part of a large area.
  • Add non-regression test
  • Keep previous spacing for easier svn blame usage
(edit) @18920   5 months taylor.smock

Fix #23067: Don't warn on unisex, female, and male tag combinations for shop=hairdresser

male=* and female=* is more verbose than unisex=* and also more precise.
From the osmwiki:Key:unisex wiki page:

unisex=yes always means a gender-neutral facility. Gender segregated facilities
(e.g. toilets) should be tagged female=yes + male=yes. Usage of the unisex=yes
tag for gender segregated features contradicts with the general meaning of the
term "unisex".

(edit) @18919   5 months taylor.smock

Fix #23339: Improve preset for charging stations (patch by dbrgn)

  • Generic fee -> fee + parking:fee (the two may be separate)
  • capacity is now free-form text (some charging stations can have 20 or more chargers)
  • covered has been added
  • Remove non-vehicle transport methods like bicycle and scooter (preset is in the vehicle group)
  • Unused socket types have been removed
  • Replace voltage and amperage with max socket output power
  • Update authentication methods
  • Add level for when the charging station is in a multi-level parking garage
(edit) @18918   5 months taylor.smock

Fix #23290: Validate the regions a tag is expected to be in (patch by Sarabjeet108, modified)

Modifications are as follows:

  • Allow the use of the new region attributes for keys inside a preset
  • Basic tests

regions comes from Vespucci's extensions: https://vespucci.io/tutorials/presets/#extensions

(edit) @18917   5 months taylor.smock

since_xxx.py: Add optional parameter for changesets

(edit) @18916   5 months taylor.smock

See GitHub #133: Add name for Castilla–La Mancha in boundaries.osm (patch by grischard)

(edit) @18915   5 months taylor.smock

remove TLD from IANA

(edit) @18914   5 months taylor.smock

Fix #22546: Warn about floating railway switches and crossing (patch by Famlam)

railway=switch and railway=crossing should always be connected to a railway;
neither can exist without a railway line as they are physical features of the
railway.

(edit) @18913   5 months taylor.smock

See #22596: Some hosts redirect to another host for authentication (patch by hhtznr, modified)

This lets plugins do authentication with hosts that redirect to another host
for authentication.

(edit) @18912   5 months taylor.smock

Fix #23227: Use the appropriate Bing layer

Microsoft guidance indicates that they do not want us to use the old Aerial
layer. This appears to be due to increasing usage of their API and their desire
to separate free usage from paid usage.

(edit) @18911   5 months taylor.smock

Fix #23113: Use default methods from JMapViewer

(edit) @18910   5 months taylor.smock

Update Tag2Link PREF_SOURCE variable

(edit) @18909   5 months taylor.smock

Dependency updates

ivy.xml

  • org.openstreetmap.jmapviewer:jmapviewer: 2.16 -> 2.18
    • Add default methods to JMapViewer TileSource interface
    • Modularize for Java 9+
    • Add layer option for Bing Imagery
  • jakarta.json:jakarta.json-api: 2.1.2 -> 2.1.3
  • org.eclipse.parsson:parsson: 1.1.4 -> 1.1.5
  • org.apache.commons:commons-jcs3-core: 3.1 -> 3.2
  • org.apache.commons:commons-compress: 1.23.0 -> 1.25.0
  • com.drewnoakes:metadata-extractor: 2.18.0 -> 2.19.0
  • ch.poole:OpeningHoursParser: 0.27.0 -> 0.27.1
  • org.webjars.npm:tag2link: 2022.11.28 -> 2023.11.21
    • This now parses OSM Wiki Data Items directly instead of via the (outdated) sophox API
  • org.apache.commons:commons-lang3: 3.13.0 -> 3.14.0
  • org.jacoco:org.jacoco.ant: 0.8.10 -> 0.8.11
    • Official Java 21 support
  • com.github.spotbugs:spotbugs-annotations: 4.7.3 -> 4.8.3
  • io.github.classgraph:classgraph: 4.8.162 -> 4.8.165
  • JUnit platform: 1.10.0 -> 1.10.1
  • JUnit packages: 5.10.0 -> 5.10.1
  • nl.jqno.equalsverifier:equalsverifier: 3.15.1 -> 3.15.4

tools/ivy.xml

  • net.java.dev.javacc:javacc: 7.0.12 -> 7.0.13
  • com.guardsquare:proguard-ant: 7.4.0-beta02 -> 7.4.1
  • com.github.spotbugs:spotbugs-annotations: 4.7.3 -> 4.8.3
  • com.google.errorprone:error_prone_core: 2.22.0 -> 2.23.0
(edit) @18908   5 months taylor.smock

Fix #23341: Don't set paintstyles to nothing when paintstyles haven't been modified by the user

The original fix (r18907) was a short-term fix that reset paintstyles to the
default if the list was empty. This is not ideal, since people who have
deliberately made their paintstyle list empty now have to clear it every time
JOSM starts.

This patch fixes that by only attempting to remove potlatch2 if the user has
previously modified the painstyle list. The previous patch was necessary to get
most users back to a "known good" state, especially those that have never used
the style settings.

(edit) @18907   5 months taylor.smock

Fix #23341: Paintstyles are wiped when updating when the user has never explicitly changed the styles

(edit) @18906   5 months stoecker

add missing APPLE_ID, see #23335

(edit) @18905   5 months taylor.smock

i18n update

(edit) @18904   6 months stoecker

don't hardcode ID

(edit) @18903   6 months taylor.smock

Fix #23309: NPE in GeoPropertyIndex$GPLevel.getBounded when called by Territories.getRegionalTaginfoUrls

Territories.getRegionalTaginfoUrls uses Collection.parallelStream
which could cause the following race conditions:

  • children is reinitialized after the null check, potentially causing an NPE due to a different null check becoming false after it was checked. Solution: either synchronize the creation of children or have a local variable.
  • Two threads could generate a child and then generate children of children, creating a split tree hierarchy, only one of which would be kept. Solution: synchronize the creation of the child nodes

For both of the new synchronized methods, we could use a safe double-lock
idiom if there ends up being performance issues. This probably won't be the case.
Profiling JOSM start to end with Mesa County, CO (+ validations) did not show
that the modified methods were "hot".

This additionally fixes some lint issues and converts some package-private
methods to use ILatLon instead of LatLon.

(edit) @18902   6 months taylor.smock

remove TLD from IANA

(edit) @18901   6 months taylor.smock

remove TLD from IANA

(edit) @18900   6 months GerdP

fix #23310: TagChecker: Correct "peek" to "peak"
Patch provided by hhtznr

(edit) @18899   6 months stoecker

combine two loops (remove sonar warning)

(edit) @18898   6 months taylor.smock

See #18866: Remove Potlatch2 from the built-in styles

Remove an icon that was missed for the Potlatch2 style.

(edit) @18897   6 months taylor.smock

Add/Ignore popular tags

Add

  • informal=no -- this appears to be used for trails that appear to be informal=yes but are not.
  • highway=trailhead
    • Icon drawn by taylor.smock
  • amenity=letterbox
    • Additionally adds post:* tags, copied from addr:* tags
    • Icon drawn by taylor.smock; a better icon would be much appreciated
  • building=stadium -- added as a checkbox to leisure=stadium and the default building preset

Ignore

  • building=no -- this is already covered in unnecessary.mapcss
(edit) @18896   6 months taylor.smock

Fix #23235: Revert r18869

The URI specification only allows for ascii characters.
See https://datatracker.ietf.org/doc/html/rfc3986#section-1.2.1.

(edit) @18895   6 months taylor.smock

Fix #23057: data layers should be selected next, not non-data layers (patch by gaben, modified)

Modifications are as follows:

  • Fix test pollution uncovered by change in non-obvious determinate order of tests
  • Fix code so that MainLayerManagerTest.testRemoveLayerUnsetsActiveLayer passes
(edit) @18894   6 months taylor.smock

remove TLD from IANA

(edit) @18893   6 months taylor.smock

Fix #16567: Upgrade to JUnit 5

JOSMTestRules and JOSMTestFixture can reset the default JOSM profile, which can
be unexpected for new contributors. This updates all tests to use JUnit 5 and
the new JUnit 5 annotations.

This also renames MapCSSStyleSourceFilterTest to MapCSSStyleSourceFilterPerformanceTest
to match the naming convention for performance tests and fixes some lint issues.

This was tested by running all tests individually and together.

(edit) @18892   6 months taylor.smock

Fix #23257: MVTTileTest has an infrequently hit race condition (patch by marcello, modified)

The race condition is dependent upon calculation speed; if the layers get loaded
prior to the image loading, it is possible for us to get to the point where
we expect the image to be loaded, but it isn't yet.

Modifications are as follows:

  • Reinitialize tileSource and loader before each test, but initialize the cache once and clear that between tests.
(edit) @18891   6 months taylor.smock

Fix #23256: AbstractPrimitive::putAll not updating values (patch by marcello)

(edit) @18890   6 months taylor.smock

Fix #23256: AbstractPrimitive::putAll not updating values (patch by marcello, modified)

Modifications are as follows:

  • Unit tests were split out into discrete units for better test feedback in the future.
(edit) @18889   6 months taylor.smock

See #17858: Add Java 17 as an option for the Java version in deb packages

By depending upon default-jre with a version specification, we can avoid
hardcoding many specific Java JREs versions via |. Instead, we just indicate
that the default-jre must be >= 17 or the currently installed version must be
Java 8 compatible. This will change on 2023-12-31 when Java 8 support is dropped.
See #17858 for details.

This was verified via the following in an Ubuntu 23.04 container:

  1. curl -O https://josm.openstreetmap.de/apt/pool/universe/j/josm-latest/josm-latest_1.5.svn18887_all.deb
  2. ar x josm-latest_1.5.svn18887_all.deb control.tar.xz
  3. tar xf control.tar.xz control
  4. Edit control to match new control
  5. xz --decompress control.tar.xz && tar uvf control.tar control && xz control.tar
  6. ar r josm-latest_1.5.svn18887_all.deb control.tar.xz

The resulting deb package was then tested against Debian Buster, Bullseye,
Bookworm, Trixie, and Sid, along with Ubuntu 18.04, 20.04, 22.04, 23.04, and
23.10 with
podman run -it --rm --volume $(pwd):/mnt ${IMAGE} /usr/bin/bash -c "apt update && apt install -y /mnt/josm-latest_1.5.svn18887_all.deb && josm-latest --version && josm-latest --status-report"

(edit) @18888   6 months taylor.smock

See #18866: Remove Potlatch2 from the built-in styles

This fixes the MapRendererPerformanceTest that failed due to depending upon the
number of built-in paintstyles.

(edit) @18887   6 months taylor.smock

See r18885: Fix default hasTagDifferent implementation.

(edit) @18886   6 months taylor.smock

Fix #18866: Remove Potlatch2 from the built-in styles. It has been replaced with wiki:Styles/Potlatch2.

Users who have the built-in Potlatch2 style enabled when they upgrade to this
revision or later will automatically have wiki:Styles/Potlatch2 added to their
style list and enabled.

(edit) @18885   6 months taylor.smock

Fix #23252: Ignore line_management=transition|termination in UnconnectedPowerTest (patch by gaben, modified)

Modifications are as follows:

  • Lint fixes
  • Performance enhancements (profiling done with validator and an overpass download of Mesa County, Colorado)
    • Iterating over an array is much more efficient than using streams. For methods that may be frequently called, using Arrays.stream is currently not a good idea.
      • hasTagDifferent: 2.09 MB -> 0
      • hasTag: 125MB -> 0
      • hasKey: 879MB -> 0
(edit) @18884   6 months taylor.smock

See #23253: Ignore landuse=paddy

The tag usage currently appears to be from a mass edit, and is largely done by a
single user. The usages are also geographically concentrated in South Korea.

With that said, the wiki page (osmwiki:Tag:landuse=paddy) is pretty good.

(edit) @18883   6 months GerdP

Mention that Douglas-Peucker is used

(edit) @18882   7 months stoecker

showtime was another CBS tld and is gone as well

(edit) @18881   7 months stoecker

add import as other name for source

(edit) @18880   7 months stoecker

cbs domain died

(edit) @18879   7 months taylor.smock

See #23125: Add secret to GH action environment

(edit) @18878   7 months taylor.smock

Fix #23125: Update macos notarization

(edit) @18877   7 months taylor.smock

See #23220: Use jakarta.annotation instead of javax.annotation (JSR305)

jsr305 should be removed in June 2024 to give plugins time to migrate.

Some lint issues were also fixed.

(edit) @18876   7 months taylor.smock

See #23238: Some MapCSS functions cause NPEs when part of fixAdd

JOSM_Search doesn't trigger the issue unless the search string is non-empty.

(edit) @18875   7 months taylor.smock

Fix #23238: Some MapCSS functions cause NPEs when part of fixAdd

(edit) @18874   7 months taylor.smock

remove TLD from IANA

(edit) @18873   7 months taylor.smock

Fix #23240: Change tag man_made=mineshaft to man_made=heap for new man_made=heap preset

(edit) @18872   7 months stoecker

add man_made=heap

(edit) @18871   7 months taylor.smock

See #23218: Use newer error_prone versions when compiling on Java 11+

error_prone 2.11 dropped support for compiling with Java 8, although it still
supports compiling for Java 8. The "major" new check for us is NotJavadoc since
we used /** in quite a few places which were not javadoc.

Other "new" checks that are of interest:

  • AlreadyChecked: if (foo) { doFoo(); } else if (!foo) { doBar(); }
  • UnnecessaryStringBuilder: Avoid StringBuilder (Java converts + to StringBuilder behind-the-scenes, but may also do something else if it performs better)
  • NonApiType: Avoid specific interface types in function definitions
  • NamedLikeContextualKeyword: Avoid using restricted names for classes and methods
  • UnusedMethod: Unused private methods should be removed

This fixes most of the new error_prone issues and some SonarLint issues.

(edit) @18870   7 months taylor.smock

See #16567: Update to JUnit 5

This converts most tests to use @Annotations. There are also some performance
improvements as it relates to tests.

(edit) @18869   7 months taylor.smock

Fix #23235: Allow unicode characters in URL paths

(edit) @18868   7 months taylor.smock

See #16207: Keep track of download area for notes

(edit) @18867   7 months taylor.smock

See #16567: Update to JUnit 5

This adds the @TaggingPresets annotation used by r18866 (see #23196). The
annotation tries to only initialize the presets when the current preset list does
not have the same hashCode as the default preset list. In order for this to work,
TaggingPresets#getTaggingPresets had to return a List (the method contract
has not changed), which calculates the hashCode in a deterministic manner.

(edit) @18866   7 months taylor.smock

Fix #23196: DataIntegrityProblemException: Primitive must be part of the dataset

It turns out that FilterModel doesn't care whether a primitive's referrers are
in the dataset or not.

This additionally adds a non-regression test and modifies WindowMocker to cover
some more headless exceptions. This additionally lets us stop mocking
ExtendedDialog#setupDialog.

(edit) @18865   7 months stoecker

see #23228 - i18n update

Note: See TracRevisionLog for help on using the revision log.