Open GoogleCodeExporter opened 9 years ago
[deleted comment]
I have the same exact issue and no ideas on how to actually fix it. As far as I
have investigated 'delegate' can be null only when
FutureTypeAdapter.setDelegate() was not called OR was called with a 'null'
object. Seems that the latter is impossible to happen as only call to
setDelegate is from Gson.java:355:
for (TypeAdapterFactory factory : factories) {
TypeAdapter<T> candidate = factory.create(this, type);
if (candidate != null) {
call.setDelegate(candidate);
typeTokenCache.put(type, candidate);
return candidate;
}
}
throw new IllegalArgumentException("GSON cannot handle " + type);
But the exception that should be thrown here when no 'candidate' was found in
the loop is also never thrown or is just ignored somewhere else in the code.
I am reproducing this while trying to parse 8 collections of 100 objects in
separate 8 threads. All of the objects are of the same type. I think an
important factor is that it either happens at the very beginning of parsing
process by the first thread of the first collection element or it never happens.
Original comment by maciej.p...@gmail.com
on 17 Feb 2015 at 10:55
Original issue reported on code.google.com by
MhaleK...@gmail.com
on 29 Jan 2015 at 5:26