From: Alexander A Khryukin <alexander@mezon.ru>
To: ofono@ofono.org
Subject: Re: list-modems patch
Date: Thu, 14 Oct 2010 13:17:29 +0400 [thread overview]
Message-ID: <1287047849.32351.16.camel@mezon.ru> (raw)
In-Reply-To: <1287045918.3316.34.camel@aeonflux>
[-- Attachment #1: Type: text/plain, Size: 2432 bytes --]
В Чтв, 14/10/2010 в 11:45 +0300, Marcel Holtmann пишет:
> Hi Alex,
>
> > Sometimes i see
> >
> > [root(a)alexander-desktop ofono-0.31]# /usr/lib/ofono/test/list-modems
> > [ /huawei5 ]
> > Features = sim
> > Powered = 1
> > Interfaces = org.ofono.Phonebook org.ofono.AudioSettings
> > org.ofono.VoiceCallManager org.ofono.SimManager
> > Online = 0
> > Model = E1550
> > Manufacturer = huawei
> > Serial = 353142033084081
> > Revision = 11.608.12.00.143
> > [ org.ofono.Phonebook ]
> > [ org.ofono.AudioSettings ]
> > Traceback (most recent call last):
> > File "/usr/lib/ofono/test/list-modems", line 61, in <module>
> > print " %s = %s" % (key, val).encode('ascii')
> >
> >
> > Patch
> >
> >
> >
> > diff --git a/test/list-modems b/test/list-modems
> > index 557efd5..df1dca8 100755
> > --- a/test/list-modems
> > +++ b/test/list-modems
> > @@ -58,6 +58,10 @@ for path, properties in modems:
> > ")" for text, icon in
> > properties[key] ])
> > else:
> > val = str(properties[key])
> > - print " %s = %s" % (key, val)
> > + try:
> > + print " %s = %s" % (key, val)
> > + except:
> > + continue
> > +
>
> can you at least print the key value. Just not printing that property at
> all is bad since it is there. Just marking the value as not printable
> seems to be the better approach.
>
> Regards
>
> Marcel
>
>
>
Little fix
diff --git a/test/list-modems b/test/list-modems
index 557efd5..f8f10ac 100755
--- a/test/list-modems
+++ b/test/list-modems
@@ -58,6 +58,12 @@ for path, properties in modems:
")" for text, icon in
properties[key] ])
else:
val = str(properties[key])
- print " %s = %s" % (key, val)
+ try:
+ print " %s = %s" % (key, val)
+ except:
+ print "Script mesaage:maybe wrong ASCII
characters\n"
+ else:
+ continue
+
print
next prev parent reply other threads:[~2010-10-14 9:17 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-13 13:54 [PATCH 01/13] voicecall: __ofono_voicecall_send_tone internal api Andrzej Zaborowski
2010-10-13 13:54 ` [PATCH 02/13] stk: Handle the Send DTMF proactive command Andrzej Zaborowski
2010-10-14 8:55 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 03/13] atmodem: Handle pauses in DTMF string Andrzej Zaborowski
2010-10-13 13:54 ` [PATCH 04/13] doc: Update property name to match code Andrzej Zaborowski
2010-10-14 5:56 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 05/13] doc: Add STK properties relevant for icons Andrzej Zaborowski
2010-10-14 8:08 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 06/13] stk: Pass icon IDs in stk agent request parameters Andrzej Zaborowski
2010-10-14 8:09 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 07/13] stk: Add icon ID information in stk_menu Andrzej Zaborowski
2010-10-14 8:09 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 08/13] stk: IdleModeIcon and MainMenuIcon properties Andrzej Zaborowski
2010-10-14 8:10 ` Denis Kenzior
2010-10-14 8:31 ` list-modems patch Alexander A Khryukin
2010-10-14 8:45 ` Marcel Holtmann
2010-10-14 9:17 ` Alexander A Khryukin [this message]
2010-10-14 9:34 ` Alexander A Khryukin
2010-10-14 10:13 ` Marcel Holtmann
2010-10-14 10:36 ` Alexander A Khryukin
2010-10-15 6:17 ` Marcel Holtmann
2010-10-13 13:54 ` [PATCH 09/13] stk: Simplify and add icon to alphaId api Andrzej Zaborowski
2010-10-14 8:56 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 10/13] stk: Apply STK text attributes as html Andrzej Zaborowski
2010-10-14 8:57 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 11/13] stkagent: Add PlayTone and LoopTone requests Andrzej Zaborowski
2010-10-14 9:02 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 12/13] stk: Handle the Play Tone proactive command Andrzej Zaborowski
2010-10-14 9:11 ` Denis Kenzior
2010-10-13 13:54 ` [PATCH 13/13] [RfC] API for STK driver to signal executed commands Andrzej Zaborowski
2010-10-14 9:17 ` Denis Kenzior
2010-10-14 8:47 ` [PATCH 01/13] voicecall: __ofono_voicecall_send_tone internal api Denis Kenzior
2010-10-19 14:10 ` Andrzej Zaborowski
2010-10-19 14:58 ` Denis Kenzior
2010-10-19 15:34 ` Andrzej Zaborowski
2010-10-19 15:59 ` Denis Kenzior
[not found] <1287133345.21789.0.camel@mezon.ru>
2010-10-15 9:09 ` list-modems patch Marcel Holtmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1287047849.32351.16.camel@mezon.ru \
--to=alexander@mezon.ru \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox