Skip to content
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

The audio service should stop on a hot restart #234

Closed
hacker1024 opened this issue Apr 5, 2020 · 3 comments
Closed

The audio service should stop on a hot restart #234

hacker1024 opened this issue Apr 5, 2020 · 3 comments

Comments

@hacker1024
Copy link
Contributor

Describe the bug
When doing a hot restart, the audio service keeps running. This causes problems when starting it again.

Furthermore, I use isolate nameservers to send complex objects to my service. After a hot restart, these become null, leading the service to crash.

Minimal reproduction project
It happens in the example too.

To Reproduce
Steps to reproduce the behavior:

  1. Run the service
  2. Run a hot restart
  3. Observe

Expected behavior
The service should stop on a hot restart.

Runtime Environment (please complete the following information if relevant):

  • Device: Xiaomi Redmi K20 Pro
  • Android version: 10 (Evolution X | Custom ROM)
  • iOS version: Not tested

Flutter SDK version
(It doesn't detect EAP plugins, for some reason)

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.12.13+hotfix.9, on Mac OS X 10.15.4 19E266, locale en-AU)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 11.4)
[!] Android Studio (not installed)
[!] IntelliJ IDEA Ultimate Edition (version 2020.1 RC)
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] Connected device (1 available)

! Doctor found issues in 2 categories.

Additional context
I'm not very experienced with isolates. I suspect that the bug's not really this plugin's fault, but it's be nice if we can find a workaround.

@hacker1024
Copy link
Contributor Author

This was briefly discussed in #214, but this is a slightly different issue.
A hot reload's fine, because that preserves state.

@hacker1024
Copy link
Contributor Author

Oops, it's fixed in Flutter master.

@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs, or use StackOverflow if you need help with audio_service.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 21, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant