#ONTAP REST API Python client library error

1 messages · Page 1 of 1 (latest)

barren cape
#

Hello Team, this is Jose Del valle from CORE technical support.

Customer in case 2009851130 has been guided to transition from NetApp API to REST API and today have replied with the following error:

When I run the command “python.exe session_stats.py DC2750” I get the error message;

Traceback (most recent call last):
File "session_stats.py", line 21, in <module>
from netapp_ontap import config, utils
ModuleNotFoundError: No module named 'netapp_ontap'

Note: DC2750 is the clustes's name.

What could be the issue here?

grave plover
#

This error is a python client installation and configuration 'misunderstanding'.
As this looks like a Windows client, in a Powershell session, run python.exe to open a python 'terminal', aka interactive session, and try the erring line:

from netapp_ontap import config, utils
#

If that fails, the user needs to install the module, or add that module path to python's environment, or any of many other possible configuration changes to make it work.
To summarize, this is not a NetApp-specific issue.

barren cape
#

Hi James, thanks for clarifying this, I'll update the customer about.

grave plover
#

Direct the customer to this Discord server for further assistance. There's also a general Python Discord server, that I am also in, that the user can ask questions in. That can be found by searching the internet. We're not allowed to post the invite link on this server.

torpid crystal
#

I gotchu, @grave plover