Forum Archive

How to import StaSh pip installed module?

jeremyzh

To be more specific, I pip installed panda through StaSh and it shows:

Dependency available in Pythonista bundle: requests

Then I tried to

from panda import panda as pd

Python can not compile showing "No module named 'request'". Shouldn't it be showing "panda"? Why "request"?
Thank you for your time

JonB

Looks like this is a python2.7 module (relative module imports are handled a bit differently). Switch to the py2.7 interpreter (upper right corner of console for console work, or long press play if you are importing in a script)

Though, I can't help but wonder if panda is what you think it is... a depreciated api for the now-named telestream video encoding api?

Or did you mean to install pandas?
(if so, those playing the pythonista pandas request drinking game should now take a sip)

Unfortunately the forum search is really bad, but google works well: https://www.google.com/search?q=pythonista+install+pandas+site:forum.omz-software.com

JonB

spoiler alert: pandas is data analysis, but is not supported on pythonista.

jeremyzh

Oh my god! I am so dumb.....it's pandas not panda........Thank you for your reply. I will just go to the corner there and hit my head

jeremyzh

@JonB yeah, I just realized it is not supported on pythonista. Thank you for your reply