Skip to content

DVC: Migrate from tracking directories to tracking files for doc images #8010

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

Merged
merged 4 commits into from
Nov 3, 2023

Conversation

seisman
Copy link
Member

@seisman seisman commented Nov 3, 2023

DVC provides two different ways to track files: (1) tracking individual files (one .dvc file for each .PS file); (2) tracking a directory (one .dvc file for the whole directory).

Currently, we're using the 2nd way, which causes many troubles for us (see #5724 (comment) for context).

In this PR, I've changed the way we tracked PS files in the docs directory to the first way. The biggest benefit is that we can have multiple PRs that work on updating documentation images without worrying about any conflicts.

In the future, if someone wants to update ex01.ps, then he needs to:

  1. Update the doc/examples/images/ex01.ps
  2. Run dvc add doc/examples/images/ex01.ps rather than dvc add doc/examples/images/

Please note that the way we track the PS files for tests are not changed.

@seisman seisman marked this pull request as ready for review November 3, 2023 08:03
@seisman seisman requested a review from PaulWessel November 3, 2023 08:03
@seisman
Copy link
Member Author

seisman commented Nov 3, 2023

BTW, please ignore the "DVC diff" workflow failure, which is likely an upstream dvc issue.

outs:
- md5: 08a2e5d2a7f9135d82ea0ae2ac99579f
size: 338598
hash: md5
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@PaulWessel all the new .dvc files added by me have the hash: md5 line, which is something new in newer dvc versions. Maybe it's easier if you can upgrade your dvc version.

Copy link
Member

@PaulWessel PaulWessel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @seisman, been busy with many things today, not all GMT..

@seisman seisman merged commit 4c918bd into master Nov 3, 2023
@seisman seisman deleted the dvc-track-files branch November 3, 2023 16:37
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.

2 participants