<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://bugs.maemo.com/skins/common/feed.css?207"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://bugs.maemo.com/index.php?action=history&amp;feed=atom&amp;title=Python%2FHarmattan%2FPython_2.6_porting_tips</id>
		<title>Python/Harmattan/Python 2.6 porting tips - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://bugs.maemo.com/index.php?action=history&amp;feed=atom&amp;title=Python%2FHarmattan%2FPython_2.6_porting_tips"/>
		<link rel="alternate" type="text/html" href="http://bugs.maemo.com/index.php?title=Python/Harmattan/Python_2.6_porting_tips&amp;action=history"/>
		<updated>2026-04-06T10:33:57Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.15.5-7</generator>

	<entry>
		<id>http://bugs.maemo.com/index.php?title=Python/Harmattan/Python_2.6_porting_tips&amp;diff=45838&amp;oldid=prev</id>
		<title>wmoreira:&amp;#32;Python 2.6 porting tips moved to Python/Harmattan/Python 2.6 porting tips</title>
		<link rel="alternate" type="text/html" href="http://bugs.maemo.com/index.php?title=Python/Harmattan/Python_2.6_porting_tips&amp;diff=45838&amp;oldid=prev"/>
				<updated>2011-11-24T17:51:55Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;a href=&quot;/Python_2.6_porting_tips&quot; class=&quot;mw-redirect&quot; title=&quot;Python 2.6 porting tips&quot;&gt;Python 2.6 porting tips&lt;/a&gt; moved to &lt;a href=&quot;/Python/Harmattan/Python_2.6_porting_tips&quot; title=&quot;Python/Harmattan/Python 2.6 porting tips&quot;&gt;Python/Harmattan/Python 2.6 porting tips&lt;/a&gt;&lt;/p&gt;

		&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
		&lt;col class='diff-marker' /&gt;
		&lt;col class='diff-content' /&gt;
		&lt;col class='diff-marker' /&gt;
		&lt;col class='diff-content' /&gt;
		&lt;tr valign='top'&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;← Older revision&lt;/td&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 17:51, 24 November 2011&lt;/td&gt;
		&lt;/tr&gt;
		&lt;!-- diff generator: internal 2026-04-06 10:33:57 --&gt;
&lt;/table&gt;</summary>
		<author><name>wmoreira</name></author>	</entry>

	<entry>
		<id>http://bugs.maemo.com/index.php?title=Python/Harmattan/Python_2.6_porting_tips&amp;diff=45814&amp;oldid=prev</id>
		<title>wmoreira:&amp;#32;New page: == Introduction ==  Porting a package to support Python 2.6 usually involves making it version agnostic, removing any explicit Python versioning. In Maemo versions prior to Maemo 5, the pa...</title>
		<link rel="alternate" type="text/html" href="http://bugs.maemo.com/index.php?title=Python/Harmattan/Python_2.6_porting_tips&amp;diff=45814&amp;oldid=prev"/>
				<updated>2011-11-22T18:30:34Z</updated>
		
		<summary type="html">&lt;p&gt;New page: == Introduction ==  Porting a package to support Python 2.6 usually involves making it version agnostic, removing any explicit Python versioning. In Maemo versions prior to Maemo 5, the pa...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Porting a package to support Python 2.6 usually involves making it version agnostic, removing any explicit Python versioning. In Maemo versions prior to Maemo 5, the packages had hardcoded support for Python 2.5, which can be demonstrated by all Python binding packages having &amp;quot;python2.5-&amp;quot; as prefix and consequently Python applications having these names also on their runtime dependencies. As Maemo 5 also used Python 2.5, these packages still worked without much problems, but as MeeGo 1.2 Harmattan uses Python 2.6 they will have to be ported.&lt;br /&gt;
&lt;br /&gt;
== Python 2.6 porting tips ==&lt;br /&gt;
&lt;br /&gt;
* First of all, consider using [[Documentation_for_pyside-assistant|pyside-assistant]] for taking care of the packaging of your application, instead of packaging it by hand. This way you can avoid dealing with various issues regarding Debian packaging and focus mostly in the application itself.&lt;br /&gt;
* Any paths that, for some reason, have hardcoded &amp;quot;python2.5&amp;quot; or &amp;quot;site-packages&amp;quot; will have to be changed to &amp;quot;python2.6&amp;quot; and &amp;quot;dist-packages&amp;quot;, as these are the ones used on Python 2.6.&lt;br /&gt;
* If your application uses any &amp;lt;code&amp;gt;python2.5&amp;lt;/code&amp;gt; prefixed package as one of its dependencies in any Depends field, you should drop the version number and add the version as a requirement - for example, &amp;lt;code&amp;gt;python2.5&amp;lt;/code&amp;gt; can be changed to &amp;lt;code&amp;gt;python (&amp;gt;= 2.5)&amp;lt;/code&amp;gt; without problems. If this is not possible or not desired, just change the dependencies to their &amp;lt;code&amp;gt;python2.6&amp;lt;/code&amp;gt; counterparts.&lt;br /&gt;
* Also, this would be a good time for your package to be named following the new [http://www.debian.org/doc/packaging-manuals/python-policy Debian Python Policy] - the Policy states that Python packages must not have a fixed version number on its name (e.g. prefer python-foo instead of python2.6-foo).&lt;br /&gt;
* One very particular case where changes are required is when some Python script uses identifiers that became reserved keywords in Python 2.6. As an example, old versions of python-xml had this issue, where the &amp;lt;code&amp;gt;as&amp;lt;/code&amp;gt; identifier (which became a reserved keyword in Python 2.6) was being used as variable name in some places. If these occurrences are not replaced, running the script will result in syntax errors.&lt;/div&gt;</summary>
		<author><name>wmoreira</name></author>	</entry>

	</feed>