Skip to main content

Pycon Apac 2011

Pycon APAC 2011 in Singapore finally end this evening and this is some quick recaps on the event for the past few days.

Day 1 (Tutorial)
This is tutorial day only. The conference actually started on the second day. I took the Python 102 class. Initially I want to attend Practical Django project by Jacob Kaplan Moss but since my boss already took that class and we didn't want to attend the same class I picked Python 102. I thought this could be somewhat 'formal' Python class for me. Turn out it really meant for beginner. I don't know what they touched in 101 but it look to me just a repetition of what in 101 class. But I still manage to know few things that I'm not aware off. It some kind of basic but I never learn Python in formal, I just picked up the specific part of the language that can solve problem at my hand.
  • Use negative (-) sign to apply string formatting backward.
  • Use double, triple and so on colon in list slicing as step. Really nice feature.
  • Enumerate to keep index when looping through dictionaries.

Day 2
It started with a keynote by Jacob Kaplan Moss, the co-creator of Django Project. Jacob talk about writing documentation and try to promote on what he called "Documentation Culture". He layout the framework of what he think would be great and valuable documentation as:-
  • Tutorial - should be quick, easy but not too easy. Show off how the project feels.
  • Topic Guides - conceptual, comprehensive, tell the why.
  • Reference - complete, for experienced users, give the 'how' of the topic.
Some facts that he mentioned:-
  • Django is 66,000 lines of Python and 75,000 lines of English (documentation).
  • New Testament is 180,000 lines.
  • In Search of Lost Time - 1,500,000 lines.

Jacob reflected that one of the factor for Django success is it's documentation.

Traits: A Component Library for Python - Eric Jones
Allow you to add explicit type to the class attributes.
Automatically create property for method that has a pattern _.
Listener also has the same pattern - __.

Trait actually a class attribute with type enforce on it.

GUI apps in Python.
This actually also using Traits to generate the GUI. Later on (when I talk to the speaker) I understand that this is more to display a GUI for real time data, for example a data coming from electronic sensor that you need to dFont sizeisplay to users maybe in a way of graph and some signal. So this is not really a GUI for building the typical desktop applications. The speaker also mentioned about bbfreeze that I really want to check it out later.

Python Web Application Hosting - Graham Dumpleton
Graham just go through a list of available options to deploy your Python application. I asked question regarding running mod_wsgi daemon mode under as separate user from the main apache process and he recommend doing that especially when hosting the python app together with other apps such as PHP in the same apache process. So if somehow the PHP process being compromised, the Python app is not accessible by the attacker.

Introduction to Diazo - Izhar Firdaus
Our fellow Malaysian, I didn't actually know that he also would be giving a talk. Diazo actually Deliverance which changed it name to xdv and now known as Diazo. I did look at Deliverance before but so far doesn't has any particular use case for it yet,

The Development of an Open-Source Application Risiko using Python and Django for the Estimation of Impact from Natural Disasters.
Basically a web frontend (Django) that allow you to upload spatial data which then being passed to the geoserver at the backend. The inputs are:
  • Hazard map
  • exposure map
and then there's gi a plugin to calculate the impact. The impact is actually the function of hazard and exposure.

Insane Django Testing.

Day 3
I was late today but it turn out to be good. Met Jacob at Woodlands MRT station so I manage to chat a little bit about Django with him while walking to the conference venue. Specifically ask him about the direction that Django's taking with class based views in 1.3 onward given that Pylons project recently admitted that using inheritance seem to be the wrong approach to provide customization. Still need to digest what he was saying so maybe would write more about this later.

Second Keynote - How Python Became My Mother Tongue
Not really interesting, more about Python usage in scientific applications which is not really my domain. But I do learn something new about Sage.

Lost Word Processing Crutch.
This guy actually a teacher there at Polytechnic Republic, place where Pycon held. He need better way to write his document (especially question paper for his student). He wrote his own static html generator based on textile. One creative way he used is to provide solution at the end of of the question but encrypted. At the end of day or week, he would publish the password to solution so his student can view it. Pretty cool actually.

Aviation
Ok, a bit boring but at the end it still quite interesting. They build all the heavy and complex aviation solutions using all the familiar tools that I know - Django, rabbitmq, celery, piston etc.

PyLightPlug
I really want to attend this session after talking to the speaker the day before during lunch break. It somewhat related to one of the tasks that I have in hand right now that is to build an antispam mechanisme that easily extend-able. He gave a link to an article and I really need to read this - http://martyalchin.com/2008/jan/10/simple-plugin-framework/

TIL: Python "hooks" module.

Rapid development with Tornado and Mongodb - Ikai Lan
Nothing much interesting. Ikai did note that mongodb sometime would fail so be prepared for it.

Buildout - Izhar Firdaus
Another talk from Izhar Firdaus. Too bad that I forgot already all my gripes with buildout otherwise this would be a good chance to whack it out ;) Something that I learned:-
  • Locking package versions through [versions] part.
  • zc.cmmi - need to look into this, could be some way to run the standard configure, make, make install through buildout.
  • zest.releaser.

Comments

Popular posts from this blog

PHP with docker

A friend asking about a PHP library and I decided to test whether that library is working. But I don't have PHP environment setup (we're Python shop btw). But thanks to docker, that's easy these days. docker run -it --tty --rm --volume $PWD:/app --user $(id -u):$(id -g) composer require google/apiclient:^2.0 Then we just need to create the script to run, still in the same directory:- include_once __DIR__ . '/vendor/autoload.php'; $GCSE_API_KEY = "nqwkoigrhe893utnih_gibberish_q2ihrgu9qjnr"; $GCSE_SEARCH_ENGINE_ID = "937592689593725455:msi299dkne4de"; $client = new Google_Client(); $client->setApplicationName("My_App"); $client->setDeveloperKey($GCSE_API_KEY); $service = new Google_Service_Customsearch($client); $optParams = array("cx"=>self::GCSE_SEARCH_ENGINE_ID); $results = $service->cse->listCse("lol cats", $optParams); And we can run that script again using docker:- docker run -it --...

Ubuntu 22.04 Wayland share screen

 After switching to Dell XPS 13 which running Ubuntu 22.04, I noticed that trying to share screen through Google Meet, it shows this:-    This - Use operating system settings, I never saw it before. Usually here we will be presented the windows that we want to share.  It turned out that screen sharing in Ubuntu 22.04 indeed an issue, due to the use of Wayland instead of Xorg as its display server. Many suggested to disable wayland and back to use Xorg. I try to avoid that since Wayland seems to works fine so far. After some searching, the conclusion seems we can make this working by installing some packages. sudo apt install xdg-desktop-portal xdg-desktop-portal-gnome But it turned out that I have already installed the packages! So what were the problems?  Well, turn out it's more psychological than technical. Since the pop up is different than what I'm used to before, I never click the allow button. But clicking the allow button we will see this:-   Which...

The rise of localhost

I noticed a pattern in dex world, where you build client backend to participate in the network, and then build a web app that simply connect to  localhost:someport  for the UI. To check my scuttlebutt updates, I opened up http://localhost:8027/. For those using Ethereum Parity wallet, they can open it at http://localhost:8180/. ZeroNet users are browsing at http://localhost:43110/. But Parity for example, try to make it seamless, they still provide a dns - web3.site which then redirected to home.web3.site which simply resolved to 127.0.0.1. But this I think bring up some problem, especially non-tech user which think that Parity is a website hosted by Parity Technologies. I seen this in a some articles about the latest bug .