Pages

Monday, June 30, 2008

Facebook Development with Python Saga

The story continues...
There are too many details now so I'm starting to write things down. :) The following are the details on how to set up the development environment and use Facebook APIs in web applications developed with Python. These are Windows specific because that's what I'm using currently.

Python
Install Python. Pretty simple, setup package. No surprises there.

SVN
Install TortoiseSVN or some other SVN client. It is quite handy for accessing various code repositories mentioned here. I'll assume you have it since it makes life so much easier.

There is a PythonPyFacebookTutorial available, which you can take a look at.

Django
I tried installing Django web templates by downloading the latest official release but it did not work. Tired of tweaking around, I downloaded the latest source with SVN and everything went smoothly.
Test by creating a test project and running a test web server.

PyFacebook
Same issue with SVN here. Download the code from the source repository. Run "setup.py install" to install packages.
Run "djangofb.py startapp fbapp" to create the test Facebook application.


Sunday, June 29, 2008

Facebook Development with Python

I'm looking how to develop Facebook apps with Python so that App Engine can be utilized. Need to see what those horse powers under the hood can do. :P
Resources to start with...
Facebook developers wiki page explaining PyFacebook
PyFacebook project
and source code access via http instead of SVN. You might still need an SVN client if you want to update to the latest version. Here is a tutorial on how to use PyFacebook.
To use this lib, you should also use Django web templates (a good idea for Python development generally). Installation instructions for Windows here.

Another, minimalistic, library is gminifb. Examples with minifb, the project prior to gminifb are online. Here is a Hello World project (Hello MiniFB.py) using minifb on Facebook. Includes source code and a tutorial.

WebDev

New era of web development. Actually, new era of software development, since it's all web nowadays.
Yahoo! Pipes, Dapper, Popfly, Appspot...

The list of tools should grow. I need these links as a reference for the tools to use for development.
Not to mention Facebook and other social apps APIs.

Google App Engine Terms of Service

Google App Engine Terms of Service - Google App Engine - Google Code

4.1. Subject to Section 12 of the Terms, the Service is provided
to you without charge for up to 500MB of disk storage, 10GB incoming bandwidth
per day, 10GB outgoing bandwidth per day, 200 million megacycles of CPU per
day and 2,000 emails per day. These quotas will be know as the “Fee Threshold”.
Google reserves the right to change this quota at its discretion.

Wow! I pretty much ignored the limitations of the app engine the first time I was playing with it. But now, looking at what's available it seems that this is practically endless for a single app. And the prices, if the traffic goes past the free limitations, are quite low.
Also, an interesting note is that Google is preparing support for other technologies (Java, PHP, Ruby, ...) to go along the support for Python.
I'm thinking to transfer all my online stuff to appspot...

Design

Financial Matters

Today I've been working on the site design a little bit. This is one of the rare occasions that I dedicated time to that aspect of the web sites. The fact is visible on the site - the design part is totally neglected. I will be changing that over time.
For now, I have added a few graphic elements - small images - to give some life to the pages. There is an animated icon on the front page that turns attention to the updates feed/site. The navigation menu on the Finance site looks decent now.
A little play with CSS and a some graphics and everything looks quite different.

Facebook Development

I added a few apps - games - as Facebook applications yesterday.
http://apps.facebook.com/eurochampion/
http://apps.facebook.com/billiards/
http://apps.facebook.com/alensblackjack/
http://apps.facebook.com/alenssniper/
http://apps.facebook.com/shooting/
http://apps.facebook.com/alensroulette/
http://apps.facebook.com/pokerdaisy/
http://apps.facebook.com/alenspacman/
http://apps.facebook.com/alensmspacman/
http://apps.facebook.com/alensfrogger/
http://apps.facebook.com/alensdarts/

There are more to come. I got tired of adding them to Facebook. Now I need to figure out how to make them available to other people. Here is a site (Facebook Developer) that has some interesting texts about Facebook development.
One of the first tutorials I saw was exactly the thing I'm looking for - Allow Your Users to Invite Their Friends.
I must admit I still haven't figured out how Facebook applications work. I assume the app (my app on my web server) has to be active i.e. use some kind of Facebook library to communicate with Facebook site and do all the work on its own.
The thing that keeps confusing me is the FBML and data access. I had an impression the pages execute on Facebook but that would probably be an overkill for the server. Hmmm... That makes sense. Well, this means I should focus on creating apps either in .Net or Python. Looking forward to play with it next time I have some free time.

Saturday, June 28, 2008

Online Games

Online games

I added a page with some interesting online games. These are useful if you have some time to spare. I guess I'll be needing them when I'm at the airport with 10 hours to kill until the next flight.
Enjoy.

Thursday, June 26, 2008

online file storage

Still looking for the best place to keep the scanned ebook online, available to everyone. MyDrive upload, after spending a couple of hours uploading, proved to be worthless as the file was rejected AFTER the upload. The allowed file size is 50MB.
Now I am uploading to myOtherDrive. The file size is enough to store 140MB book and the link is directly to the uploaded file, instead of the page with commercials or other extra stuff that I don't need.
The upload is very slow and it will take another hour or so before I know if everything is alright.

Wednesday, June 25, 2008

Okano's dead, baby. Looking for online storage.

The server that hosted my original web site for years has probably exhaled the last breath of life. The server was down for a few days and, when the host name reappeared, it was not set up the same way. This means I probably lost the files there. The server was still used to host certain files linked from my web sites. Since storage for web sites is limited and just enough for web pages and design images, I had to use some other online source to host some larger files, like the scanned book about Bosnia.
Now, to use some suspicious services that change their Terms and Conditions every month would be a pain. I need a reliable online provider that will not cut my files for no reason and will be there for long enough. Microsoft's SkyDrive seems like a reasonable candidate for this role. I will upload the book and re-link the web site tonight and see how it goes.
This will be an opportunity to finally move all the web pages that were still hosted at Djesi.ba to googlepages site. Will need to spend some time relinking the page and removing the subfolders but hopefully that will be the last I have to do to get the site back in order.

Sunday, June 22, 2008

Albums

Just finished an application that uploads photos to Flickr and creates a link to the photo page with thumbnail. The process of photo upload and album generation should now be extremely simple.
The albums are created from a page template and all that is left is to write the album title and paste the links from the desktop app after photo is uploaded.
Now I need to start bringing the camera with me again when I go through the Melbourne area. There is always something interesting to capture in photographs.
It's a sunny day, I should make a few photos of botanical gardens...