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

app crashing when starting video on iOS #56

Closed
jamesdixon opened this issue Dec 11, 2020 · 7 comments · Fixed by #57
Closed

app crashing when starting video on iOS #56

jamesdixon opened this issue Dec 11, 2020 · 7 comments · Fixed by #57
Labels
bug Something isn't working

Comments

@jamesdixon
Copy link

jamesdixon commented Dec 11, 2020

Hello!

Steps to Reproduce

I copied your _recordVideo method pretty much verbatim.

  _recordVideo() async {
    if (_isRecordingVideo) {
      await _videoController.stopRecordingVideo();

      _isRecordingVideo = false;
      setState(() {});
    } else {
      final extDir = await getTemporaryDirectory();
      final testDir =
          await Directory('${extDir.path}/test').create(recursive: true);
      final filePath = '${testDir.path}/video_test.mp4';

      await _videoController.recordVideo(filePath);

      _isRecordingVideo = true;
      setState(() {});
    }
  }

Expected results

Video should work.

Actual results

App crashes and I see the following in the XCode console:

*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Unsupported value for standard codec'

About your device

Brand Model OS
Apple iPhone 12 Pro 14.2.1
@g-apparence g-apparence assigned ghost Dec 12, 2020
@g-apparence g-apparence added the bug Something isn't working label Dec 12, 2020
@g-apparence
Copy link
Collaborator

Thank you for reporting it.

@istornz
Copy link
Contributor

istornz commented Dec 14, 2020

Hi @jamesdixon, do you have a complete example to reproduce the error ?
The example provided in this repo works on your phone ?
Thanks !

@jamesdixon
Copy link
Author

@istornz I will try and make a reproducible example!

@jamesdixon
Copy link
Author

Hello! I was able to run the example successfully so not sure what's going on 🤔 It's a bit bizarre but I'll keep trying and let you guys know what I find. Thank you for all you do. Cheers

@jamesdixon
Copy link
Author

Hello again! So, I copied the exact example code directly into my own app and unfortunately, I get the same result. As soon as I tap the button to record video, the app crashes with the error mentioned above.

The good news is that I was able to reproduce the issue in your example. Basically, I copied in my dependencies and then ran your app and as soon as I started recording, the example app crashed. Here's a modified version of your pubspec.yaml that contains the dependencies from my app.

https://gist.github.com/jamesdixon/f335a8011a55a8e45d063c4eab600fdf

Let me know if you're able to reproduce with the same file.

@leonalonso
Copy link

Hello, is there any news about it? I also have the same problem, everything works correctly, but when I press the register button the app crash.

@ghost
Copy link

ghost commented Feb 2, 2021

Hello @leonalonso, what is your device model, OS version, library used in your projects and can you paste the log when crash occur ?
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants