Skip to content

device_info_plus plugin is producing build warnings on macos #569

@ekuleshov

Description

@ekuleshov

System info

Issue occurs on: macos
Plugin name: device_info_plus
Plugin version: 3.1.0
Flutter doctor output:

see below

Steps to Reproduce

When device_info_plus plugin is used in the application, build on macos prodices the following warnings when compiling Swift code:

/Users/eu/.pub-cache/hosted/pub.dartlang.org/device_info_plus_macos-2.2.0/macos/Classes/DeviceInfoPlusMacosPlugin.swift:42:27: warning: expression implicitly coerced from 'String?' to 'Any'
            "systemGUID": guid
                          ^~~~
/Users/eu/.pub-cache/hosted/pub.dartlang.org/device_info_plus_macos-2.2.0/macos/Classes/DeviceInfoPlusMacosPlugin.swift:42:27: note: provide a default value to avoid this warning
            "systemGUID": guid
                          ^~~~
                               ?? <#default value#>

Logs

nothing interesting there
No issues found! (ran in 1.4s)
[✓] Flutter (Channel stable, 2.5.3, on Mac OS X 10.15.7 19H1419 darwin-x64, locale en-CA)
    • Flutter version 2.5.3 at /Users/eu/Downloads/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 18116933e7 (5 days ago), 2021-10-15 10:46:35 -0700
    • Engine revision d3ea636dc5
    • Dart version 2.14.4

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    • Android SDK at .../android-sdks
    • Platform android-31, build-tools 30.0.3
    • ANDROID_HOME = .../android-sdks
    • ANDROID_SDK_ROOT = .../android-sdks
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7281165)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode 12.4.app/Contents/Developer
    • Xcode 12.4, Build version 12D4e
    • CocoaPods version 1.10.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2020.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7281165)

[✓] IntelliJ IDEA Community Edition (version 2021.2.3)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • Mac OS X 10.15.7 19H1419 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 94.0.4606.81

• No issues found!

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions