Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git: is_tracked: use ls_files instead of walking the index #3677

Merged
merged 1 commit into from
Apr 24, 2020

Conversation

efiop
Copy link
Contributor

@efiop efiop commented Apr 24, 2020

Current implementation doesn't work with directories, which results in
hard-to-debug bugs like #3561. The bug that made us walk through index
manually is now fixed in gitpython, so we can simply use ls_files from
now on. Added some tests to prevent this from happening in the future.

Fixes #3561

  • ❗ I have followed the Contributing to DVC checklist.

  • 📖 If this PR requires documentation updates, I have created a separate PR (or issue, at least) in dvc.org and linked it here. If the CLI API is changed, I have updated tab completion scripts.

  • ❌ I will check DeepSource, CodeClimate, and other sanity checks below. (We consider them recommendatory and don't expect everything to be addressed. Please fix things that actually improve code or fix bugs.)

Thank you for the contribution - we'll try to review it as soon as possible. 🙏

Current implementation doesn't work with directories, which results in
hard-to-debug bugs like iterative#3561. The bug that made us walk through index
manually is now fixed in gitpython, so we can simply use `ls_files` from
now on. Added some tests to prevent this from happening in the future.

Fixes iterative#3561
@efiop efiop merged commit e2981d2 into iterative:master Apr 24, 2020
@efiop
Copy link
Contributor Author

efiop commented Apr 24, 2020

For the record: snap is randomly failing again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

dvc add produces /tmp in .dvc/.gitignore
1 participant