dtinit / data-transfer-project

The Data Transfer Project makes it easy for platforms to build interoperable user data portability features. We are establishing a common framework, including data models and protocols, to enable direct transfer of data both into and out of participating online service providers.
https://dtinit.org/docs/dtp-what-is-it
Apache License 2.0
3.57k stars 482 forks source link

bugfix: NullPointerExc swallowing real errors #1341

Closed jzacsh closed 6 months ago

jzacsh commented 6 months ago

ImmutableMap is being used to log error cases during a transfer. Unfortunately said error cases are themselves obfuscated by a less interesting NullPointerException due to ImmutableMap receiving nulls.

ImmutableMap doesn't allow null values (see guava's issues 1782) but it's being passed an albumId sometimes set to null. This might be happening in multiple places but I've at least seen it in the primary download/upload loop (on line 588, before this change).