flyte icon indicating copy to clipboard operation
flyte copied to clipboard

[BUG] pyflyte not respecting .gitignore in pyflyte init

Open zeryx opened this issue 2 years ago • 3 comments

Describe the bug

pyflyte init generates a new flyte project with a .gitignore. pyflyte respects .gitignores and .dockerignores, which by default contain venv and .venv, however it only respects the .gitignore if the cwd is a git project which by default it isn't.

Expected behavior

I would expect that if I use a venv to manage my local, non-git managed flyte project I'm not accidentally bundling my venv (which could be multiple GB in size) into my flyte tar.gz object.

Additional context to reproduce

pyflyte init foo cd foo python -m venv venv source venv/bin/activate pip install ..... pyflyte register workflows

Screenshots

No response

Are you sure this issue hasn't been raised already?

  • [X] Yes

Have you read the Code of Conduct?

  • [X] Yes

zeryx avatar Jul 27 '23 22:07 zeryx

To decrease the chances of hitting this, what if we made the directory created by pyflyte init a git repo by default? Need to verify what happens if the user doesn't have git installed locally.

eapolinario avatar Jul 31 '23 14:07 eapolinario

Not the first time we see users hitting this error: https://github.com/flyteorg/flyte/issues/3520

eapolinario avatar Jul 31 '23 14:07 eapolinario

Hello 👋, this issue has been inactive for over 9 months. To help maintain a clean and focused backlog, we'll be marking this issue as stale and will engage on it to decide if it is still applicable. Thank you for your contribution and understanding! 🙏

github-actions[bot] avatar May 04 '24 00:05 github-actions[bot]