Skip to content

feat: liquid flutter v23#59

Open
ElectricCookie wants to merge 7 commits intodevfrom
feat_liquid_flutter_23
Open

feat: liquid flutter v23#59
ElectricCookie wants to merge 7 commits intodevfrom
feat_liquid_flutter_23

Conversation

@ElectricCookie
Copy link
Copy Markdown
Contributor

Summary

Updates the package to Liquid Flutter v23 (pre-release)

Checklist

  • You agree with our CLA
  • Included tests (or is not applicable).
  • Updated documentation (or is not applicable).

Copilot AI review requested due to automatic review settings February 27, 2026 09:47
@ElectricCookie
Copy link
Copy Markdown
Contributor Author

@copilot the validation failed becasue the validate (pull_Request) job is using an old flutter version. Can you bump the version in the workflow?

Copy link
Copy Markdown

Copilot AI commented Feb 27, 2026

@ElectricCookie I've opened a new pull request, #60, to work on those changes. Once the pull request is ready, I'll request review from you.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request updates the codebase to use Liquid Flutter v23.0.0-1, a pre-release version that introduces breaking API changes. The update affects multiple packages in the monorepo and includes comprehensive changes to adapt to the new widget APIs.

Changes:

  • Upgraded liquid_flutter from v22.0.4 to v23.0.0-1 across all packages
  • Added publish_to: none to all internal package configurations
  • Converted internal dependencies from version constraints to path-based references for monorepo development
  • Updated all widget usages to match Liquid Flutter v23 API (LdSubmit generics, text widgets, button constructors, builder signatures)
  • Regenerated golden test images due to rendering changes

Reviewed changes

Copilot reviewed 17 out of 89 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
mtrust_urp_wifi_strategy/pubspec.yaml Added publish_to config, converted to path dependency
mtrust_urp_virtual_strategy/pubspec.yaml Added publish_to config, converted to path dependency
mtrust_urp_usb_strategy/pubspec.yaml Added publish_to config, converted to path dependency
mtrust_urp_ui/pubspec.yaml Updated liquid_flutter to v23, path dependencies, publish_to config
mtrust_urp_ui/lib/src/device_connector/*.dart Updated to Liquid Flutter v23 APIs (LdSubmit, text widgets, builders)
mtrust_urp_ui/test/golden_utils.dart Removed deprecated autoSize parameter
mtrust_urp_ui/test/goldens//.png Regenerated golden test images
mtrust_urp_ui/example/pubspec.yaml Updated liquid_flutter to v23, path dependencies
mtrust_urp_ui/example/lib/main.dart Updated to LdScaffold structure with v23 APIs
mtrust_urp_core/pubspec.yaml Added publish_to config
mtrust_urp_ble_strategy/pubspec.yaml Added publish_to config, converted to path dependency
*/pubspec.lock Transitive dependency updates from liquid_flutter upgrade

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

action: () async {
final connected = await strategy.connectToFoundDevice(expectedReader);
action: (reader) async {
final connected = await strategy.connectToFoundDevice(reader!);
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The force unwrapping of the reader parameter using reader! is unsafe. Since expectedReader is already available as a non-nullable field in the class, the arg parameter seems redundant here. If the Liquid Flutter v23 API requires the arg parameter to be passed, consider using reader ?? expectedReader instead of force unwrapping to avoid potential null pointer exceptions.

Suggested change
final connected = await strategy.connectToFoundDevice(reader!);
final connected = await strategy.connectToFoundDevice(reader ?? expectedReader);

Copilot uses AI. Check for mistakes.
Comment on lines +25 to +26
action: (strategy) async {
return strategy!.availability;
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The force unwrapping of the strategy parameter using strategy! is unsafe. Since strategy is already available as a non-nullable field, and the arg parameter is being set to strategy, this force unwrap could cause a runtime crash if the parameter is somehow null. Consider using the class field directly in the action callback instead: return strategy.availability;.

Suggested change
action: (strategy) async {
return strategy!.availability;
action: (_) async {
return strategy.availability;

Copilot uses AI. Check for mistakes.
Comment on lines +112 to +113
action: (deviceTypes) async {
return connectionStrategy.findDevices(deviceTypes!);
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The force unwrapping of the deviceTypes parameter using deviceTypes! is unsafe. Since deviceTypes is already available as a non-nullable field in the widget, and the arg parameter is being set to deviceTypes, this force unwrap could cause a runtime crash. Consider using the widget field directly in the action callback instead: return connectionStrategy.findDevices(deviceTypes);.

Suggested change
action: (deviceTypes) async {
return connectionStrategy.findDevices(deviceTypes!);
action: (_) async {
return connectionStrategy.findDevices(deviceTypes);

Copilot uses AI. Check for mistakes.
* Initial plan

* ci: bump Flutter version to 3.41.2 for liquid_flutter v23 compatibility

Co-authored-by: ElectricCookie <18628516+ElectricCookie@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ElectricCookie <18628516+ElectricCookie@users.noreply.github.com>
@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ ElectricCookie
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

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

Successfully merging this pull request may close these issues.

4 participants