Skip to content

[BUG] v1.0.0-dev.12 AliceHttpCall is not immutable #252

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

Open
luiges90 opened this issue Apr 10, 2025 · 0 comments
Open

[BUG] v1.0.0-dev.12 AliceHttpCall is not immutable #252

luiges90 opened this issue Apr 10, 2025 · 0 comments
Assignees
Labels
new issue New issue which has not been checked yet

Comments

@luiges90
Copy link

luiges90 commented Apr 10, 2025

Describe the bug
AliceHttpCall, AliceHttpRequest and AliceHttpResponse mixins EquatableMixin. The latter is marked @immutable but all Alice classes contains mutable fields, causing lint issues.
The error is:

warning • This class (or a class that this class inherits from) is marked as '@immutable', but one or more of its instance fields aren't final: AliceHttpCall.client, AliceHttpCall.loading, AliceHttpCall.secure, AliceHttpCall.method, AliceHttpCall.endpoint, AliceHttpCall.server, AliceHttpCall.uri,
       AliceHttpCall.duration, AliceHttpCall.request, AliceHttpCall.response, AliceHttpCall.error • lib/models/http_snapshot_call.dart:5:7 • must_be_immutable

To Reproduce
N/A

Expected behavior
AliceHttpCall should be @immutable with only final fields

Screenshots
N/A

Flutter doctor

{10:49}~ ✓ ➭ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.27.1, on macOS 15.0.1 24A348 darwin-arm64, locale en-HK)
[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 16.1)
[✗] Chrome - develop for the web (Cannot find Chrome executable at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome)
    ! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[✓] Android Studio (version 2024.3)
[✓] VS Code (version 1.99.0)
[✓] Connected device (3 available)
    ! Error: Browsing on the local area network for [snip]. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)
    ! Error: Browsing on the local area network for [snip]. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)
[✓] Network resources

Alice version

  • Version: v1.0.0-dev.12

Smartphone (please complete the following information):
N/A

Additional context
Code level issue, not related to any UI.

@luiges90 luiges90 added the new issue New issue which has not been checked yet label Apr 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new issue New issue which has not been checked yet
Projects
None yet
Development

No branches or pull requests

2 participants