Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flutter web ReactiveBuilder: Unsupported operation: Platform._operatingSystem #19

Closed
4F2E4A2E opened this issue Apr 7, 2021 · 1 comment

Comments

@4F2E4A2E
Copy link

4F2E4A2E commented Apr 7, 2021

Hello there and thank you for rx_widgets!

On my journey in finding a reactive way of communication and reactive ui in flutter [5], the road led me here, to you guys.

Everything is working fine on iOS, but I just want to report this exception [2] being thrown for this code [1] on web, using latest stable version of flutter [3]:

1: https://github.com/4F2E4A2E/getx-websocket-example/blob/1.0.1/lib/view/detail_v2.dart#L17

...
ReactiveBuilder<UserDataProfile>(
    stream: controller.userDataProfile.stream,
    builder: (BuildContext context, data) {
        return Text(data.name);
    },
),
...

2: Unsupported operation: Platform._operatingSystem

======== Exception caught by widgets library =======================================================
The following UnsupportedError was thrown building StreamBuilder<UserDataProfile>(dirty, state: _StreamBuilderBaseState<UserDataProfile, AsyncSnapshot<UserDataProfile>>#48108):
Unsupported operation: Platform._operatingSystem

The relevant error-causing widget was: 
  ReactiveBuilder<UserDataProfile> getx-websocket-example/lib/view/detail_v2.dart:30:15
When the exception was thrown, this was the stack: 
dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 236:49     throw_
dart-sdk/lib/_internal/js_dev_runtime/patch/io_patch.dart 244:5                  _operatingSystem
dart-sdk/lib/io/platform_impl.dart 56:40                                         get operatingSystem
dart-sdk/lib/io/platform.dart 64:45                                              get _operatingSystem
dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 825:8  get
...
====================================================================================================

======== Exception caught by widgets library =======================================================
Unsupported operation: Platform._operatingSystem
The relevant error-causing widget was: 
  ReactiveBuilder<UserDataProfile> getx-websocket-example/lib/view/detail_v2.dart:17:18

3: flutter version

$ flutter doctor       
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.0.4, on macOS 11.2.3 20D91 darwin-x64, locale en-AT)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[✓] Xcode - develop for iOS and macOS
[✓] Chrome - develop for the web
[✓] Android Studio (version 4.1)
[✓] IntelliJ IDEA Ultimate Edition (version 2019.3.3)
[✓] VS Code (version 1.55.0)
[✓] Connected device (2 available)

• No issues found!
Time: 0h:00m:08s  

4: flutter pub outdated

transitive dependencies:
rxdart           *0.25.0  *0.25.0     *0.25.0     0.26.0   

5: https://stackoverflow.com/questions/66933598/flutter-getx-first-null-value

P.s.: Please also notice [4]

@4F2E4A2E 4F2E4A2E reopened this Apr 12, 2021
@escamoteur
Copy link
Owner

Hi,
sorry for the delay. should be fixed in V4.0.1 attention that is the now null safe version

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants