diff --git a/CHANGELOG.md b/CHANGELOG.md index 93db6c2..df91cbf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 1.2.3 (2025-10-01) + +* Update WebRTC ver & code maintenance. (#41) + ## 1.2.2+hotfix.1 (2025-06-30) * Fixed: TranscriptionContext clean up (#36) diff --git a/analysis_options.yaml b/analysis_options.yaml index f9517a1..b13dcec 100644 --- a/analysis_options.yaml +++ b/analysis_options.yaml @@ -1,6 +1,11 @@ include: package:flutter_lints/flutter.yaml analyzer: + language: + strict-casts: true + strict-inference: true + strict-raw-types: true + errors: constant_identifier_names: ignore no_wildcard_variable_uses: ignore @@ -14,6 +19,7 @@ linter: prefer_final_locals: true unnecessary_brace_in_string_interps: false avoid_print: true + depend_on_referenced_packages: true # Enforce this for correct async logic unawaited_futures: true diff --git a/example/macos/Podfile b/example/macos/Podfile index c795730..b52666a 100644 --- a/example/macos/Podfile +++ b/example/macos/Podfile @@ -1,4 +1,4 @@ -platform :osx, '10.14' +platform :osx, '10.15' # CocoaPods analytics sends network stats synchronously affecting flutter build latency. ENV['COCOAPODS_DISABLE_STATS'] = 'true' diff --git a/example/macos/Runner.xcodeproj/project.pbxproj b/example/macos/Runner.xcodeproj/project.pbxproj index fe44e6d..48a8af9 100644 --- a/example/macos/Runner.xcodeproj/project.pbxproj +++ b/example/macos/Runner.xcodeproj/project.pbxproj @@ -557,7 +557,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.14; + MACOSX_DEPLOYMENT_TARGET = 10.15; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = macosx; SWIFT_COMPILATION_MODE = wholemodule; @@ -639,7 +639,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.14; + MACOSX_DEPLOYMENT_TARGET = 10.15; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = macosx; @@ -689,7 +689,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.14; + MACOSX_DEPLOYMENT_TARGET = 10.15; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = macosx; SWIFT_COMPILATION_MODE = wholemodule; diff --git a/example/pubspec.yaml b/example/pubspec.yaml index cd7f8b4..de2adcf 100644 --- a/example/pubspec.yaml +++ b/example/pubspec.yaml @@ -27,6 +27,7 @@ dependencies: livekit_components: path: .. + livekit_client: ^2.5.4 # The following adds the Cupertino Icons font to your application. # Use with the CupertinoIcons class for iOS style icons. diff --git a/lib/src/context/room_context.dart b/lib/src/context/room_context.dart index b611347..8d70d07 100644 --- a/lib/src/context/room_context.dart +++ b/lib/src/context/room_context.dart @@ -145,7 +145,7 @@ class RoomContext extends ChangeNotifier with ChatContextMixin, TranscriptionCon if (connect && url != null && token != null) { _url = url; _token = token; - unawaited(this.connect(url: url, token: token).catchError((error, stack) { + unawaited(this.connect(url: url, token: token).catchError((Object error, StackTrace stack) { Debug.event('RoomContext: auto connect failed: $error'); // Preserve original behavior by rethrowing after logging. throw error; diff --git a/lib/src/ui/widgets/track/audio_visualizer_widget.dart b/lib/src/ui/widgets/track/audio_visualizer_widget.dart index f1fe80a..f30ec8b 100644 --- a/lib/src/ui/widgets/track/audio_visualizer_widget.dart +++ b/lib/src/ui/widgets/track/audio_visualizer_widget.dart @@ -124,7 +124,7 @@ class _SoundWaveformWidgetState extends State with SingleTi sdk.EventsListener? _participantListener; // Agent support - sdk.AgentState _agentState = sdk.AgentState.INITIALIZING; + sdk.AgentState _agentState = sdk.AgentState.initializing; @override void didUpdateWidget(SoundWaveformWidget oldWidget) { @@ -155,7 +155,7 @@ class _SoundWaveformWidgetState extends State with SingleTi if (!mounted) return; final agentAttributes = sdk.AgentAttributes.fromJson(e.attributes); setState(() { - _agentState = agentAttributes.lkAgentState ?? sdk.AgentState.INITIALIZING; + _agentState = agentAttributes.lkAgentState ?? sdk.AgentState.initializing; }); }); } @@ -260,13 +260,13 @@ class _SoundWaveformWidgetState extends State with SingleTi } VisualizerState _determineState() { - if (widget.participant?.kind == sdk.ParticipantKind.AGENT && _agentState == sdk.AgentState.THINKING) { + if (widget.participant?.kind == sdk.ParticipantKind.AGENT && _agentState == sdk.AgentState.thinking) { return VisualizerState.thinking; } if (widget.participant == null || widget.participant?.kind == sdk.ParticipantKind.AGENT && - (_agentState == sdk.AgentState.INITIALIZING || _agentState == sdk.AgentState.LISTENING)) { + (_agentState == sdk.AgentState.initializing || _agentState == sdk.AgentState.listening)) { return VisualizerState.listening; } diff --git a/pubspec.yaml b/pubspec.yaml index 3e36d96..3873a7b 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: livekit_components description: "Out-of-the-box flutter widgets for livekit client." -version: 1.2.2+hotfix.1 +version: 1.2.3 homepage: https://github.com/livekit/components-flutter environment: @@ -10,7 +10,7 @@ environment: dependencies: flutter: sdk: flutter - flutter_webrtc: 1.2.0 + flutter_webrtc: 1.2.1 livekit_client: ^2.4.9 chat_bubbles: ^1.6.0 collection: ^1.19.0