# How to import multiple files?

**URL:** https://forum.crunchdao.com/t/how-to-import-multiple-files/708
**Category:** (ended) Broad Institute Crunch #1
**Created:** [January 9, 2025, 6:39am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708 "2025-01-09T06:39:17Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![unsightly-bo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/unsightly-bo/32/432_2.png) [@unsightly-bo](https://forum.crunchdao.com/u/unsightly-bo)
#### Post date: [January 9, 2025, 6:39am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/1 "2025-01-09T06:39:17Z")

</div>

in my main.py, I need to import packages written by myself. But the /context/code dir does not have the execute permission, so my import always fails. Is there any solution?

---

<div class="post-metadata">

### Author: ![enzo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/enzo/32/15_2.png) [@enzo](https://forum.crunchdao.com/u/enzo)
#### Post date: [January 9, 2025, 10:51am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/2 "2025-01-09T10:51:44Z")

</div>

Python does not require +x privileges to import other .py files.

Can you give me a Run ID I could look into?

---

<div class="post-metadata">

### Author: ![unsightly-bo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/unsightly-bo/32/432_2.png) [@unsightly-bo](https://forum.crunchdao.com/u/unsightly-bo)
#### Post date: [January 10, 2025, 4:13am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/3 "2025-01-10T04:13:43Z")

</div>

#28497 #28467  
I think I have correctly add the sys.path and also the **init**.py. In the local test, if I change the dir +x permission, It will yield the same error.

---

<div class="post-metadata">

### Author: ![enzo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/enzo/32/15_2.png) [@enzo](https://forum.crunchdao.com/u/enzo)
#### Post date: [January 10, 2025, 2:22pm UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/4 "2025-01-10T14:22:28Z")

</div>

Your setup should already be correct without having to mess with the `sys.path`.

You have the following error:

```auto
ModuleNotFoundError: No module named 'REDACTED.data'

```

However, you didn’t submitted any `data/` directory in the `REDACTED/` directory. Hence the error.

If your package is available on PyPI, I can whitelist it.  
I am not finding it however. Could you please send me the PyPI page via DM (if you want to keep it private) or here if it is fine sharing it?

---

<div class="post-metadata">

### Author: ![unsightly-bo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/unsightly-bo/32/432_2.png) [@unsightly-bo](https://forum.crunchdao.com/u/unsightly-bo)
#### Post date: [January 11, 2025, 10:42am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/5 "2025-01-11T10:42:40Z")

</div>

I do have the `data` folder locally, but when I used `crunch push` to upload it, the folder wasn’t included. I thought folders named `data` might be automatically ignored, so I renamed it to `pydata` and tried again, but it still didn’t work.

---

<div class="post-metadata">

### Author: ![enzo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/enzo/32/15_2.png) [@enzo](https://forum.crunchdao.com/u/enzo)
#### Post date: [January 11, 2025, 3:38pm UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/6 "2025-01-11T15:38:44Z")

</div>

I was able to reproduce it locally, the problem was a bad handling of forced ignored files.

Please upgrade the crunch-cli (`pip install --upgrade crunch-cli`) and try again. It should work fine now!

---

<div class="post-metadata">

### Author: ![unsightly-bo](https://forum.crunchdao.com/user_avatar/forum.crunchdao.com/unsightly-bo/32/432_2.png) [@unsightly-bo](https://forum.crunchdao.com/u/unsightly-bo)
#### Post date: [January 13, 2025, 5:13am UTC](https://forum.crunchdao.com/t/how-to-import-multiple-files/708/7 "2025-01-13T05:13:37Z")

</div>

okay. It works. Thanks a lot!
