In this case mutating the existing LoadParameters object also modified it it the cache key, and getting a value from the cache with the new cache key returned the value for the old cache key.
Making LoadParameters immutable like EvalEnv would prevent this kind of mistakes.
load_collection
caching was fixed as part of https://github.com/Open-EO/openeo-geotrellis-extensions/issues/74; this made an issue apparent withLoadParameters
: a mutable object that's part of a cache key has some undesired consequences.In this case mutating the existing
LoadParameters
object also modified it it the cache key, and getting a value from the cache with the new cache key returned the value for the old cache key.Making
LoadParameters
immutable likeEvalEnv
would prevent this kind of mistakes.