we no longer use global name space in our shared objects which seems to have
a side effect on modules who in turn try to load it's own shared objects
because they too inherit the non-global namespace param.

you can either add an attribute to the modues.conf to ask it to load with
global name space

<load module="mod_foo" global="true"/>

or you can edit the code to request global loading every time.

by adding the param SMODF_GLOBAL_SYMBOLS to the SWITCH_MODULE_DEFINITION
macro
(See mod_cepstral at the top)


On Mon, Dec 1, 2008 at 2:31 AM, Traun Leyden <[EMAIL PROTECTED]> wrote:

>
>
>> Message: 9
>> Date: Sun, 30 Nov 2008 18:42:30 -0800 (PST)
>> From: Marc Orenberg <[EMAIL PROTECTED]>
>> Subject: [Freeswitch-users] Problem importing modules in mod_python
>> To: [email protected]
>> Message-ID: <[EMAIL PROTECTED]>
>> Content-Type: text/plain; charset="iso-8859-1"
>>
>> In the latter versions of mod_python, I'm unable to import standard python
>> modules such as time and MySQLdb.?
>> For example, the following script works fine in version 1.0.1:
>>
>> ??? ??? import time
>> ??? ??? import os
>> ??? ??? from freeswitch import *
>> ??? ??? def handler(session, args):
>> ??? ??? ??? session.answer()
>> ??? ??? ??? session.execute("sleep", "2000")
>> ??? ??? ???
>> session.streamFile("/usr/local/freeswitch/prompts/01Welcome.wav")
>> ??? ??? ??? return(session)
>>
>> But in freeswitch-1.0.latest.tar.gz, and svn versions 10556-10558, I get
>> the following error:
>>
>> ??? ??? 2008-11-30 21:13:09 [ERR] mod_python.c:129 eval_some_python()
>> Error reloading module
>> ??? ??? Traceback (most recent call last):
>> ??????? File "/usr/lib/python2.4/site-packages/scripts/test.py", line 1,
>> in ?
>> ??? ??? import time
>> ??? ??? ImportError: /usr/lib/python2.4/lib-dynload/timemodule.so:
>> undefined symbol: PyExc_ValueError
>>
>> Thanks for your help!
>>
>
> I have run into the same problem and put some documentation on the wiki:
>
>
> http://wiki.freeswitch.org/wiki/Mod_python#ImportError:_.2F...2Fdatetime.so:_undefined_symbol:_PyExc_IOError
>
> I think something changed in freeswitch in the way it is loading modules,
> or at least the way it is loading mod_python.  This behavior appeared all of
> the sudden in recent freeswitch versions.
>
> HTH
>
>
> _______________________________________________
> Freeswitch-users mailing list
> [email protected]
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>


-- 
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/

AIM: anthm
MSN:[EMAIL PROTECTED] <[EMAIL PROTECTED]>
GTALK/JABBER/PAYPAL:[EMAIL PROTECTED]<[EMAIL PROTECTED]>
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:[EMAIL PROTECTED] <[EMAIL PROTECTED]>
iax:[EMAIL PROTECTED]/888
googletalk:[EMAIL PROTECTED]<[EMAIL PROTECTED]>
pstn:213-799-1400
_______________________________________________
Freeswitch-users mailing list
[email protected]
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org

Reply via email to