2012-07-05

At Europython I learned...

Today I learned something magical that has transformed all my twisted
program examples:

from __future__ import print_function

Whee! This means that you can quickly and easily do
d.addCallback(print) without any pain. You can even do
d.addCallback(print, 'somedata', 1, 'etc').

>>> d = defer.succeed(None)
>>> d.addCallback(print, 'somedata', 1, 'etc')
None somedata 1 etc


Huzzah!

16 comments:

Cory said...

Oh shit son, that is great. Thanks for the tip.

Anonymous said...

thanks a lot!!!!
great great
the end of my stupid function "printit"
it seem's that print "toto" still work also.
that's the best day of my life

wordpress plugins said...

Divine Developer specializes in personalized WordPress consulting services. Featured services include custom plugins and themes coding, PSD to WordPress services, migration to wordpress and upgrades.

kancelarijske stolice said...

ANAKS is a company specializing in the sale of office furniture and furnishing office space. Like the company name says (ANAKS is the ancient Greek word for the best, leading, ruler), we strive to provide our customers with the best service, the best selection and the best quality. Our product range includes furniture and chairs for your business well-known manufacturers.
http://www.anaks-namestaj.com/

rent a car beograd said...

Really loved reading your blog. Thanks for sharing this!

GoldyVPN said...

Once you unblock rai tv you will experience high speed so you can easily test your gaming skills. You will be able to use vpn for rai tv from anywhere in the world.
http://www.goldyvpn.com/vpn-for-rai-tv/

Willie Ames said...

i live in australia but i can watch rai tv using australian vpn.

James R. Douglas said...

wonderful post

Micheal E. Wilson said...

You are continuing your essay writing service. You need to more tips. Find more tips you can follow this site. http://tjmun.info/best-gadgets-for-assignment-writing

zubair hussain said...

Willie Ames thanks for sharing,
I am using VPN to access American Netflix in Australia.

Unknown said...

Professional and user- friendly services are available for assignment help melbourne. It is known for providing the students expert assistance related to almost every subject.

Unknown said...

I’m working as an academic consultant at Global Assignment Help Australia. I have been providing assignment help to Aussie scholars for more than 5 years. I hold exceptional writing skills and assist the scholars in assignment writing tasks.

John Noels said...

We, at Instant Assignment Help, offer the best Assignment writing service UK to the college students who wish to score top grades in their academic career. Our team of subject-oriented and highly qualified writers promises to deliver well-written and thoroughly researched assignments at affordable prices within the prescribed deadlines. If you want to receive an original document according to your university guidelines, then take our assignment writers help right away!

Adam Jackson said...

Adam Jackson has been associated with Assignment Prime for a long period now. He is popular among students for providing them with the best assignment help in australia. He takes a keen interest in writing for his academic blog as well. Over the time, he has received accolades and appraisals for his teaching techniques.

Evelyn Williams said...

Online Dissertation Writing is a UK-based academic writing service provider known for the competency of its dissertation writing team. Other than dissertation, we also provide writing assistance for essays, term papers, reports, research papers, theses, book reviews and other custom papers. We have diligent student support team that is available 24*7 hours for the convenience of our customers. We believe in providing only the high-quality content with consistency, so that we can achieve our 100% satisfaction objective.

Unknown said...

Assignment Desk provides online assignment help & writing services from professional UK writers at affordable prices. This helps the students to submit their assignments within deadlines and score the best grades in it.