Today, I spent a few hours migrating my site back to one of my SliceHost servers. The appEngine just wasn't doing it for me. The biggest problem was storage limitations in regards to the size of files you could store. The AppEngine only allows 1mb files to be stored which is sadly stored on the database itself. Limitations like that meant that I could not host my own photo gallery and I missed not having my own gallery! Using Picasa would have been the alternative but, at the time, I didn't feel motivated enough to implement that. The nice thing about Django is that it automatically comes with a fairly straightforward administrative tool whereas the AppEngine makes you somewhat responsible for writing your own administrative tools.
Disqus comments rock! Previously, I was relying on Django comments. After that I tried a custom comments system that I made but was getting way too much spam so I decided to completely axe comments altogether. About a year or so ago I discovered Disqus but I never got around to actually implementing their comment system. 5 minutes was literally all it took to install and I was up and running. The only thing I have left is to customise the look and feel of the comment system. Though, at some point, I may try to use their new API to have a more tightly integrated comment system.
Leave a comment
Last week I updated Python-TwiPic to API v2.0. TwitPic announced that they will continue supporting the old version, however, I recommend upgrading to the latest and greatest. Version 2.0 addresses some security concerns and comes with tons more functionality than the previous.
A while back Twitter introduced an extension to oAuth called Echo oAuth. In short, it's a way to provide a Twitter access_token to the media provider (TwitPic) instead of providing a username and password. As you may already know, TwitPic introduced more than photo uploading to their API. Now you can leave comments group and assign photos to events, and tag faces in a photo. I personally am only using TwitPic to upload photos but the extra features could be nice depending on your intentions.
The only request methods that TwitPic currently accepts are GET and POST. In this library, I chose to break up the method request calls into the four main RESTful request groups GET, PUT, POST, DELETE. Each request method belongs to a RESTful request group depending on it's function. Below is an example use case. You must first choose the appropriate method which is either: read, create, update, or remove. Then you pass a method the method call name and a dictionary of parameters (not including a service key). Seems pretty straightforward I hope. Also keep in mind that you are responsible for getting a user's access_token and should be passed as a string which I believe is fairly standard practice.
Usage:
| import twitpic2
twitpic = twitpic2.TwitPicOAuthClient(
consumer_key = CONSUMER_KEY,
consumer_secret = CONSUMER_SECRET,
access_token = ACCESS_TOKEN,
service_key = SERVICE_KEY
)
# methods - read, create, update, remove
response = twitpic.create(METHOD_CALL, PARAMS)
|
If you find any bugs please create a ticket so that I can fix them.
Leave a comment