Skip to content

bug: Null patch option description causes app hang #2725

@LisoUseInAIKyrios

Description

@LisoUseInAIKyrios

Bug description

If a patch option does not include a description, Manager hangs and internally crashes.

A null description is allowed by Patch Option

And if a patch does not include a description, such as here, then Manager internally crashes and hangs on the app selection screen.

Version of ReVanced Manager and version & name of app you are patching

1.25.1

ReVanced Manager logs

[ERROR:flutter/runtime/dart_vm_initializer.cc(40)] Unhandled Exception: type 'Null' is not a subtype of type 'String' in type cast
09-04 12:49:43.061 13174 13174 E flutter : #0      _$OptionFromJson (package:revanced_manager/models/patch.g.dart:43)
09-04 12:49:43.061 13174 13174 E flutter : #1      new Option.fromJson (package:revanced_manager/models/patch.dart:72)
09-04 12:49:43.061 13174 13174 E flutter : #2      _$PatchFromJson.<anonymous closure> (package:revanced_manager/models/patch.g.dart:17)
09-04 12:49:43.061 13174 13174 E flutter : #3      MappedListIterable.elementAt (dart:_internal/iterable.dart:442)
09-04 12:49:43.061 13174 13174 E flutter : #4      ListIterator.moveNext (dart:_internal/iterable.dart:371)
09-04 12:49:43.061 13174 13174 E flutter : #5      new _GrowableList._ofEfficientLengthIterable (dart:core-patch/growable_array.dart:190)
09-04 12:49:43.061 13174 13174 E flutter : #6      new _GrowableList.of (dart:core-patch/growable_array.dart:150)
09-04 12:49:43.061 13174 13174 E flutter : #7      new List.of (dart:core-patch/array_patch.dart:40)
09-04 12:49:43.061 13174 13174 E flutter : #8      SetBase.toList (dart:collection/set.dart:119)
09-04 12:49:43.061 13174 13174 E flutter : #9      _$PatchFromJson (package:revanced_manager/models/patch.g.dart:18)
09-04 12:49:43.061 13174 13174 E flutter : #10     new Patch.fromJson (package:revanced_manager/models/patch.dart:18)
09-04 12:49:43.061 13174 13174 E flutter : #11     ManagerAPI.getPatches.<anonymous closure> (package:revanced_manager/services/manager_api.dart:452)
09-04 12:49:43.061 13174 13174 E flutter : #12     MappedListIterable.elementAt (dart:_internal/iterable.dart:442)
09-04 12:49:43.061 13174 13174 E flutter : #13     ListIterator.moveNext (dart:_internal/iterable.dart:371)
09-04 12:49:43.061 13174 13174 E flutter : #14     new _GrowableList._ofEfficientLengthIterable (dart:core-patch/growable_array.dart:190)
09-04 12:49:43.061 13174 13174 E flutter : #15     new _GrowableList.of (dart:core-patch/growable_array.dart:150)
09-04 12:49:43.061 13174 13174 E flutter : #16     new List.of (dart:core-patch/array_patch.dart:40)
09-04 12:49:43.061 13174 13174 E flutter : #17     SetBase.toList (dart:collection/set.dart:119)
09-04 12:49:43.061 13174 13174 E flutter : #18     ManagerAPI.getPatches (package:revanced_manager/services/manager_api.dart:453)

Acknowledgements

  • I have checked all open and closed bug reports and this is not a duplicate.
  • I have chosen an appropriate title.
  • All requested information has been provided properly.
  • The bug is only related to ReVanced Manager.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug reportSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions