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

bug: Image is lost if choosing not to edit for Camera plugin on Android #2835

Closed
1 of 4 tasks
maaljam opened this issue Apr 27, 2020 · 19 comments
Closed
1 of 4 tasks

Comments

@maaljam
Copy link

maaljam commented Apr 27, 2020

Bug Report

Capacitor Version

💊 Capacitor Doctor 💊

Latest Dependencies:

@capacitor/cli: 2.0.1

@capacitor/core: 2.0.1

@capacitor/android: 2.0.1

@capacitor/electron: 2.0.1

@capacitor/ios: 2.0.1

Installed Dependencies:

@capacitor/electron not installed

@capacitor/cli 2.0.0

@capacitor/core 2.0.0

@capacitor/ios 2.0.0

@capacitor/android 2.0.0

[success] Android looking great! 👌
Found 7 Capacitor plugins for ios:
com-darryncampbell-cordova-plugin-intent (2.0.0)
cordova-admob-plus (0.35.0)
cordova-plugin-appavailability (0.4.2)
cordova-plugin-file (6.0.2)
cordova-plugin-file-transfer (1.7.1)
[success] iOS looking great! 👌

Affected Platform(s)

  • Android
  • iOS
  • Electron
  • Web

Current Behavior

Original Image is not returned when you select a phone from gallery and continue without editing it.

Note: This is almost exactly the same issue as #2020. I see it is working totally fine in case of taking a picture but not in case of selecting an image from gallery.

Expected Behavior

If no edit is performed after selecting an image from gallery, original image should be returned

Sample Code or Sample Application Repo

const image = await Camera.getPhoto({
	quality: 90,
         allowEditing: true,
	resultType: CameraResultType.Uri,
});

console.log(image.webPath); // nothing is returned

Reproduction Steps

Call Camera Plugin code Camera.getPhoto(..)
choose option (Select an Image from Gallery)
when edit screen pops up, click the X without making any edits
No image is returned

Other Technical Details

npm --version output: 6.4.1

node --version output: v10.10.0

pod --version output (iOS issues only):

Other Information

@jcesarmobile
Copy link
Member

can you provide a sample app? also, latest version is 2.0.1

@jcesarmobile jcesarmobile added the needs reply needs reply from the user label Apr 27, 2020
@maaljam
Copy link
Author

maaljam commented Apr 27, 2020

I created and ran a sample app using npx @capacitor/cli create and added allowEditing: true to the existing function in the app. I can confirm the issue exists even in v2.0.1. sample app is here

@Boby
Copy link

Boby commented May 14, 2020

+1 the issue still exist

@YogenRaii
Copy link

+1

@shanksauce
Copy link

+1 (observed on Android)

@eglismella
Copy link

+1 (android)

@sandstrom
Copy link
Contributor

See if this commit fixes your issue: #3331

@basvdijk
Copy link

@sandstrom I can confirm this issue still exists in Capacitor 2.4.1

@eikooc
Copy link

eikooc commented Dec 19, 2020

For me the bug is only there with the option allowEditing: true. If set to false it works.

@KrishPro
Copy link

Same here +1

1 similar comment
@bastifix
Copy link

bastifix commented Feb 4, 2021

Same here +1

@ealejandromt
Copy link

I confirm this issue happening in Capacitor 2.4.6

@adeldx
Copy link

adeldx commented Mar 24, 2021

+1 (android)

@Awadh-Dixit
Copy link

I am also facing the same issue in Capacitor 3. Please advise.

@HelloDavideDeSimone
Copy link

I confirm this issue still exist on capacitor 3.0.0

@LorenzoDelPianta
Copy link

+1 (android) capacitor 3.0.0 camera 1.0.3

@florianmonfort
Copy link

florianmonfort commented Jul 30, 2021

+1 we have same issue on Capacitor 3.

For us the issue also exists whenever you do edit the picture, then select to agree, on Xiaomi devices specifically. The plug in doesn't return any picture.

@jcesarmobile
Copy link
Member

this has been fixed in @capacitor/camera, would be available on next release.

@ionitron-bot
Copy link

ionitron-bot bot commented Nov 11, 2022

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Nov 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests