Skip Menu |

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

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

People
Owner: Nobody in particular
Requestors: jworkman [...] pimpworks.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.82
Fixed in: 0.84



Subject: friends_from_profile() returns own friends
Date: Tue, 24 Jun 2008 10:30:00 -0400
To: bug-WWW-Myspace [...] rt.cpan.org
From: Jeff Workman <jworkman [...] pimpworks.org>
With the code below, friends_from_profile seems to be getting friends from my own profile rather than the one specified. This even occurs when "exclude." Whatever is causing this has also broken WWW::Myspace::FriendAdder which depends on this module. $bandid = 20308530; # 20308530 is not me my @current_friends = $myspace->get_friends; my @friends = $myspace->friends_from_profile( id => $bandid, exclude => \@current_friends );
Subject: Re: [rt.cpan.org #37057] friends_from_profile() returns own friends
Date: Tue, 24 Jun 2008 15:06:35 -0700
To: bug-WWW-Myspace [...] rt.cpan.org
From: Grant Grueninger <grantg [...] spamarrest.com>
Thanks for reporting this Jeff. I've removed the outdated "exclude" example from the friends_from_profile code - The "exclude" option was deprecated in WWW::Myspace 0.62 when we had to re-write the underlying get_friends_from_page method. So, that's why "exclude" wasn't working. As for the method returning your friends, one of us will have to look into that more. Steven and Olaf: This appears to be an issue in get_friends (which is called by friends_from_profile), but I can't on first scan find the issue, since the profile ID should be in the URL, which is just retrieved from the page code. Grant On Jun 24, 2008, at 7:35 AM, Jeff Workman via RT wrote: Show quoted text
> Tue Jun 24 10:34:35 2008: Request 37057 was acted upon. > Transaction: Ticket created by jworkman@pimpworks.org > Queue: WWW-Myspace > Subject: friends_from_profile() returns own friends > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: jworkman@pimpworks.org > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=37057 > > > > With the code below, friends_from_profile seems to be getting friends > from my own profile rather than the one specified. This even occurs > when "exclude." Whatever is causing this has also broken > WWW::Myspace::FriendAdder which depends on this module. > > $bandid = 20308530; # 20308530 is not me > my @current_friends = $myspace->get_friends; > my @friends = $myspace->friends_from_profile( > id => $bandid, > exclude => \@current_friends > ); > > >
RT-Send-CC: john [...] deedevelopments.com
Hi, I've just committed R-610 to SVN which I believe fixes this. Unfortunately there seems to be nothing in the test suite at the moment regarding the get_friends functions, so it won't be immediately obvious if this breaks again in future. Ideally some tests can be added before the next release (0.83). This was caused by the new Myspace header/banner area, which added a 'view my friends' link. After loading a user's profile, get_friends was wrongly following that link instead of the 'view friends' link on the profile. Thanks!