Re: Postgresql & Python 2

Поиск
Список
Период
Сортировка
От teg@redhat.com (Trond Eivind Glomsrød)
Тема Re: Postgresql & Python 2
Дата
Msg-id xuyvgkwlta4.fsf@halden.devel.redhat.com
обсуждение исходный текст
Ответ на Re: Postgresql & Python 2  (Keith F Irwin <kirwin14@home.com>)
Ответы Re: Postgresql & Python 2  (Keith F Irwin <kirwin14@home.com>)
Список pgsql-general
Keith F Irwin <kirwin14@home.com> writes:

> > > Let's suppose I want to delete python1.5.  If a reinstall the
> > > posgres-python rpm, it'll put 'em back in /usr/lib/python1.5.  How do I
> > > get them into the python2 directory?
>
> > Don't move them - python 1.5 and python 2 aren't binary compatible.
>
> > What you can do, is to hardcode the pyver variable on top of the file.
>
> Trond--
>
> I hate to be ignorant, but what do you mean?  You're talking about the
> fact that they _pgmodule.so is incompatible?


Yes.

> What does it mean to hardcode the pyver variable on top of the file?

Look at the specfile, and you'll see the an attempt to autodetect the
version of python installed. You can hardcode the result...

> If I've got a database.py file with database classes, and I include
> this file in main.py, which instantiates its objects and calls its
> methods, how to I run main.py with Python2, and Database.py with
> Python1.5?

You can't.
>

--
Trond Eivind Glomsrød
Red Hat, Inc.

В списке pgsql-general по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: Postgresql & Python 2
Следующее
От: Thomas Lockhart
Дата:
Сообщение: Re: Re: [DOCS] QUERY - Including the new LDP PostgreSQL HOWTO in the main PostgreSQL distribution