View Single Post
Old 02-09-2012, 06:46 PM   #273
ixtab
(offline)
ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.
 
ixtab's Avatar
 
Posts: 2,903
Karma: 6677557
Join Date: Dec 2011
Device: K3, K4, K5, KPW, KPW2
@flat_eric:

your problem is very likely caused by this:
Code:
120206:235032 cvm[1193]: E StateMachine:Error::failed to process action
120206:235032 cvm[1193]: java.lang.IllegalArgumentException: can't parse argument number 0.number
120206:235032 cvm[1193]: 	at java.text.MessageFormat.makeFormat(Compiled Method)(Unknown Source)
120206:235032 cvm[1193]: 	at java.text.MessageFormat.applyPattern(Compiled Method)(Unknown Source)
120206:235032 cvm[1193]: 	at java.text.MessageFormat.<init>(Compiled Method)(Unknown Source)
120206:235032 cvm[1193]: 	at java.text.MessageFormat.format(Unknown Source)
120206:235032 cvm[1193]: 	at com.amazon.ebook.booklet.reader.plugin.notesandmarks.AnnotationView.updateAnnotations(wld:933)
Since it's not obvious how to track down such errors, I'll try to give a step-by-step explanation below.

0. In order to even find such errors, you should be logged in on the Kindle, and watch "showlog -f". Debug mode may be a good decision as well, though it's not needed for this particular mistake.
1. The error is initially caused by "java.text.MessageFormat.format()" at "com.amazon.ebook.booklet.reader.plugin.notesandma rks.AnnotationView.updateAnnotations()".
2. This indicates a wrong translation somewhere, but how do we find out where?
3. We find out from the stack trace that we should probably take a look at the method updateAnnotations() in com.amazon.ebook.booklet.reader.plugin.notesandmar ks.AnnotationView.
4. http://wiki.mobileread.com/wiki/Kind...on.27s_classes gives some valuable hints on how to achieve this.
5. In the decompiled method, we only find one line of interest: String a = rb.getString("annotation.info.page");
6. ... where: rb = ResourceBundle.getBundle("com.amazon.ebook.booklet .reader.plugin.notesandmarks.resources.AnnotationR esources");
7. Finally, we take a look at that resource in transifex:


... and you should immediately see where the error comes from.

(This uses eureka's previous hint of enabling "verbose editing" on transifex to display resource names, shown in green). And it clearly shows that care must be taken while translating...
ixtab is offline   Reply With Quote