﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
6576	lxml.etree.tostring crashes after importing django.contrib.gis.db.models	kanu@…	nobody	"I know that sounds strange, but under the following conditions my python shell ends with a '''bus-errer''':

 * !MacBookPro

 * Mac OSX 10.5 - Leopard

 * Python 2.5

 * psycopg2, lxml2.0

 * http://code.djangoproject.com/svn/django/branches/gis Revision 7104

'''/.../models.py'''
{{{
from django.contrib.gis.db import models
}}}

'''in the terminal'''
{{{
...$python manage.py shell
Python 2.5.1 (r251:54869, Apr 18 2007, 22:08:04) 
[GCC 4.0.1 (Apple Computer, Inc. build 5367)] on darwin
Type ""help"", ""copyright"", ""credits"" or ""license"" for more information.
(InteractiveConsole)
>>> from lxml import etree
>>> etree.tostring(etree.Element('TEST'))
Bus error
}}}

the only way to get this work is passing the unicode object as encoding keyword
{{{
>>> etree.tostring(etree.Element('TEST'),encoding=unicode)
}}}"		closed	GIS	dev		invalid	lxml		Unreviewed	0	0	0	0	0	0
