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

Photo not working in android 7 and 8 #90

Open
Tracked by #89
cdparra opened this issue Nov 5, 2017 · 4 comments
Open
Tracked by #89

Photo not working in android 7 and 8 #90

cdparra opened this issue Nov 5, 2017 · 4 comments

Comments

@cdparra
Copy link
Member

cdparra commented Nov 5, 2017

11-05 18:58:53.138 10909 10909 D CordovaActivity: Stopped the activity.
11-05 18:58:57.710 10909 10909 D CordovaActivity: Incoming Result. Request code = 33
11-05 18:58:57.710 10909 10909 D CordovaInterfaceImpl: Sending activity result to plugin
11-05 18:58:57.719 10909 10909 W ExifInterface: Skip the tag entry since tag number is not defined: 2
11-05 18:58:57.724 10909 10909 W System.err: java.io.FileNotFoundException: open failed: EACCES (Permission denied)
11-05 18:58:57.724 10909 10909 W System.err:    at android.os.ParcelFileDescriptor.openInternal(ParcelFileDescriptor.java:313)
11-05 18:58:57.724 10909 10909 W System.err:    at android.os.ParcelFileDescriptor.open(ParcelFileDescriptor.java:211)
11-05 18:58:57.724 10909 10909 W System.err:    at android.content.ContentResolver.openAssetFileDescriptor(ContentResolver.java:1242)
11-05 18:58:57.724 10909 10909 W System.err:    at android.content.ContentResolver.openOutputStream(ContentResolver.java:1007)
11-05 18:58:57.724 10909 10909 W System.err:    at android.content.ContentResolver.openOutputStream(ContentResolver.java:983)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.camera.CameraLauncher.writeUncompressedImage(CameraLauncher.java:865)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.camera.CameraLauncher.writeUncompressedImage(CameraLauncher.java:901)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.camera.CameraLauncher.processResultFromCamera(CameraLauncher.java:502)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.camera.CameraLauncher.onActivityResult(CameraLauncher.java:805)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.CordovaInterfaceImpl.onActivityResult(CordovaInterfaceImpl.java:152)
11-05 18:58:57.724 10909 10909 W System.err:    at org.apache.cordova.CordovaActivity.onActivityResult(CordovaActivity.java:358)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.Activity.dispatchActivityResult(Activity.java:7235)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.ActivityThread.deliverResults(ActivityThread.java:4320)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.ActivityThread.handleSendResult(ActivityThread.java:4367)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.ActivityThread.-wrap19(Unknown Source:0)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1649)
11-05 18:58:57.724 10909 10909 W System.err:    at android.os.Handler.dispatchMessage(Handler.java:105)
11-05 18:58:57.724 10909 10909 W System.err:    at android.os.Looper.loop(Looper.java:164)
11-05 18:58:57.724 10909 10909 W System.err:    at android.app.ActivityThread.main(ActivityThread.java:6541)
11-05 18:58:57.724 10909 10909 W System.err:    at java.lang.reflect.Method.invoke(Native Method)
11-05 18:58:57.724 10909 10909 W System.err:    at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
11-05 18:58:57.724 10909 10909 W System.err:    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
@cdparra cdparra changed the title Photo not working in android 8 Photo not working in android 7 and 8 Nov 5, 2017
@cdparra cdparra changed the title Photo not working in android 7 and 8 Photo not working in android 8 Nov 5, 2017
@cdparra
Copy link
Member Author

cdparra commented Nov 5, 2017

In android 7, ig get stucked in posting the post with an image:

11-05 19:11:26.292 18166 18166 D ViewRootImpl@9b0d9e0[MainActivity]: ViewPostImeInputStage processPointer 0
11-05 19:11:26.382 18166 18166 D ViewRootImpl@9b0d9e0[MainActivity]: ViewPostImeInputStage processPointer 1
11-05 19:11:26.408 18166 18166 I chromium: [INFO:CONSOLE(26794)] "TypeError: Cannot read property 'id' of undefined
11-05 19:11:26.408 18166 18166 I chromium:     at Object.documentID (file:///android_asset/www/js/services/post.js:18:20)
11-05 19:11:26.408 18166 18166 I chromium:     at Scope.$scope.createPost (file:///android_asset/www/js/controllers/postsCtrl.js:106:19)
11-05 19:11:26.408 18166 18166 I chromium:     at fn (eval at compile (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:27638:15), <anonymous>:4:221)
11-05 19:11:26.408 18166 18166 I chromium:     at file:///android_asset/www/lib/ionic/js/ionic.bundle.js:65427:9
11-05 19:11:26.408 18166 18166 I chromium:     at Scope.$eval (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:30395:28)
11-05 19:11:26.408 18166 18166 I chromium:     at Scope.$apply (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:30495:25)
11-05 19:11:26.408 18166 18166 I chromium:     at HTMLDivElement.<anonymous> (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:65426:13)
11-05 19:11:26.408 18166 18166 I chromium:     at defaultHandlerWrapper (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:16787:11)
11-05 19:11:26.408 18166 18166 I chromium:     at HTMLDivElement.eventHandler (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:16775:9)
11-05 19:11:26.408 18166 18166 I chromium:     at triggerMouseEvent (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:2953:7)", source: file:///android_asset/www/lib/ionic/js/ionic.bundle.js (26794)
11-05 19:11:26.410 18166 18166 V InputMethodManager: Starting input: tba=android.view.inputmethod.EditorInfo@388938f nm : com.denguechat.denguechat ic=org.chromium.content.browser.input.ReplicaInputConnection@db6961c
11-05 19:11:26.426 18166 18166 I InputMethodManager: [IMM] startInputInner - mService.startInputOrWindowGainedFocus
11-05 19:11:26.430 18166 18166 D InputTransport: Input channel constructed: fd=135

@cdparra cdparra changed the title Photo not working in android 8 Photo not working in android 7 and 8 Nov 5, 2017
@cdparra
Copy link
Member Author

cdparra commented Nov 5, 2017

The photo posts is stucked with the following error:

I/chromium( 1376): [INFO:CONSOLE(26794)] "TypeError: Cannot read property 'id' of undefined
I/chromium( 1376):     at Object.documentID (file:///android_asset/www/js/services/post.js:18:20)
I/chromium( 1376):     at Scope.$scope.createPost (file:///android_asset/www/js/controllers/postsCtrl.js:106:19)
I/chromium( 1376):     at fn (eval at compile (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:27638:15), <anonymous>:4:221)
I/chromium( 1376):     at file:///android_asset/www/lib/ionic/js/ionic.bundle.js:65427:9
I/chromium( 1376):     at Scope.$eval (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:30395:28)
I/chromium( 1376):     at Scope.$apply (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:30495:25)
I/chromium( 1376):     at HTMLDivElement.<anonymous> (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:65426:13)
I/chromium( 1376):     at defaultHandlerWrapper (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:16787:11)
I/chromium( 1376):     at HTMLDivElement.eventHandler (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:16775:9)
I/chromium( 1376):     at triggerMouseEvent (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:2953:7)", source: file:///android_asset/www/lib/ionic/js/ionic.bundle.js (26794)

This is most likely related to the issue #85 since what's somehow missing is the user.id. Somewhere, this is deleted.

cdparra added a commit that referenced this issue Nov 5, 2017
@cdparra
Copy link
Member Author

cdparra commented Dec 6, 2017

Still getting this error:

12-05 22:19:21.261 12840 12918 W PluginManager: THREAD WARNING: exec() call to Camera.takePicture blocked the main thread for 31ms. Plugin should use CordovaInterface.getThreadPool().
12-05 22:19:21.998 12840 12840 D CordovaActivity: Stopped the activity.
12-05 22:19:27.288 12840 12840 D CordovaActivity: Incoming Result. Request code = 33
12-05 22:19:27.288 12840 12840 D CordovaInterfaceImpl: Sending activity result to plugin
12-05 22:19:27.291 12840 12840 W ExifInterface: Skip the tag entry since tag number is not defined: 2
12-05 22:19:27.296 12840 12840 W System.err: java.io.FileNotFoundException: open failed: EACCES (Permission denied)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.os.ParcelFileDescriptor.openInternal(ParcelFileDescriptor.java:313)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.os.ParcelFileDescriptor.open(ParcelFileDescriptor.java:211)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.content.ContentResolver.openAssetFileDescriptor(ContentResolver.java:1242)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.content.ContentResolver.openOutputStream(ContentResolver.java:1007)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.content.ContentResolver.openOutputStream(ContentResolver.java:983)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.camera.CameraLauncher.writeUncompressedImage(CameraLauncher.java:865)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.camera.CameraLauncher.writeUncompressedImage(CameraLauncher.java:901)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.camera.CameraLauncher.processResultFromCamera(CameraLauncher.java:502)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.camera.CameraLauncher.onActivityResult(CameraLauncher.java:805)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.CordovaInterfaceImpl.onActivityResult(CordovaInterfaceImpl.java:152)
12-05 22:19:27.296 12840 12840 W System.err: 	at org.apache.cordova.CordovaActivity.onActivityResult(CordovaActivity.java:358)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.Activity.dispatchActivityResult(Activity.java:7235)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.ActivityThread.deliverResults(ActivityThread.java:4320)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.ActivityThread.handleSendResult(ActivityThread.java:4367)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.ActivityThread.-wrap19(Unknown Source:0)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1649)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.os.Handler.dispatchMessage(Handler.java:105)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.os.Looper.loop(Looper.java:164)
12-05 22:19:27.296 12840 12840 W System.err: 	at android.app.ActivityThread.main(ActivityThread.java:6541)
12-05 22:19:27.296 12840 12840 W System.err: 	at java.lang.reflect.Method.invoke(Native Method)
12-05 22:19:27.296 12840 12840 W System.err: 	at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
12-05 22:19:27.296 12840 12840 W System.err: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
12-05 22:19:27.310 12840 12840 D CordovaActivity: Started the activity.
12-05 22:19:27.312 12840 12840 D CordovaActivity: Resumed the activity.
12-05 22:19:27.360 12840 12840 I chromium: [INFO:CONSOLE(116)] "
12-05 22:19:27.360 12840 12840 I chromium: 
12-05 22:19:27.360 12840 12840 I chromium: 
12-05 22:19:27.360 12840 12840 I chromium: ---------------", source: file:///android_asset/www/js/app.js (116)
12-05 22:19:27.361 12840 12840 I chromium: [INFO:CONSOLE(117)] "clovi.env.error: "Error capturing image."", source: file:///android_asset/www/js/app.js (117)
12-05 22:19:27.361 12840 12840 I chromium: [INFO:CONSOLE(118)] "---------------

cdparra added a commit that referenced this issue Dec 6, 2017
* commit '0c9ad212fb26eb8bff9d89b3bc7e291d6e88b2ab':
  Fixed registrations endpoint to point the new endpoint created
  Added geolocation plugin to generate the right permissions
  Final fix for #85 and #88
  Fix for post getting stuck loading refs #88
  Fix for #85 and #90
@cdparra
Copy link
Member Author

cdparra commented Dec 6, 2017

Seems to be working when access to files is also enabled as permission

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant