PubSub not automatically downloading enclosures
PubSub not automatically downloading enclosures
- Subject: PubSub not automatically downloading enclosures
- From: "Colin Barrett" <email@hidden>
- Date: Sat, 27 Sep 2008 15:54:51 -0700
I'm having some problems with PubSub not downloading enclosures. I'm
running 10.5.5 and using Xcode 3.1.1. If this is the wrong list, my
apologies.
Here's a codesample that seems to not be working.
-----------
- (void)awakeFromNib
{
PSClient *client = [PSClient applicationClient];
PSFeedSettings *settings = client.settings;
settings.downloadsEnclosures = YES;
settings.enclosureTypes = [NSArray arrayWithObject:@"image/jpeg"];
settings.maxEnclosureSize = PSFeedSettingsUnlimitedSize;
settings.refreshesInBackground = NO;
client.settings = settings;
client.delegate = self;
PSFeed *feed = [client addFeedWithURL:[NSURL
URLWithString:@"http://api.flickr.com/services/feeds/photos_public.gne?id=13058742@N00&lang=en-us&format=atom"]];
[feed refresh:NULL];
}
- (void)feed:(PSFeed *)feed didAddEntries:(NSArray *)entries
{
NSLog(@"%@ added entries %@", feed, entries);
}
- (void)enclosure:(PSEnclosure *)enclosure
downloadStateDidChange:(PSEnclosureDownloadState)state
{
NSLog(@"%@ %d", enclosure, state);
}
----------
When I run the code, I get the following output:
----------
2008-09-27 15:42:26.434 PhotoRSS[92602:10b]
PSFeed[<http://api.flickr.com/services/feeds/photos_public.gne?id=13058742@N00&lang=en-us&format=atom>
2/8] added entries (
PSEntry['Happy Birthday' 3166],
PSEntry['OpenDoc ftw' 3157],
PSEntry['Loot from Portland' 3159],
PSEntry['Nerd mode engage!' 3158],
PSEntry['Anne' 3170],
PSEntry['Ready for Action' 3171],
PSEntry['Hotel Monaco' 3155],
PSEntry['Palin hates polar bears' 3172],
PSEntry['Nice Hawaii license plate!' 3165],
PSEntry['photo.jpg' 3163],
PSEntry['KILL' 3164],
PSEntry['WALL·E Rides ... Muni?' 3169],
PSEntry['My new pixel rig' 3162],
PSEntry['Aloha Shoyu is the best, don't pose' 3161],
PSEntry['New glasses have arrived!' 3160],
PSEntry['New Digs' 3168],
PSEntry['L&Ls Loco Moco and Spam musubi' 3153],
PSEntry['WTF hot sauce?' 3154],
PSEntry['Inside Macintosh' 3156],
PSEntry['CA$H' 3167]
)
---------
As you can see, it does not appear that the enclosures are not
downloading automatically. I even checked in the PubSub sqlite db, and
the downloadedPath column is empty for all enclosures.
Any suggestions? Or is PubSub just broken, and I should just file a
radar and write my own RSS parsing code...
-Colin
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden