# Import pandas - No module named 'pandas'

**URL:** <https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037>\
**Category:** PyScript\
**Created:** [May 26, 2022, 12:18pm UTC](https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037 "2022-05-26T12:18:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![alihht](https://dub1.discourse-cdn.com/anaconda/user_avatar/forum.anaconda.com/alihht/32/1399_2.png) [@alihht](https://forum.anaconda.com/u/alihht)\
**Post date:** [May 26, 2022, 12:18pm UTC](https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037/1 "2022-05-26T12:18:27Z")

</div>

Hi,

It is my first time using trying to import pandas.

I’m getting the following error:

> JsException(PythonError: Traceback (most recent call last): File “/lib/python3.10/site-packages/\_pyodide/\_base.py”, line 429, in eval\_code .run(globals, locals) File “/lib/python3.10/site-packages/\_pyodide/\_base.py”, line 300, in run coroutine = eval(self.code, globals, locals) File “”, line 1, in ModuleNotFoundError: No module named ‘pandas’ )

and this is my html script:

```auto
<html>
	<head>
		<link rel="stylesheet" href="https://pyscript.net/alpha/pyscript.css" />
		<script defer src="https://pyscript.net/alpha/pyscript.js"></script>
	<py-env>
		- pandas
	</py-env>
	</head>
	<body>
    <py-script> 
import pandas as pd
	</py-script>
	</body>
</html>

```

Any explanation to why I’m receiving such error?

Regards,

---

<div class="post-metadata">

**Author:** ![neil](https://dub1.discourse-cdn.com/anaconda/user_avatar/forum.anaconda.com/neil/32/1303_2.png) [@neil](https://forum.anaconda.com/u/neil)\
**Post date:** [May 26, 2022, 4:46pm UTC](https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037/2 "2022-05-26T16:46:39Z")

</div>

What happens if you try running the folium example?

> <https://github.com/pyscript/pyscript/blob/main/pyscriptjs/examples/folium.html>

---

<div class="post-metadata">

**Author:** ![alihht](https://dub1.discourse-cdn.com/anaconda/user_avatar/forum.anaconda.com/alihht/32/1399_2.png) [@alihht](https://forum.anaconda.com/u/alihht)\
**Post date:** [May 28, 2022, 3:56pm UTC](https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037/3 "2022-05-28T15:56:05Z")

</div>

Dear Neil,

Thank you so much for the help you provided.  
It is working now.  
However, I’m facing an issue, which is that pandas not reading from my PC.

I executed the below lines:

```auto
import os

cwd = os.getcwd()
files = os.listdir(cwd) 
print("Files in %r: %s" % (cwd, files))

```

This is the output:

> Files in ‘/home/pyodide’:

Which is not my PC.

Regards,

---

<div class="post-metadata">

**Author:** ![john.hanley](https://dub1.discourse-cdn.com/anaconda/user_avatar/forum.anaconda.com/john.hanley/32/1294_2.png) [@john.hanley](https://forum.anaconda.com/u/john.hanley)\
**Post date:** [May 28, 2022, 4:14pm UTC](https://forum.anaconda.com/t/import-pandas-no-module-named-pandas/23037/4 "2022-05-28T16:14:57Z")

</div>

> [@alihht](#):
>
> /home/pyodide

/home/pyodide is the browser virtual file system. Applications (Python/JavaScript) running inside the browser cannot directly access a user’s local file system. Doing so would be a serious security problem. You must request file access using one of the browser APIs such as FileReader() or showOpenFilePicker(). These articles will help you:

> **[Pyscript: Files and File Systems - Part 1 - John Hanley](https://www.jhanley.com/blog/pyscript-files-and-file-systems-part-1/)**
>
> This will be the first of several articles that provides details on Pyscript files and file systems. I will discuss the different virtual file systems and how to access files located on the desktop. I have put each example in... Continue Reading →

> **[Pyscript: Files and File Systems – Part 2 - John Hanley](https://www.jhanley.com/blog/pyscript-files-and-file-systems-part-2/)**
>
> In this article, I will show how to use the File System Access API. This API is a web platform API that enables developers to build powerful web apps that interact with files on the user’s local device. There are a few caveats in using this API such...
