Skip to content

Commit

Permalink
Removes the try-catch gRPC error TODO
Browse files Browse the repository at this point in the history
This exception should no longer be expected.
  • Loading branch information
CarlosNihelton committed Nov 21, 2023
1 parent 35f819a commit 2ff2787
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions gui/packages/ubuntupro/lib/app.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import 'package:agentapi/agentapi.dart';
import 'package:flutter/material.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:grpc/grpc.dart';
import 'package:provider/provider.dart';
import 'package:ubuntu_service/ubuntu_service.dart';
import 'package:wizard_router/wizard_router.dart';
Expand Down Expand Up @@ -42,14 +41,9 @@ class Pro4WindowsApp extends StatelessWidget {
final client = getService<AgentApiClient>();
final subscriptionInfo =
context.read<ValueNotifier<SubscriptionInfo>>();
// TODO: Remove this try-catch once the agent stop crashing due lack of MS Store access
try {
subscriptionInfo.value =
await client.subscriptionInfo();
} on GrpcError catch (err) {
debugPrint('$err');
debugPrintStack(maxFrames: 20);
}

subscriptionInfo.value = await client.subscriptionInfo();

// never skip this page.
return true;
},
Expand Down

0 comments on commit 2ff2787

Please sign in to comment.