appdotnet / pourover

RSS publishing for App.net
35 stars 10 forks source link

Produce Geo-Annotations form Instagram Posts containing Geo-Information #10

Open mdornseif opened 10 years ago

mdornseif commented 10 years ago

Currently I maintain http://im-fluss.appspot.com to transfer geo data from Instagam to ADN posts. The resulting posts look like https://alpha.app.net/peter_hacker/post/13376289

The relevant code looks like this (complete code here:

    media, next = instagram_client.user_recent_media()
    for image in reversed(media):
        if hasattr(image, 'location') and hasattr(image.location, 'point') and image.location.point:
            # handle geolocation information
            post['annotations'].append(
                dict(type='net.app.core.geolocation',
                     value=dict(latitude=image.location.point.latitude,
                                longitude=image.location.point.longitude)))

Adding geolocation support to pour over would help to promote the use of annotations and show how feature rich bridges can be.

I have not oriented me in the pour over codebase very much, but it seems models. InstagramFeed .process_feed(), models.Entry and poster.instagram_format_for_adn would need updating.

voidfiles commented 10 years ago

this is a good idea, and I will implement it when I get a chance. If you had the time to put together a pull request that would make things easier.