Page 42 of 57

Posted: Wed May 02, 2007 4:40 am
by psyXonova
Every once in a while this thread gets on fire and it is always because of my "inability" to post that new version I said I am working on almost a year ago.
I am really glad that there is so much interest for SDj and I feel even happier to see so many scripters stand by me but I am also aware that I have disappointed a *LOT* of ppl. Guest, is one of them but as I have already stated in the past he has a more *offensive* way to express that disappointment than the others.
While seeing posts like his it is also a disappointment for me this is NOT going to change the time I spent on SDj. PhD comes first, it was and still is my dream and even though is not going to "save the world" it surely has changed mine in several ways, you are just experiencing one of them.

Now just to comment on a few things...

1. The problem with the bug that appeared during the last couple of months is due to Last.FM's decision(?) to start serving some of their xml pages with empty "Match" elements. This started happening about 2 months ago and I don't know if it is a problem or a change of policy of Last.FM.
Since the element is missing using Int rather than CInt won't fix the problem as both require a valid number expression to work (empty strings or NULLs are not accepted). This is why the QuickFix I posted is first checking to see if there is an empty string and then proceeds to its conversion. As it is obvious, when the match element is empty the filtering of results based on % match doesn't work.

2. Releasing SDj under an open source license it is something I am thinking of doing for more that 6 months now. As a matter of fact there is a google code page for SDj (http://code.google.com/p/scrobblerdj/) which exists for about that time but it's still empty.... Why is that? Because I don't feel my code is ready for public yet. In fact, my plan is to release SDj 2.0 as an open source project and let ppl continue its development from that point onwards. Perhaps my plans will change and release the code earlier but still this is not going to happen before the end of August since I have to attend several conferences until then and posting the code before a good "cleaning" is done is out of the question... Keep in mind that the current version of SDj is in fact "open source" although not released under any official license. I am a supporter of open source and don't have any problems sharing my code as long as is in a working and readable state. Right now the new code of SDj doesn't fulfill any of those two criteria. This is mainly due to the modular nature of the new code. Many portions of it work really fine but there are not connected with each other and thus it doesn't work as a normal script should.

3. The very first version of SDj was experimental and buggy. Since then I worked hard to update it and version 1.6 works just fine (until that bug I described appeared). Sure, many features are missing but current version does the job it was meant to do pretty well.

Thats it for now...

Thanks.

Posted: Wed May 02, 2007 5:00 am
by A_Disciple
psyXonova-

Thanks for the update and all the work you have put into SDj. I wish you the best in pursuit of your PhD.

Posted: Wed May 02, 2007 5:37 am
by trixmoto
Of course you have (almost) everyone's support including mine, excluding Guest of course! :lol:

Re: New Version (1.26 beta): ScrobblerDJ, Let your music fre

Posted: Wed May 02, 2007 1:09 pm
by sm7urw
Great stuff I guess but when I reach the last file in my playlist I get an error;

Error 6
Overflow: 'CInt'
Line 297 Column 16

Whats the solution.

/ H

Posted: Wed May 02, 2007 1:30 pm
by psyXonova
I have fixed the error and updated the installer as well as the download link (something I should have done weeks ago).

I hope everything will work OK from now on.

Posted: Wed May 02, 2007 5:40 pm
by Ramon Rames
trixmoto wrote:@Guest - Next time you post complaining about this script not being completed when you want it to be, I will delete it. Unless you have something constructive to post, don't bother!! :evil:

@6onova - That code is a non-numeric solution for creating an integer from a real value. Replace "CInt" with "Int" should also work, although the non-numeric solutions seem to work better in some locales.
Hi all,

So the problem solved by my fix is:
Error #13
Type mismatch 'CInt'
scrobblerdj.vbs line 297 column 16
A few explanations:
I first tried using Int instead of CInt but the problem remained.
The fix already published in this thread that simply ignores empty strings does not work either.
It appears the problem is that the decimal separator accepted by Cint (or Int) is the comma (,), whereas lastfm delivers the value with a perdiod (.).
I have to say I did not actually understand this on my first approach (which I said was quick & dirty!!) so here is another, cleaner one (although the other one works just as well):

Code: Select all

                dim xm
                xm = XElmnt.ChildNodes.Item(2).Text
                xm= replace(xm,".",",")

                If CInt(xm) > MinMatch Then
                    XDict.Add i, XElmnt.ChildNodes.Item(0).Text
                End If
To be inserted in place of the if CInt... statement line 297.

Regards

Posted: Wed May 02, 2007 5:57 pm
by Ramon Rames
Just a thought, my language settings are French, I know this can have an incidence on ,/. so the new fix might not work for everyone?? Although logically if the fix doesn't work they shouldn't have the problem either... Anyway whathever !!!

Posted: Wed May 02, 2007 6:01 pm
by Ramon Rames
Oh and Guest, you should try writing your own scripts, it would really do your nerves some good. You cannot beat the feeling you get when your code is up and working !
:wink:

Posted: Thu May 03, 2007 1:53 am
by psyXonova
Ramon Rames wrote:the fix already published in this thread that simply ignores empty strings does not work either.
It appears the problem is that the decimal separator accepted by Cint (or Int) is the comma (,), whereas lastfm delivers the value with a perdiod (.).
Hmmm, haven't noticed that... The xmls that were producing errors to me had an empty element.
I will try to create a new fix based on Ramon's code tonight...

Posted: Thu May 03, 2007 4:42 am
by trixmoto
The decimal separator used by CInt/Int depends on your locale settings whereas Last.Fm will always return a "."

Posted: Thu May 03, 2007 7:00 am
by psyXonova
Yeah, I am thinking of using Val() since this always assumes that decimal separator is period.

Posted: Sun May 06, 2007 2:45 am
by cadmanmeg
So how do I get this script to start? I have it installed and all, but how do I get it to start playing something? Thanks much.

Posted: Sun May 06, 2007 4:01 am
by RedX
just play your list through normally, whe it reaches the last song it wil automatically enqueue a new song ;)

Posted: Tue May 08, 2007 10:21 pm
by Diabolic-Destiny
I accidently deleted the default playlist it used and now i keep getting this error

okay it seems i cant get the error to occur again but the script still isnt working as the song just repeats.

Posted: Wed May 09, 2007 3:46 am
by trixmoto
Create a new playlist with that name, or change the name of the playlist in the settings to one that does exist.