Is that a Python 2.7 package?
You should add the redis package to the "Additional Python modules path"
rather than a script that calls it (if I'm understanding correctly).
Best regards.
On 13/03/2023 11:34, Karthik k wrote:
> Python packages installation in OWASP ZAP Jython environment.
>
> My requirement is to send alerts(alertID, ReqHeader, Responseheader etc...
> as json object) to redis store for which I'm using a python zap extender
> script.
> Everything is working fine except for the sending to redis part
>
> I'm not able to import redis module inside extender script.
>
> I have tried the following
>
> 1) Installing redis python module using pip in my python installation
> assuming owasp zap jython will pick it up as well.
>
> 2) Wrote a seperate py file which implements the redis functionality
> required and mentioned it in a folder and pointed it to
> options-->Jython-->Additional Python modules path, and tried to import that
>
> In both the above cases I got the following error.
>
> Traceback (most recent call last):
> File "aaa.py", line 7, in <module>
> ImportError: No module named redis
> Traceback (most recent call last):
> File "aaa.py", line 7, in <module>
> ImportError: No module named redis
>
> *Note: Normally in python environment I'm able to import redis.*