IBM / ibmi-oss-issues

Important resources for anyone interested in open source on IBM i
Creative Commons Zero v1.0 Universal
13 stars 0 forks source link

ModuleNotFoundError: No module named 'pandas' in IBM I (AS400) #12

Closed kapiltiwarimca closed 2 years ago

kapiltiwarimca commented 2 years ago

Pandas is intalled but when i run the script , it ModuleNotFoundError: No module named 'pandas'.

I have installed everything by IBM i client access solution open source package option.

i have already set path in qp2term

PATH=/QOpenSys/pkgs/bin:$PATH export PATH

Please advise

kadler commented 2 years ago

How are you running the script?

kapiltiwarimca commented 2 years ago

Hi kevin,

I am calling from Cl

PYONI/PYRUN2 + SCRIPTDIR('/home/kapilt/Production_Source') + SCRIPTFILE('RNW0001.py') PYVERSION(3) + PYPATH('/QOpenSys/pkgs/bin/') CCSID(37) + DSPSTDOUT(YES) LOGSTDOUT(NO) + PRTSTDOUT(NO) DLTSTDOUT(YES)

But it is also not working from QP2TERM .

On Fri, Mar 11, 2022 at 1:55 AM Kevin Adler @.***> wrote:

How are you running the script?

— Reply to this email directly, view it on GitHub https://github.com/IBM/ibmi-oss-issues/issues/12#issuecomment-1064472107, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADJ6WV3HTK6D67PIESVUBE3U7JLFDANCNFSM5QHD2U7Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

kapiltiwarimca commented 2 years ago

Hi Kevin,

I am in a different timezone.

what time i should be online so that i can check and answer your questions quickly .

Thanks,

Kapil

On Sun, Mar 13, 2022 at 5:49 PM kapil tiwari @.***> wrote:

Hi kevin,

I am calling from Cl

PYONI/PYRUN2 + SCRIPTDIR('/home/kapilt/Production_Source') + SCRIPTFILE('RNW0001.py') PYVERSION(3) + PYPATH('/QOpenSys/pkgs/bin/') CCSID(37) + DSPSTDOUT(YES) LOGSTDOUT(NO) + PRTSTDOUT(NO) DLTSTDOUT(YES)

But it is also not working from QP2TERM .

On Fri, Mar 11, 2022 at 1:55 AM Kevin Adler @.***> wrote:

How are you running the script?

— Reply to this email directly, view it on GitHub https://github.com/IBM/ibmi-oss-issues/issues/12#issuecomment-1064472107, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADJ6WV3HTK6D67PIESVUBE3U7JLFDANCNFSM5QHD2U7Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

ThePrez commented 2 years ago

This is likely a scenario where you have pandas installed for a different version of Python than you are running. First off, when running outside of PYRUN2, it's good practice to explicitly qualify which Python version you would like to run, as documented at https://ibmi-oss-docs.readthedocs.io/en/latest/python/README.html

PYRUN2, as documented here, is rolled into the larger QSHONI project. PYRUN2 does not support Python3.9 explicitly.

The recommendation is to either:

kapiltiwarimca commented 2 years ago
  1. yes , there are multiple version of python i can see in my system.

  2. there is only 2 and 3 version option in command. it is not accepting other than 2 and 3 value .

    • Switch to QSHPYRUN and specify the PYVERSION(3.9) option

2.before calling from Cl, Script should run from QP2TERM too , but it is not running from there .

[image: image.png]

On Mon, Mar 14, 2022 at 7:18 AM Jesse Gorzinski @.***> wrote:

This is likely a scenario where you have pandas installed for a different version of Python than you are running. First off, when running outside of PYRUN2, it's good practice to explicitly qualify which Python version you would like to run, as documented at https://ibmi-oss-docs.readthedocs.io/en/latest/python/README.html

PYRUN2, as documented here https://github.com/richardschoen/PythonOniLibrary, is rolled into the larger QSHONI project https://github.com/richardschoen/QShOni. PYRUN2 does not support Python3.9 explicitly.

The recommendation is to either:

  • Switch to QSHPYRUN and specify the PYVERSION(3.9) option
  • Use a different technique for starting your script (for instance, QP2TERM, QSH, Service Commander, or your own wrapper commands)

— Reply to this email directly, view it on GitHub https://github.com/IBM/ibmi-oss-issues/issues/12#issuecomment-1066255934, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADJ6WV3EMIKI4XMQDMBGQB3U72SJRANCNFSM5QHD2U7Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

ThePrez commented 2 years ago

The QSHPYRUN documentation says that PYVERSION(3.9) is allowed. If it's not allowing 3.9 as a value, I would recommend opening an issue against that project, which I see you've already done https://github.com/richardschoen/QshOni/issues/9 Looks like an upgrade will give you what you need.

kadler commented 2 years ago

Closing, since this seems like a third-party issue. Feel free to re-open if you are still having issues after resolving the QshOni issue.