In the last few days we managed to get Darkserver live in production. Thanks to Nirik and Dgilmore, without their help it was not possible.
This service is providing the API(s) based on which other developers can write tools to query details of build-ids. We Have build-id in every ELF we build from Fedora 8, but there was no good way to query them. More details on why we need the service can be found at the wiki page.
For now it is handling only primary architecture builds. Within last 4 days we have around 118k build-id(s) in the database.
I am working on a small command line client for the same, called darkclient. Hope to have the first release out in next week.
API details can be found at the home page of the service.
Why you need it ?
Say you are writing unittests for your favourite application and in some function you are using xmlrpclib module to interact with a web-application. Now for testing you can easily mock that interaction out, which will help to run your code in fast and easy way. Mocking database calls can be another example.
Example:
import unittest
import xmlrpclib
from mock import patch
class TestFoo(unittest.TestCase):
"""
A simple test
"""
@patch('xmlrpclib.Server')
def test_first(self, mock_xmlrpc):
m = mock_xmlrpc.return_value
m.multiply.return_value = 6
server = xmlrpclib.Server("http://kushaldas.in/")
res = server.multiply(2, 3)
self.assertEqual(res, 6)
if __name__ == '__main__':
unittest.main()
We reached Durgapur around 3:30AM on Friday, woke up by 6AM due to the really cold temperature. The inauguration event started few hours late and after that Mether started doing his RPM workshop.
My workshop started after 6:30PM , around 60+ students. Started with basics of python as a language. I did this workshop slowly so that everyone can pick the things we were discussing.
Next day morning my second session started from 10AM and in the afternoon I had my PyGtk workshop in the lab. After finishing talking for more than 6 hours did the final talk for the night with the first year students. Total time I spoke was more than 7 hours , which is a record for me :)
3rd day again started at 10AM and I was surprised to see more than 30 students in the seminar hall where I was doing the python workshops. We discussed in details various modules in python and also discussed about projects for the students.
Generally I don’t get many mails from the students after the workshops or even if they do mail , they don’t continue. But here I found 3 students still continuing. I hope at least one of them will be able his/her journey in the path of freedom.
Photos can be found here. Will update the post with flickr set when I upload there.
So I am back from PyCon India 2010. I missed last year, so was waiting for this year’s event. Met many faces after very long time and to be in a place with so many other python lovers is always a nice experience. The total attendance was around 700 but the venue was too big for that number , so except the lunch time, corridors had lesser number of people discussing. The selection of the talks were also matching the environment as they came from different directions. We saw talks with hardware accessibility to web development to GUI application toolkits, network programming, scientific computing, terminal based works etc.
Day 1 started a bit late, David Goodger gave the keynote, it was fun. Next talk I liked was from Dhananjay Nene on “Functional Programming with Python“, he managed to show many things within the short time.
I stood in the queue for lunch as soon as possible, it was late, too much crowd at the same time, but the taste of the food was delicious. During and after the lunch I was discussing with Jace about Wing IDE, I had a thought of buying that previously also but the price is high for me. Wait, not anymore, they gave a 90% discount for the PyCon India :) Started using it right away with vi mode and it works like a charm.
After lunch, thought of going in Mahendra M’s Twisted programming talk, but the room was full, no place for standing also. So hoped over to the auditorium for Vijay Kumar B.’s Device Interfacing with Python and ZIO , it was one of the best talk I ever attended.
Met DP and Jacob after long time :)
This was first time my laptop’s X crashed while trying to use the projector, so after few tries I started my talk with the black terminal on the big screen :) newt widgets looked great on that screen though :)
Day 2: I came a bit late as I had to meet few seniors from my college in the city (event was in a far corner of the city), I spent the day mostly in the corridors talking with people. I met so many Pune based python lovers there :) Strangely enough few speakers were absconding from the talks, so the organizers had to innovate to fill in.
At the very end we had first AGM of Indian Python Software Society, too much fun in that :p. I applied for membership, I still need two votes. I also resumed my work on “Python for you and me” 2nd edition. You can also read ml-IN or zh-CN translation of the book.
Any python lover from the country should attend this event, next year it will be in Chennai. Photos will come later this week.