kwhitefoot / ImapNote2

Sync notes between Android devices using IMAP accounts as the central repository.
GNU General Public License v3.0
4 stars 0 forks source link

Reported by nbenm #3

Closed kwhitefoot closed 7 years ago

kwhitefoot commented 7 years ago

It compiles with the following error:

:ImapNote2:lintVitalRelease
/Users/nb/Dropbox/dev/android/adt/ImapNote2/ImapNote2/src/main/java/com/Pau/ImapNotes2/Sync/StubProvider.java:16: Error: This class should be public (com.Pau.ImapNotes2.Sync.StubProvider) [Instantiatable]
class StubProvider extends ContentProvider {
~

Explanation for issues of type "Instantiatable":
Activities, services, broadcast receivers etc. registered in the manifest
file (or for custom views, in a layout file) must be "instantiatable" by
the system, which means that the class must be public, it must have an
empty public constructor, and if it's an inner class, it must be a static
inner class.

At runtime, the app crashes with the following in logcat:

01-22 20:02:05.831 31453 31453 E AndroidRuntime: FATAL EXCEPTION: main
01-22 20:02:05.831 31453 31453 E AndroidRuntime: Process: com.Pau.ImapNotes2, PID: 31453
01-22 20:02:05.831 31453 31453 E AndroidRuntime: java.lang.RuntimeException: Unable to get provider com.Pau.ImapNotes2.Sync.StubProvider: java.lang.IllegalAccessException: java.lang.Class<com.Pau.ImapNotes2.Sync.StubProvider> is not accessible from java.lang.Class<android.app.ActivityThread>
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:6871)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.installContentProviders(ActivityThread.java:6463)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6403)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.access$1800(ActivityThread.java:229)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1887)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:7325)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: Caused by: java.lang.IllegalAccessException: java.lang.Class<com.Pau.ImapNotes2.Sync.StubProvider> is not accessible from java.lang.Class<android.app.ActivityThread>
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at java.lang.Class.newInstance(Native Method)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:6856)
01-22 20:02:05.831 31453 31453 E AndroidRuntime: ... 10 more
01-22 20:02:05.841 2624 3406 W ActivityManager: Force finishing activity com.Pau.ImapNotes2/.Listactivity

There are also errors about missing translations in strings.xml to nb (Norwegian Bokmål)

kwhitefoot commented 7 years ago

I can't reproduce the runtime failure.

Exactly what actions lead to it?

N0ury commented 7 years ago

I haven't time to do anything. The app crashes as soon as I tap the icon. I have removed old app from my device. The account configuration activity is not displayed. I've tried to make the StubProvider class public, but it's the same. Even if the error message has disappeared. I use a galaxy A5 2016 with Android 6.0.1

kwhitefoot commented 7 years ago

Fixed. I had a syntax error in an SQL create for a new table.

N0ury commented 7 years ago

Sorry, just tested, same error. The app crashes immediately. Does it work for you when you run the app? At least, the first time after install

01-30 21:29:18.738 27290 27290 E AndroidRuntime: FATAL EXCEPTION: main 01-30 21:29:18.738 27290 27290 E AndroidRuntime: Process: com.Pau.ImapNotes2, PID: 27290 01-30 21:29:18.738 27290 27290 E AndroidRuntime: java.lang.RuntimeException: Unable to get provider com.Pau.ImapNotes2.Sync.StubProvider: java.lang.IllegalAccessException: java.lang.Class is not accessible from java.lang.Class 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:6871) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.installContentProviders(ActivityThread.java:6463) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6403) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.access$1800(ActivityThread.java:229) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1887) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:7325) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: Caused by: java.lang.IllegalAccessException: java.lang.Class is not accessible from java.lang.Class 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at java.lang.Class.newInstance(Native Method) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:6856) 01-30 21:29:18.738 27290 27290 E AndroidRuntime: ... 10 more 01-30 21:29:18.748 2624 3405 W ActivityManager: Force finishing activity com.Pau.ImapNotes2/.Listactivity

kwhitefoot commented 7 years ago

Grr!

[☹]

Thanks for testing. I'll try again.

------ Unix is like a wigwam: no gates, no windows and an Apache inside.