Release v10.2.0
Stream subscription detection improvements — fixes false negatives on rxdart and custom Stream subclasses, and aligns rule description with actual behavior.
Added
- New rule:
avoid_removed_null_thrown_error— flags removedNullThrownErrortype (Dart 3.0); quick fix renames toTypeError - New rule:
avoid_deprecated_file_system_delete_event_is_directory— flags deprecatedFileSystemDeleteEvent.isDirectory(Dart 3.4) which always returns false - New rule:
avoid_removed_render_object_element_methods— flags removedinsertChildRenderObject,moveChildRenderObject,removeChildRenderObject(Flutter 3.0); quick fix renames to replacement methods - New rule:
avoid_deprecated_animated_list_typedefs— flags deprecatedAnimatedListItemBuilder/AnimatedListRemovedItemBuilder(Flutter 3.7); quick fix renames toAnimatedItemBuilder/AnimatedRemovedItemBuilder - New rule:
avoid_deprecated_use_material3_copy_with— flags misleadinguseMaterial3parameter inThemeData.copyWith()(Flutter 3.16); quick fix removes the parameter - New rule:
avoid_deprecated_on_surface_destroyed— flags deprecatedSurfaceProducer.onSurfaceDestroyed(Flutter 3.29); quick fix renames toonSurfaceCleanup
Fixed
avoid_stream_subscription_in_fieldnow detects uncaptured.listen()calls on Stream subclasses (e.g. rxdartMergeStream,BehaviorSubject) that were previously missed by string-based type checkingavoid_stream_subscription_in_fieldproblem message and correction message now accurately describe the rule's behavior (detecting uncaptured.listen()calls) instead of incorrectly claiming it checksdispose()- Test fixture for
avoid_stream_subscription_in_fieldnow uses properly-typedStream<int>variables instead of undefineddynamicreferences that bypassed the type check - (Extension) Violations sidebar no longer opens a "file not found" error when source files have been moved or renamed since the last analysis; affected items show a warning icon with "(file moved or deleted)" label
- (Extension) "Fix all in this file" command now shows a user-friendly warning instead of silently failing on moved/deleted files