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

com.mr.flutter.plugin.filepicker.FileUtils.createImageFile #1711

Open
1 task done
BunnyBuddy opened this issue Feb 17, 2025 · 2 comments
Open
1 task done

com.mr.flutter.plugin.filepicker.FileUtils.createImageFile #1711

BunnyBuddy opened this issue Feb 17, 2025 · 2 comments
Labels
new issue An issue that hasn't yet been seen from the maintainer

Comments

@BunnyBuddy
Copy link

BunnyBuddy commented Feb 17, 2025

Description:
We have been using FilePicker since really long time and never encountered this issue before, but recently it often pops up under Google Play Console

Platform

  • Android

Platform OS version
Android 10

Devices Showing This Issue

  • Redmi lancelot
  • samsung a20

How are you picking?

FilePickerResult? result = await FilePicker.platform.pickFiles(
                                          allowMultiple: false,
                                          type: FileType.custom,
                                          allowedExtensions: ['jpeg', 'png', 'jpg', 'ppt', 'pptx', 'doc', 'docx', 'pdf', 'xls', 'xlsx', 'zip', 'rar', 'svg'],
                                        );
                                        if (result != null) {...

Error Log

Exception java.lang.RuntimeException: java.io.IOException: Permission denied
  at com.mr.flutter.plugin.filepicker.FileUtils.compressImage (FileUtils.java:111)
  at com.mr.flutter.plugin.filepicker.FilePickerDelegate$1.run (FilePickerDelegate.java:140)
  at java.lang.Thread.run (Thread.java:919)
Caused by java.io.IOException: Permission denied
  at java.io.UnixFileSystem.createFileExclusively0
  at java.io.UnixFileSystem.createFileExclusively (UnixFileSystem.java:317)
  at java.io.File.createTempFile (File.java:2018)
  at com.mr.flutter.plugin.filepicker.FileUtils.createImageFile (FileUtils.java:120)
  at com.mr.flutter.plugin.filepicker.FileUtils.compressImage (FileUtils.java:98)

Flutter Version details

[✓] Flutter (Channel stable, 3.27.4, on macOS 15.2 24C101 darwin-arm64, locale en-PK)
    • Flutter version 3.27.4 on channel stable at /Users/X/fvm/versions/stable
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision d8a9f9a52e (2 weeks ago), 2025-01-31 16:07:18 -0500
    • Engine revision 82bd5b7209
    • Dart version 3.6.2
    • DevTools version 2.40.3

[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
    • Android SDK at /Users/X/Library/Android/sdk
    • Platform android-35, build-tools 35.0.0
    • Java binary at: /Library/Java/JavaVirtualMachines/jdk-17.jdk/Contents/Home/bin/java
    • Java version Java(TM) SE Runtime Environment (build 17.0.12+8-LTS-286)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 16.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 16B40
    • CocoaPods version 1.16.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 21.0.5+-12932927-b750.29)

[✓] Connected device (5 available)
    • Android SDK built for arm64 (mobile) • emulator-5554             • android-arm64  • Android 10 (API 29) (emulator)
    • X iPhone (mobile)      • 00008020-001D0D0 • ios            • iOS 18.2.1 22C161
    • macOS (desktop)                      • macos                     • darwin-arm64   • macOS 15.2 24C101 darwin-arm64
    • Mac Designed for iPad (desktop)      • mac-designed-for-ipad     • darwin         • macOS 15.2 24C101 darwin-arm64
    • Chrome (web)                         • chrome                    • web-javascript • Google Chrome 133.0.6943.55

[✓] Network resources
    • All expected network resources are available.

• No issues found!
@BunnyBuddy BunnyBuddy added the new issue An issue that hasn't yet been seen from the maintainer label Feb 17, 2025
@TiAmo-cat
Copy link

Use compressionQuality: 0 add this in your parameters

@BunnyBuddy
Copy link
Author

Use compressionQuality: 0 add this in your parameters

I'll let you know if this resolves the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new issue An issue that hasn't yet been seen from the maintainer
Projects
None yet
Development

No branches or pull requests

2 participants