﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
24130	Unexpected error on opening Bing imagery	ChrisBoothroyd@…	team	"==== What steps will reproduce the problem?
1. Start JOSM
2. Download some data from OSM
3. Try to open Bing from Imagery menu.

==== What is the expected result?

Bing imagery opens

==== What happens instead?

""You have encountered a bug in JOSM"" ""An unexpected exception occurred."" appears

==== Please provide any additional information below. Attach a screenshot if possible.

I just updated to 19307 prior to this appearing using Homebrew

{{{
Revision:19307
Build-Date:2025-02-04 10:33:54

Identification: JOSM/1.5 (19307 en_GB) Mac OS X 14.7.3
OS Build number: macOS 14.7.3 (23H417)
Memory Usage: 480 MB / 24576 MB (157 MB allocated, but free)
Java version: 21.0.6+7-LTS, Azul Systems, Inc., OpenJDK 64-Bit Server VM
Look and Feel: com.apple.laf.AquaLookAndFeel
Screen: Display 1 1800x1169x32bpp@120Hz (scaling 2.00×2.00) Display 2 1920x1200x32bpp@60Hz (scaling 1.00×1.00)
Maximum Screen Size: 1920×1200
Best cursor sizes: 16×16→16×16, 32×32→32×32
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_GB
Numbers with default locale: 1234567890 -> 1234567890
VM arguments: [-Djpackage.app-version=19307, -XX:MaxRAMPercentage=75.0, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.apple.eawt=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, -Djpackage.app-path=/Applications/JOSM.app/Contents/MacOS/JOSM]
Dataset consistency test: No problems found

Plugins:
+ HouseNumberTaggingTool (36379)
+ Mapillary (1792)
+ PicLayer (259)
+ apache-commons (36379)
+ apache-http (36379)
+ editgpx (36379)
+ imagery_offset_db (36379)
+ jna (36379)
+ reverter (36379)
+ turnrestrictions (36379)
+ undelete (36379)

Last errors/warnings:
- 00585.711 W: java.io.IOException: Attribution is not loaded yet
- 00585.712 W: java.io.IOException: Attribution is not loaded yet
- 00585.712 W: java.io.IOException: Attribution is not loaded yet
- 00585.712 W: java.io.IOException: Attribution is not loaded yet
- 00585.712 W: java.io.IOException: Attribution is not loaded yet
- 00585.712 W: java.io.IOException: Attribution is not loaded yet
- 00585.713 W: java.io.IOException: Attribution is not loaded yet
- 00585.713 W: java.io.IOException: Attribution is not loaded yet
- 00585.713 W: java.io.IOException: Attribution is not loaded yet
- 00586.786 E: Handled by bug report queue: java.lang.NullPointerException: Cannot invoke ""java.lang.CharSequence.toString()"" because ""<parameter2>"" is null



=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: bing-attribution-loader-timer (148)
java.lang.NullPointerException: Cannot invoke ""java.lang.CharSequence.toString()"" because ""<parameter2>"" is null
	at java.base/java.lang.String.replace(Unknown Source)
	at org.openstreetmap.gui.jmapviewer.tilesources.BingAerialTileSource.getAttributionUrl(BingAerialTileSource.java:134)
	at org.openstreetmap.josm.data.imagery.CachedAttributionBingAerialTileSource.access$100(CachedAttributionBingAerialTileSource.java:37)
	at org.openstreetmap.josm.data.imagery.CachedAttributionBingAerialTileSource$BingAttributionData.isOffline(CachedAttributionBingAerialTileSource.java:82)
	at org.openstreetmap.josm.io.CacheCustomContent.needsUpdate(CacheCustomContent.java:90)
	at org.openstreetmap.josm.io.CacheCustomContent.updateIfRequiredString(CacheCustomContent.java:120)
	at org.openstreetmap.josm.data.imagery.CachedAttributionBingAerialTileSource$AttributionTimerTask.run(CachedAttributionBingAerialTileSource.java:142)
	at java.base/java.util.TimerThread.mainLoop(Unknown Source)
	at java.base/java.util.TimerThread.run(Unknown Source)
}}}
"	defect	closed	normal		Core		duplicate	template_report	
