It happens on several devices (also ones that have 19H1/19H2 versions).
It's not likely related to poor networking, as the issue is reproduced on networks in different places and different machines, which should have a rather stable network.
In the exact same setups that reproduces the bug, it usually works when trying again straight away and in the following attempts as well (even if we delete the app and reinstall it).
Here is the code:
private readonly SynchronizationContext _syncContext;
private StoreContext _storeContext = null;
public MSStoreActions()
{
_syncContext = SynchronizationContext.Current;
_storeContext = StoreContext.GetDefault();
}
public IAsyncOperation<string> ShowAppRating()
{
Logger.LogFunction();
var taskCompletionSource = new TaskCompletionSource<string>();
_syncContext.Post(async state =>
{
StoreRateAndReviewResult result = await _storeContext.RequestRateAndReviewAppAsync();
Logger.Log($"result={result.Status}");
Logger.Log($"extendedData={result.ExtendedJsonData}");
Logger.Log($"extendedError={result.ExtendedError}");
taskCompletionSource.SetResult(result.ExtendedJsonData);
}, null);
return taskCompletionSource.Task.AsAsyncOperation();
}