Quiet Lately

September 16th, 2011

Hey Everyone, or anyone that’s still around sorry it’s been so quiet around here lately, I’ve just had so much on my plate. Moving, baby, wife, work, a new homebrewing passion, reading, writing, and so on. All of this has led to very little time spent on this blog.

I have some things in mind for this blog, but I never seem to get around to writing the posts or doing the work. Hopefully I’ll be able to get back into it soon.

At work we’ve delved into the Android platform and created an online app builder called andromo, which means I’ve been writing a lot of Java and hanging out on smart phones and tablets. If you are interested you can see some of the apps that have been built and added to the Android Market in our showcase.

You can keep up with what I’m doing on twitter: @MarkAtAndromo or add me to a circle on google+ under Mark Mruss and yes I follow Guido. If you are not on Google plus and need an invite let me know in the comments.

Oh and I also write on the Andromo blog from time to time as well.

Posted in News | 2 Comments »


New Belorussian/Belarusian Translation

April 21st, 2011

Hey everyone, just a quick note to let you know that Bohdan has translated the Creating a GUI using PyGTK and Glade tutorial in to Belorussian/Belarusian. You can view the translation here: Belorussian translation.

Many thanks to Bohdan and all the other who have translated some of these tutorials over the years.

Posted in python, Translation | 2 Comments »


Using Future Statements to Prepare for the Future

September 22nd, 2010

Note: This article was first published the June 2008 issue of Python Magazine

Mark Mruss

With the release of Python 3.0 only a few months away many Python programmers have visions of compatibility problems dancing in their heads. This article will introduce the concept of future statements including two future statements that you can use to help prepare your code for version 3.0.

Introduction

Python 3.0 (or Python 3000 as many people know it) is something that many Python programmers have started thinking about. Besides being the next major version of our beloved programming language, version 3.0 of Python will break backwards compatibility with the current 2.0 branch of Python. This means that a some of the code that you are writing right now in Python 2.X won’t immediately work in Python 3.0. Since Python 3.0 has a scheduled release date of September 2008 [1] now may be a good time to start thinking about future migration.

Of course there’s no reason to be alarmed yet. Guido, himself, has said that there is no rush to switch over to Python 3.0. [2] According to his PyCon 2008 essay “Python 3000 and You” you should switch when the following are true: “1. You’re ready 2. All your dependencies have been ported.” [3]

In the same essay Guido also says that Python programmers should be prepared and that they should “start writing future-proof” code for 2.5″ [4] In this sprit, this article will introduce “future statements” and two ways that you can use them now in order to make the migration process from the Python 2.0 branch to the Python 3.0 branch as smooth as possible.

The rest of this article, and the examples within, will assume that you are working with Python 2.5.
Read the rest of this entry »

Posted in python, Python Magazine | 3 Comments »

Python Version Poll Results

August 13th, 2010

The results are in for the first annual LearningPython.com Python version quiz:

Which version of Python do you use?

  • 2.6 (65%, 700 Votes)
  • 3.1 (17%, 187 Votes)
  • 2.5 (17%, 182 Votes)
  • 2.7 (4%, 48 Votes)
  • 2.4 (3%, 32 Votes)
  • 3.0 (2%, 20 Votes)
  • 2.3 (0%, 5 Votes)
  • 2.1 (0%, 3 Votes)
  • 1.5 (0%, 2 Votes)
  • 2.2 (0%, 1 Votes)
  • 2.0 (0%, 1 Votes)
  • 1.6 (0%, 1 Votes)

Total Voters: 1,084

spacer  Loading ...

By a landslide version 2.6 is the winner, with 3.1 and 2.5 following far behind. A grand total of 1084 people voted and 700 of those still use Python 2.6, 187 use 3.1 and 182 use 2.5. While not the largest sampling of users the wide margin of victory probably means that most Python programmers are still targeting 2.6, or at the very least the newest version of the 2.x branch. Now what is installed on our end user’s system…that’s another matter all together.

Thanks again to everyone that voted. I’m happy that I was able to attract 1000+ people to vote in this poll. My next idea for a poll is an IDE poll, partially because I’m curious as to what people are using, and partially because there is a good chance that I may have overlooked other programs on my way to selecting Geany.

Note: Python 2.7 was released (July 3rd, 2010) after the poll was created (Mach 4, 2010) this means that the value for 2.7 is probably larger now and 2.6 is probably slightly smaller.

Posted in python | 2 Comments »

Hacking Fixed, and Python on the Web

August 12th, 2010

Hey Everyone, just an update on the last post. I was able to dig through the wordpress files and find where the hack was and it appears to be fixed now.

Again if you notice anything strange happening here, redirects to external sites and whatnot, please let me know.

Also, does anyone here use any of the python web frameworks? I’d like to try my hand at them, but I’m having difficulty deciding between Pylons, Django, and Zope. I’m a total n00b when it comes to web programming, so it’s something that I’d like to be better at, so one of my requirements is being easy for beginners to learn.

If anyone has any thoughts or advice please post a comment.

Posted in Uncategorized | 21 Comments »

Possibly Hacked 2.0

August 3rd, 2010

Just to let everyone who still reads this blog that it looks as though I have been hacked again.

Please don’t believe the rumours, I am not selling, nor will I ever, levitra online.

If you notice anything strange in the text on this blog, or you end up redirected to some strange site, please let me know.

Posted in News | No Comments »

Introducing Descriptors and Properties

April 25th, 2010

Note: This article was first published the May 2008 issue of Python Magazine

Introducing Descriptors and Properties

Mark Mruss

New-style classes were introduced to Python with the release of Python 2.2. And with these new-style classes came descriptors and properties. This article will introduce the descriptor protocol, descriptors, and properties.

Introduction

New-style classes were introduced to Python with the release of Python 2.2. A new-style class is any class that is derived from the object base class. New-style classes give Python programmers many new (and initially confusing) features. One such feature is the descriptor protocol, and more specifically descriptors themselves.

Descriptors give Python programmers the ability to easily and efficiently create “managed attributes”. Managed attributes can be thought of as attributes that are not accessed directly. Instead their access is “managed” by something else, generally a class or a function.

If you haven’t come across this before you are probably wondering why one would want to manage attribute access? One reason might be that you don’t want people to be able to delete the attribute. Another reason may be that you need to ensure that your attribute data is always valid. Or perhaps attribute x is based on attribute y, so every time the value of y changes you want to update the value of x. From these few examples you can see the many possible cases where you might want to control access to certain attributes.

For those of you familiar with other programming languages, this type of access is often referred to as “getters and setters”. In many language, implementing “getters and setters” means using private variables and public functions that get and set the variable’s value. Since Python doesn’t (really) have private variables, the descriptor protocol is basically a built-in and Python-ic way to way to achieve something similar.

This article will introduce you to the descriptor protocol, descriptors, and properties. It will focus on demonstrating how to use them to create managed attributes. Since the descriptor protocol requires new-style classes, all of the examples in this article require Python 2.2 or newer.

Read the rest of this entry »

Posted in python, Python Magazine | No Comments »

Forums Forums Forums

April 8th, 2010

I just wanted to re-point out the fact that there are some forums associated with this blog. There’s not much happening there, and recently they have become a haven for spammers, but I’m trying to clean them up and if other Python programmers read this blog maybe the forums could actually become useful!

Either way for those that didn’t know, there are learning python forums available.

Posted in python | No Comments »

AVC: Simplifying your GUI Code

March 14th, 2010

Note: This article was first published the April 2008 issue of Python Magazine

By: Mark Mruss

GUI programming, like many other types of programming, can sometimes prove exhausting because you must repeat yourself over and over again. AVC is one tool available to Python GUI programmers that attempts to simplify things by synchronizing application data and GUI widgets.

Introduction

Every once in a while I find myself browsing the Internet trying to find out what’s new and exciting in the Python world. Sometimes I browse to find topics for this article; other times mere curiosity draws me across the web. While I was browsing the other day, I stumbled across AVC: the Application View Controller [1]. I was immediately intrigued by it because its’ name is so similar to the Model View Controller (MVC) pattern. Being familiar with the Model View Controller pattern, and admittedly having struggles with it in the past, I decided to check out AVC to determine if it might be a viable alternative.

After reading about AVC I was intrigued for several reasons. The main reason was the promise of “a multiplatform, fully automatic, live connection among graphical interface widgets and application variables.” [2] This means that graphical widgets can be connected to variables and automatically synchronized. One of the (many?) problems with Graphical User Interface (GUI) programming is that you often find yourself doing the same thing over and over again. One of the things that you end of doing over and over again is setting the contents of a widget based on the value of a variable, and then subsequently, setting that variable’s value based on the current state of the widget. Whenever someone promises me an automatic connection between GUI widgets and my variables, I’m interested.

Read the rest of this entry »

Posted in Uncategorized | 2 Comments »

Poll: Python Version

March 4th, 2010

Edit: Due to popular demand (well a couple of comments) I’ve decided to allow multiple answers to the poll. This should make everyone that uses two versions happy.

With two major versions of Python available to us Python programmers (2.X and 3.X) I thought it would be interesting to see which version the readers of this blog are using and targeting.

Personally I’m still using 2.5 on my Debian box because it’s the default, and 2.6 on my Windows PC. While I have used 3.X and have it installed, I’ve remained on the 2.X branch largely because many of the modules that I play around with are still focused on the 2.X branch so that’s where my focus has remained.

I voted 2.5 since I do that majority of my programing on my Debian box. So now what about you:

Which version of Python do you use?

  • 2.6 (65%, 700 Votes)
  • 3.1 (17%, 187 Votes)
  • 2.5 (17%, 182 Votes)
  • 2.7 (4%, 48 Votes)
  • 2.4 (3%, 32 Votes)
  • 3.0 (2%, 20 Votes)
  • 2.3 (0%, 5 Votes)
  • 2.1 (0%, 3 Votes)
  • 1.5 (0%, 2 Votes)
  • 2.2 (0%, 1 Votes)
  • 2.0 (0%, 1 Votes)
  • 1.6 (0%, 1 Votes)

Total Voters: 1,084

spacer  Loading ...

If you want to explain your choice leave a comment below.

Posted in Poll, python | 15 Comments »

« Previous Entries
Related searches:
python version article posted future
gipoco.com is neither affiliated with the authors of this page nor responsible for its contents. This is a safe-cache copy of the original web site.