Skip to content

Conversation

@ameerabdul
Copy link

@ameerabdulameerabdul commented Mar 10, 2025

Summary

  • Creating a new DataLoader with newMappedDataLoaderWithTry and batchingEnabled as false and cachingEnabled as true.
  • This will cause the value to which is already a Try instance to be wrapped again in another Try.succeed causing class cast exception

@ameerabdulameerabdul marked this pull request as ready for review March 10, 2025 17:28
valuesInKeyOrder.set(listIndex, Try.succeeded(v));
}
}
List<V> assembledValues = valuesInKeyOrder.stream().map(Try::get).collect(toList());
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this might be a bigger change as I can't go a Try.get on failed instances

@bbakerman
Copy link
Member

Can we please have a unit test showing this working.

Its not enough to fix the code, we need to lock in that behavior

@bbakerman
Copy link
Member

I managed to do a reproducton of this. I can confirm its a genuine problem but this is not the fix for it

@github-actions
Copy link

Hello, this pull request has been inactive for 60 days, so we're marking it as stale. If you would like to continue working on this pull request, please make an update within the next 30 days, or we'll close the pull request.

@github-actions
Copy link

Hello, as this pull request has been inactive for 90 days, we're closing this pull request. We always welcome contributions, and if you would like to continue, please open a new pull request.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@ameerabdul@bbakerman@dondonz