From Hackerspace Brussels
Jump to: navigation, search

Tue 10 Jul 2012 19:30
till Tue 10 Jul 2012 23:00
Python for Web applications workshop
This workshop targets beginner users ( no Python or OOP knowledge required ). At the end of the workshop,

participants should be able to create a small website with an SQL database as storage.

HSB Brussels,Belgium
U go,

Duration: Two evenings during the week. Lesson One already happened.

Lesson 2 planned on July 10

Location: HackerSpace Brussels - Prinses Elisabethlaan 48 av. Princesse Elisabeth, 1030 Schaarbeek

What do I need[edit]

Here's what you'll need for lesson 1:

  • computer
  • recent Python installed

I will use branch 2 for the demo. There should be no problem using version 3 for the first lesson, but some frameworks and tools for Lesson 2 might not be compatible. Everything should work on major platforms (Linux, *BSD, OS X, Windows), and most stuff should work on exotic platforms (iOS, Android, Symbian S60).

Main topics[edit]

Lesson 1: Getting hands on[edit]

  • Python syntax and Object Oriented Programming (OOP)
  • Going roots: HTTP server using sockets
  • Intro to CGI
  • Using Python CGI
  • Basic storage and persistent data

Lesson 2: Using libs[edit]

  • Templating ( Jinja2 ? )
  • SQL Alchemy ( ORM )
  • CherryPy ( web framework )
  • Deployment options

Links & Docs[edit]

Simple Python CGI Server

What about Django, Flask, ?[edit]

Django has awesome features, but it uses several new concepts altogether ( MVC, ORM, regex routing, ...). This workshop will help understanding some of these concepts, one at a time. This will help participants to attend a workshop about Django.

I love the simplicity and the object orientation of CherryPy, which is why I arbitrary chose it over other options such as Flash,, ...

From First Episode[edit]

If you didn't attend episode one :

- Basics of Python programming will be required for episode 2.

- Main subjects were HTTP, sockets and CGI. Knowledge of these is not required for episode 2.

- Slides are available here :

- My files from episode one are available as attachment to this mail

- To start a Python CGI server : python -m CGIHTTPServer