Notices


Reply
Thread Tools
Posts: 6 | Thanked: 0 times | Joined on Sep 2010
#1121
can i install QBW in pc
how to do this
 
Posts: 5 | Thanked: 1 time | Joined on Feb 2011 @ USA
#1122
Hi, No!No!No!Yes!

I love your app, I have been busy replacing my regular widgets with beecons for the past week or so,
and I am currently working on a "like button" for my mp3 player",
I dump a bunch of new songs onto a folder, and if I hear a song i like, I just press the LIKEbutton,
and it saves the song file to another folder.

it seems to be working well, but I think I found a bug in queenbeecon,
I am using QBW V1.3.3, and my N900 firmware is up to date.

the LIKEbutton uses the DBUS to get the currently playing song from the media player (I am using Mediabox player),
but if the song titles have single quotes in them (" ' "), $QBW_DBUS_VERBOSE_OUTPUT returns NOTHING,
in fact, the entire script seems to crash, returning an exit code 2.

I set up a demo beecon that was taken from your own Wiki page,
with a slight modification to include a " ' " in a DBUS output string.

Code:
run-standalone.sh dbus-send --system --type=signal /com/example/app/Signal com.example.app.Signal.Test string:'Oh' string:'No!!!' string:'More QBWs!!!' string:"single quotes don't work here" boolean:true uint32:10000
if you change
"single quotes don't work here"
to
"single quotes dont work here"
the script works fine.


here is the beecon that demonstrates the bug (original script code from Wiki):
Code:
[queen-beecon-header]
version=1.000000
checksum=2855790
[queen-beecon-exported-instance]
widgetType=0
widgetVisible=1
operationalStatus=0
hideCanvas=false
hideClickCanvas=true
snippetBgRGB=0
snippetExtBgRGB=#83477ee7845f
beecon_lt0_ImgZoom=0
beecon_lt0_BgRGB=2
beecon_lt0_ExtBgRGB=#808080808080
beecon_lt0_ImgFilename=
beecon_eq0_ImgZoom=0
beecon_eq0_BgRGB=3
beecon_eq0_ExtBgRGB=#0000ffff0000
beecon_eq0_ImgFilename=
beecon_eq1_ImgZoom=0
beecon_eq1_BgRGB=4
beecon_eq1_ExtBgRGB=#ffff00000000
beecon_eq1_ImgFilename=
beecon_ge2_ImgZoom=0
beecon_ge2_BgRGB=5
beecon_ge2_ExtBgRGB=#ffffffff0000
beecon_ge2_ImgFilename=
beecon_idxge2_ImgZoom=0
beecon_idxge2_BgRGB=11
beecon_idxge2_ExtBgRGB=#ffff8c080000
beecon_idxge2_ImgFilename=
widWidth=500.67741935483866
widHeight=320.57142857142856
instanceTitle=single quote fail
instanceCmd=echo "$QBW_ID $QBW_EXEC_REASON"; echo '$QBW_DBUS_VERBOSE_OUTPUT'; exit 2
rememberMe=
cmdImgFilename=
cmdImgAngle=0
cmdImgZoom=0
cmdFgRGB=1
cmdExtFgRGB=#ffffffffffff
cmdTextAngle=0
cmdVisibilityPosition=0
cmdImgVisibilityPosition=5
cmdJustify=0
cmdExtFont=Nokia Sans bold italic 12
cmdFontName=3
cmdFontSize=12
resImgFilename=queen-beecon-resimg.png
resImgAngle=0
resImgZoom=0
resFgRGB=1
resExtFgRGB=#000000000000
resTextAngle=0
resVisibilityPosition=1
resImgVisibilityPosition=5
resJustify=0
resExtFont=Nokia Sans Cn 17
resFontName=16
resFontSize=10
resWrapLongLines=true
progressAnimationFrames=4
progressAnimationTimer=4
progressAnimationPos=4
progressAnimationAtClickXY=false
progressAnimationBasename=queen-beecon-progress
updOnStartup=false
updOnClick=true
multiClick=false
updOnDesktop=false
updOnSight=false
updOnOrientation=false
delayIndex=0
customIntervalSecs=0
updNeworkPolicy=0
GPSsettings=0
updOnDBUS=1
updOnDBUSBus=0
updOnDBUSMatchRule=type='signal',interface='com.example.app.Signal'

Thanks for reading
 

The Following User Says Thank You to Midnite_Rider For This Useful Post:
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#1123
Originally Posted by ioiomi View Post
can i install QBW in pc
how to do this
Sorry ... N900 only. No immediate plans to cross-porting.
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#1124
Originally Posted by Midnite_Rider View Post
Hi, No!No!No!Yes!

I love your app, I have been busy replacing my regular widgets with beecons for the past week or so,
and I am currently working on a "like button" for my mp3 player",
I dump a bunch of new songs onto a folder, and if I hear a song i like, I just press the LIKEbutton,
and it saves the song file to another folder.

it seems to be working well, but I think I found a bug in queenbeecon,
I am using QBW V1.3.3, and my N900 firmware is up to date.

the LIKEbutton uses the DBUS to get the currently playing song from the media player (I am using Mediabox player),
but if the song titles have single quotes in them (" ' "), $QBW_DBUS_VERBOSE_OUTPUT returns NOTHING,
in fact, the entire script seems to crash, returning an exit code 2.

I set up a demo beecon that was taken from your own Wiki page,
with a slight modification to include a " ' " in a DBUS output string.

Code:
run-standalone.sh dbus-send --system --type=signal /com/example/app/Signal com.example.app.Signal.Test string:'Oh' string:'No!!!' string:'More QBWs!!!' string:"single quotes don't work here" boolean:true uint32:10000
if you change
"single quotes don't work here"
to
"single quotes dont work here"
the script works fine.


here is the beecon that demonstrates the bug (original script code from Wiki):
Code:
[queen-beecon-header]
version=1.000000
checksum=2855790
[queen-beecon-exported-instance]
widgetType=0
widgetVisible=1
operationalStatus=0
hideCanvas=false
hideClickCanvas=true
snippetBgRGB=0
snippetExtBgRGB=#83477ee7845f
beecon_lt0_ImgZoom=0
beecon_lt0_BgRGB=2
beecon_lt0_ExtBgRGB=#808080808080
beecon_lt0_ImgFilename=
beecon_eq0_ImgZoom=0
beecon_eq0_BgRGB=3
beecon_eq0_ExtBgRGB=#0000ffff0000
beecon_eq0_ImgFilename=
beecon_eq1_ImgZoom=0
beecon_eq1_BgRGB=4
beecon_eq1_ExtBgRGB=#ffff00000000
beecon_eq1_ImgFilename=
beecon_ge2_ImgZoom=0
beecon_ge2_BgRGB=5
beecon_ge2_ExtBgRGB=#ffffffff0000
beecon_ge2_ImgFilename=
beecon_idxge2_ImgZoom=0
beecon_idxge2_BgRGB=11
beecon_idxge2_ExtBgRGB=#ffff8c080000
beecon_idxge2_ImgFilename=
widWidth=500.67741935483866
widHeight=320.57142857142856
instanceTitle=single quote fail
instanceCmd=echo "$QBW_ID $QBW_EXEC_REASON"; echo '$QBW_DBUS_VERBOSE_OUTPUT'; exit 2
rememberMe=
cmdImgFilename=
cmdImgAngle=0
cmdImgZoom=0
cmdFgRGB=1
cmdExtFgRGB=#ffffffffffff
cmdTextAngle=0
cmdVisibilityPosition=0
cmdImgVisibilityPosition=5
cmdJustify=0
cmdExtFont=Nokia Sans bold italic 12
cmdFontName=3
cmdFontSize=12
resImgFilename=queen-beecon-resimg.png
resImgAngle=0
resImgZoom=0
resFgRGB=1
resExtFgRGB=#000000000000
resTextAngle=0
resVisibilityPosition=1
resImgVisibilityPosition=5
resJustify=0
resExtFont=Nokia Sans Cn 17
resFontName=16
resFontSize=10
resWrapLongLines=true
progressAnimationFrames=4
progressAnimationTimer=4
progressAnimationPos=4
progressAnimationAtClickXY=false
progressAnimationBasename=queen-beecon-progress
updOnStartup=false
updOnClick=true
multiClick=false
updOnDesktop=false
updOnSight=false
updOnOrientation=false
delayIndex=0
customIntervalSecs=0
updNeworkPolicy=0
GPSsettings=0
updOnDBUS=1
updOnDBUSBus=0
updOnDBUSMatchRule=type='signal',interface='com.example.app.Signal'

Thanks for reading
Thanks for thorough reporting
Actually, I think the problem here is the:
Code:
echo '$QBW_DBUS_VERBOSE_OUTPUT'
That gets replaced as something like:
Code:
echo '.....single quotes don't work here...'
Thus causing the uneven single quote character balancing and shell statement to fail (Unterminated quoted string)

How about trying with:
Code:
echo "$QBW_DBUS_VERBOSE_OUTPUT"
This way maybe you'll get rid of your current problem but you could have the side effect of noticing weird behaviour with songs with shell special characters in their title.
Like for example: '...$$$ for nothing...'

One more thing to try (shell Here Documents):
Code:
echo <<LikeThisSong
$QBW_DBUS_VERBOSE_OUTPUT
LikeThisSong
Let me now
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 
moudy91's Avatar
Posts: 165 | Thanked: 18 times | Joined on Jun 2010
#1125
i usual i use the cat command so i can see my notes but i need a script that i will access it from my desktop, and the location of my note is /home/user/MyDocs/note.html
how can i do that ?
i have this script but i can't open my text location:

dbus-send --type=method_call --dest=com.nokia.HildonDesktop.AppMgr /com/nokia/HildonDesktop/AppMgr com.nokia.HildonDesktop.AppMgr.LaunchApplication string:"osso_notes"

please can anyone correct it, thank you
 
Posts: 5 | Thanked: 1 time | Joined on Feb 2011 @ USA
#1126
Originally Posted by No!No!No!Yes! View Post
Thanks for thorough reporting
Actually, I think the problem here is the:
Code:
echo '$QBW_DBUS_VERBOSE_OUTPUT'
How about trying with:
Code:
echo "$QBW_DBUS_VERBOSE_OUTPUT"
Tried that, one of the first things I tried, I even tried putting the quotes into strings,
Code:
QT="'"; echo $QT$QBW_DBUS_VERBOSE_OUTPUT$QT
but even if I used the wrong quoting, I would still get something returned from the variable,
like this: "single quotes don"
but this is a far more serious problem, since the entire script crashes, and I get no output at all.

I will add some code to the demo beecon before $QBW_DBUS_VERBOSE_OUTPUT is read to confirm that the beecon code crashes, but I'm pretty sure it does crash .


One more thing to try (shell Here Documents):
Code:
echo <<LikeThisSong
$QBW_DBUS_VERBOSE_OUTPUT
LikeThisSong
It looks like that I would be simply inserting the data into a string,
the same as doing:
Code:
 QBW_DBUS_VERBOSE_OUTPUT="single quotes don't work here"
and that isn't going to get me anywhere, since the data is coming from MY code, and I can escape it any way I want.

the problem is that $QBW_DBUS_VERBOSE_OUTPUT
is being set internally by YOUR code, so there isn't anything I can do to correct it after it was set by QBW.

Please try out the beecon & DBUS command I posted above, and see for yourself .

thanks
 
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#1127






__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 
Posts: 5 | Thanked: 1 time | Joined on Feb 2011 @ USA
#1128
well, I was wrong,
it does seem to work, but it's not very useful, unfortunately.

it only displays the entire dbus output, you can't pass it to another variable for further processing, and a here-doc that was posted on the page you linked to is SUPPOSED to pass the output to a variable doesn't seem to work
Code:
variable=$(cat <<SETVAR
This variable
runs over multiple lines.
SETVAR)

echo "$variable"
So, I guess that you aren't going to fix the bug in your app ?
or even look to see if it can be fixed ?

I would think it can be fixed, since the dbus output shows up in the QBW logs & is formatted correctly .

Thanks for pointing me to the here-docs though, at least I learned something new for all my effort .
 
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#1129
Originally Posted by Midnite_Rider View Post
well, I was wrong,
it does seem to work, but it's not very useful, unfortunately.

it only displays the entire dbus output, you can't pass it to another variable for further processing, and a here-doc that was posted on the page you linked to is SUPPOSED to pass the output to a variable doesn't seem to work
Code:
variable=$(cat <<SETVAR
This variable
runs over multiple lines.
SETVAR)

echo "$variable"
So, I guess that you aren't going to fix the bug in your app ?
or even look to see if it can be fixed ?

I would think it can be fixed, since the dbus output shows up in the QBW logs & is formatted correctly .

Thanks for pointing me to the here-docs though, at least I learned something new for all my effort .
It's not a bug in the app.
It's just a matter of scripting skills and shell knowledge.
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 
Posts: 5 | Thanked: 1 time | Joined on Feb 2011 @ USA
#1130
well, if a single character (" ' ") causing an entire script to crash isn't a bug, than I don't know what is, (and it does crash, I checked).

I'm not trying to do anything unusual in the beecon, just trying to extract data from $QBW_DBUS_VERBOSE_OUTPUT, and it works just fine, until it encounters a single quote in the dbus message, how is that not a bug ?

why would I need to add several extra lines of code just to handle quote chars when a:
"my_variable=$QBW_DBUS_VERBOSE_OUTPUT"
should suffice for ALL printable chars.?

and that screenshot you posted shows that the script is clearly NOT running on your widget.
 
Reply


 
Forum Jump


All times are GMT. The time now is 14:14.