SNOW-938301: snow streamlit init my-app creates a __pycache__ directory
Closed this issue · 1 comments
sfc-gh-asaini commented
SnowCLI version
1.2.0
Python version
No response
Platform
No response
What happened
❯ snow streamlit init my_app
Initialized the new project in my_app/
❯ cd my_app
❯ ll
total 16
drwxr-xr-x 3 asaini staff 96B Oct 11 22:24 __pycache__
-rw-r--r-- 1 asaini staff 62B Oct 11 22:24 environment.yml
-rw-r--r-- 1 asaini staff 58B Oct 11 22:24 main.py
drwxr-xr-x 4 asaini staff 128B Oct 11 22:24 pages
❯ ll __pycache__
total 8
-rw-r--r-- 1 asaini staff 287B Oct 11 22:24 main.cpython-38.pyc
Further the presence of this directory blocks the creation of an app
❯ snow streamlit deploy snowcli-test --file main.py --query-warehouse hlevel1
An unexpected exception occurred. Use --debug option to see the traceback.
Exception message:
253006: Not a file but a directory: /Users/asaini/work/snowcli-1-20-test/my_app/pages/__pycache__
What is the purpose of this __pycache__
directory?
Console output
No response
How to reproduce
No response
sfc-gh-turbaszek commented
__pycache__
is a directory that is created by the Python interpreter when it imports a module. It's related to how python works not snowcli.
We should consider adding .snowflake_ignore or using .gitignore to ignore files when uploading 🤔
For now, we will just upload .py
files