[OpenSIPS-Users] Can't seem to get python module to work
Gordon Yeong
anexiole at gmail.com
Wed May 13 02:16:33 EST 2020
Anyone know what's going on?
Gordon
On Tue, 12 May 2020 at 17:10, Gordon Yeong <anexiole at gmail.com> wrote:
> hi guys
> I managed to get opensips to work with the perl module.
> I now need to port what I have to python 3.
>
>
> I can't seem to start opensips 3.0 because I have the following error:
>
>
> May 12 16:59:51 [47532] ERROR:core:set_mod_param_regex: no module matching
> python found
> May 12 16:59:51 [47532] Traceback (last included file at the bottom):
> May 12 16:59:51 [47532] 0.
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg
> May 12 16:59:51 [47532] CRITICAL:core:yyerror: parse error in
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg:137:20-21: Parameter
> <script_name> not found in module <python> - can't set
> May 12 16:59:51 [47532]
> May 12 16:59:51 [47532] loadmodule "enum.so"
> May 12 16:59:51 [47532] modparam("python", "script_name", "/tmp/test.py")
> May 12 16:59:51 [47532] ^~
> May 12 16:59:51 [47532]
> May 12 16:59:51 [47532] ####### Routing Logic ########
> May 12 16:59:51 [47532] CRITICAL:core:yyerror: parse error in
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg:158:36-37: unknown
> command <python_exec>, missing loadmodule?
> May 12 16:59:51 [47532] CRITICAL:core:yyerror: parse error in
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg:159:54-55: unknown
> command <python_exec>, missing loadmodule?
> May 12 16:59:51 [47532] ERROR:core:parse_opensips_cfg: bad config file (3
> errors)
> May 12 16:59:51 [47532] ERROR:core:main: failed to parse config file
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg
> May 12 16:59:51 [47532] NOTICE:core:main: Exiting....
>
> 1) the first issue is "ERROR:core:set_mod_param_regex: no module matching
> python found".
> I find this really weird because I referred to
> https://opensips.org/docs/modules/3.0.x/python.html and it says in 1.2.1.
> that no loading is required.
>
> 2) Additionally, I am using the line "modparam("python", "script_name",
> "/tmp/test.py")" to load my test python functions as per the same
> documentation in section 1.3.1.
> Yet, it errors out, "CRITICAL:core:yyerror: parse error in
> /opt/opensips/etc/opensips/opensips-Enum-Python.cfg:137:20-21: Parameter
> <script_name> not found in module <python> - can't set".
>
> Any ideas?
>
> Thank you
>
>
> Regards,
> Gordon Yeong
> perl, python3, elixir, rails, php = joy
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200513/e90c5a16/attachment.html>
More information about the Users
mailing list