NumberFormatException in RingtonePreferenceDialogFragmentCompat
See original GitHub issueHello, I’m getting this exception on a Pixel 3.
java.lang.NumberFormatException:
at java.lang.Long.parseLong (Long.java:594)
at java.lang.Long.parseLong (Long.java:636)
at android.content.ContentUris.parseId (ContentUris.java:89)
at android.media.RingtoneManager.getRingtonePosition (RingtoneManager.java:513)
at com.takisoft.preferencex.RingtonePreferenceDialogFragmentCompat.a (RingtonePreferenceDialogFragmentCompat.java:146)
at com.takisoft.preferencex.RingtonePreferenceDialogFragmentCompat.a (RingtonePreferenceDialogFragmentCompat.java:11)
at androidx.preference.PreferenceDialogFragmentCompat.a (PreferenceDialogFragmentCompat.java:50)
at com.takisoft.preferencex.RingtonePreferenceDialogFragmentCompat.access$000 (RingtonePreferenceDialogFragmentCompat.java)
or .access$002 (RingtonePreferenceDialogFragmentCompat.java)
or .access$202 (RingtonePreferenceDialogFragmentCompat.java)
or .access$600 (RingtonePreferenceDialogFragmentCompat.java)
or .access$700 (RingtonePreferenceDialogFragmentCompat.java)
or .addCustomExternalRingtone (RingtonePreferenceDialogFragmentCompat.java)
or .buildAdapter (RingtonePreferenceDialogFragmentCompat.java)
or .buildUniqueFile (RingtonePreferenceDialogFragmentCompat.java)
or .createCursor (RingtonePreferenceDialogFragmentCompat.java)
or .getFileDisplayNameFromUri (RingtonePreferenceDialogFragmentCompat.java)
or .getUniqueExternalFile (RingtonePreferenceDialogFragmentCompat.java)
or .newInstance (RingtonePreferenceDialogFragmentCompat.java)
or .onCreateDialog (RingtonePreferenceDialogFragmentCompat.java)
or .onDialogClosed (RingtonePreferenceDialogFragmentCompat.java)
or .onPrepareDialogBuilder (RingtonePreferenceDialogFragmentCompat.java)
or .splitFileName (RingtonePreferenceDialogFragmentCompat.java)
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
java - What is a NumberFormatException and how can I fix it?
An exception is an event, which occurs during the execution of a program, that disrupts the normal flow of the program's instructions. - ......
Read more >@android.support.annotation.Nullable Example - Program Talk
... catch (NumberFormatException e) { Log.w(TAG, e); return null; } } ... View Source File : RingtonePreferenceDialogFragmentCompat.java , License : GNU ...
Read more >如何在Java 中处理NumberFormatException, Double 的 ...
RingtonePreferenceDialogFragmentCompat throws ,. NumberFormatException 基本上是因为输入的字符串在解析成数值时格式不正确或者非法造成的。因此,为避免此异常, ...
Read more >How to handle the NumberFormatException (unchecked) in ...
The NumberFormatException is an unchecked exception thrown by parseXXX() methods when they are unable to format (convert) a string into a ...
Read more >ERROR java.lang.NumberFormatException: For input string
What is wrong? Here is the log: PWC1406: Servlet.service() for servlet Faces Servlet threw exception java.lang.NumberFormatException: For input ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Do those devices run Android 10 as well?
@Gericop do you know where the list of added custom notification sounds is stored? I would like to clear it in the following case:
I see that if you start fresh with Android 10, a toast is shown when trying to add a custom ringtone which is still better than a completely unusable RingtonePreference like the case above.
Edit: the exception I’m getting comes from
onPrepareDialogBuilderwherecreateCursoris called.