Skip Menu |

This queue is for tickets about the WWW-Myspace CPAN distribution.

Report information
The Basics
Id: 38716
Status: resolved
Priority: 0/
Queue: WWW-Myspace

People
Owner: steven [...] pyro.eu.org
Requestors: wilpower50 [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.85
Fixed in: 0.86



Subject: get_friends
Date: Mon, 25 Aug 2008 15:56:34 -0500
To: bug-WWW-Myspace [...] rt.cpan.org
From: "Rick Smith" <wilpower50 [...] gmail.com>
Hello I'm having an issue with the get_friends module, or more specifically, the follow_link called by the get_friends module. I am utilizing the get_friends function using args source => 'profile', id => $friend_id If I execute the following code: $myspace->new() $myspace->get_friends( source => 'profile', id => '12345' ); $myspace->get_friends( source => 'profile', id => '67890' ); The second call to $myspace->get_friends (for 67890) returns no friends. The issue appears to be that when follow_link is called from get_friends, the regex that is known to follow_link is from the previous call to get_friends. The variables are being set properly in get_friends. but when follow_link is called a second time from get_friends, the @_ variables within follow_link seem to still be set from the initial call. I'm running on a win32 platform utilizing myspace 0.84 activeperl 5.8.8 build 819 spiffy 0.30 thanks Derek
I can reproduce the problem here. Interestingly, if I reverse the order of those function calls, it doesn't seem to be able to retrieve friends from *either* of the profiles. Very strange... I'm still investigating. Thanks for reporting. -- Steven Chamberlain steven@pyro.eu.org
Aha! It seems the 67890 profile is a rather special one. Someone (a band with friend ID 308098330) registered "67890" as their 'Myspace URL' so these URLs actually show different profiles: http://www.myspace.com/67890 http://profile.myspace.com/index.cfm?fuseaction=user.viewprofile&friendid=67890 The get_friends function uses the latter form, which is actually a personal profile set as 'private', so get_friends is rightly returning 'undef' for that profile. But there's still something wrong because the subsequent call to get_friends for friend ID 12345 should still work. -- Steven Chamberlain steven@pyro.eu.org
Subject: Re: [rt.cpan.org #38716] get_friends
Date: Mon, 25 Aug 2008 16:41:01 -0500
To: bug-WWW-Myspace [...] rt.cpan.org
From: "Rick Smith" <wilpower50 [...] gmail.com>
Hi Steve Apologies, I should have mentioned that those were "placeholder numbers" for the profiles. Both of the profiles I'm trying to retrieve are public, individual profiles. Derek On Mon, Aug 25, 2008 at 4:16 PM, Steven Chamberlain via RT < bug-WWW-Myspace@rt.cpan.org> wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=38716 > > > I can reproduce the problem here. Interestingly, if I reverse the order > of those function calls, it doesn't seem to be able to retrieve friends > from *either* of the profiles. Very strange... I'm still investigating. > > Thanks for reporting. > > -- > Steven Chamberlain > steven@pyro.eu.org > >
Hi, No matter, I was able to reproduce the problem with profiles 12345 and 67890 anyway. It turns out that get_friends was permanently compiling the regexp for follow_link only once (because of the 'o' flag), using only the value of $profile_id specified in the first call to that method. Please try SVN R-637 which I believe should fix it. I'll be adding some tests for this bug to the test suite shortly. Thanks, -- Steven Chamberlain steven@pyro.eu.org
Subject: Re: [rt.cpan.org #38716] get_friends
Date: Mon, 25 Aug 2008 18:17:12 -0500
To: bug-WWW-Myspace [...] rt.cpan.org
From: "Rick Smith" <wilpower50 [...] gmail.com>
Steve Works perfectly. Many thanks Derek On Mon, Aug 25, 2008 at 4:58 PM, Steven Chamberlain via RT < bug-WWW-Myspace@rt.cpan.org> wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=38716 > > > Hi, > > No matter, I was able to reproduce the problem with profiles 12345 and > 67890 anyway. > > It turns out that get_friends was permanently compiling the regexp for > follow_link only once (because of the 'o' flag), using only the value of > $profile_id specified in the first call to that method. > > Please try SVN R-637 which I believe should fix it. I'll be adding some > tests for this bug to the test suite shortly. > > Thanks, > -- > Steven Chamberlain > steven@pyro.eu.org > >