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

This package throws an error when analyzing apk size #29

Open
pmatatias opened this issue Jun 12, 2024 · 0 comments
Open

This package throws an error when analyzing apk size #29

pmatatias opened this issue Jun 12, 2024 · 0 comments

Comments

@pmatatias
Copy link

After add the community_charts_flutter to my project, I cant analyze the apk size.

run this command:

flutter build apk --target-platform=android-arm --analyze-size --verbose

and got this error:

../../third_party/dart/runtime/vm/app_snapshot.cc: 7704: error: Request to create artificial node for object with
cid 60
[   +5 ms] [   +1 ms] version=3.4.1 (stable) (Tue May 21 15:46:25 2024 +0000) on "macos_arm"
[        ] [        ] pid=66872, thread=-1, isolate_group=isolate(0x7fc805810600), isolate=isolate(0x7fc80580ee00)
[        ] [        ] os=macos, arch=arm, comp=no, sim=no
[        ] [        ] isolate_instructions=0, vm_instructions=0
[        ] [        ] fp=305a67a40, sp=305a67a20, pc=100d68c6b
[  +89 ms] [  +24 ms]   pc 0x0000000100d68c6b fp 0x0000000305a67a40 Dart_DumpNativeStackTrace+0x4b
[        ] [   +5 ms]   pc 0x0000000100895b81 fp 0x0000000305a67b20 dart::Assert::Fail(char const*, ...) const+0x91
[        ] [   +1 ms]   pc 0x00000001008eef1f fp 0x0000000305a67be0 dart::Serializer::CreateArtificialNodeIfNeeded(dart::ObjectPtr)+0x8af
[        ] [        ]   pc 0x0000000100912a54 fp 0x0000000305a681a0 dart::Serializer::Serialize(dart::SerializationRoots*)+0x50d4
[        ] [   +2 ms]   pc 0x0000000100929545 fp 0x0000000305a68410
dart::FullSnapshotWriter::WriteFullSnapshot(dart::GrowableArray<dart::LoadingUnitSerializationData*>*)+0x5b5
[        ] [   +2 ms]   pc 0x0000000100d6534c fp 0x0000000305a68810 dart::CreateAppAOTSnapshot(void ()(void, unsigned char const*,
long), void*, bool, bool, void*, dart::GrowableArray<dart::LoadingUnitSerializationData*>, dart::LoadingUnitSerializationData, unsigned
int)+0xb5c
[        ] [        ]   pc 0x0000000100d66c91 fp 0x0000000305a688f0 Dart_CreateAppAOTSnapshotAsElf+0x191
[        ] [        ]   pc 0x000000010088e9dd fp 0x0000000305a68e00 dart::bin::main(int, char**)+0x1e4d
[        ] [   +5 ms]   pc 0x00000002010ee310 fp 0x0000000305a690a0 Unknown symbol
[        ] [        ] -- End of DumpStackTrace

how to reporoduce:

  • add the community_charts_flutter to your flutter project . in my case I use 1.0.4 version
  • run this command to analyze the app size
    flutter build apk --target-platform=android-arm --analyze-size

i try to remove the package from my pubspec.yaml file,

  • flutter clean and then flutter pub get
  • run again flutter build apk --target-platform=android-arm --analyze-size
    success analyzing apk and got the result of the package size.

flutter doctor

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.22.1, on macOS 13.0.1 22A400 darwin-arm64, locale en-ID)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
[!] Xcode - develop for iOS and macOS (Xcode 14.1)
    ! Flutter recommends a minimum Xcode version of 15.
      Download the latest version or update via the Mac App Store.
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.3)
[✓] VS Code (version 1.90.0)
[✓] Connected device (4 available)
[✓] Network resources

! Doctor found issues in 1 category.
@pmatatias pmatatias changed the title The package cause error when analyze-size apk size This package throws an error when analyzing apk size Jun 12, 2024
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

1 participant