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

Introduce early check for submodule presence in status evaluation #607

Merged
merged 3 commits into from
Jan 26, 2024

Commits on Jan 26, 2024

  1. Introduce early check for submodule presence in status evaluation

    This can dramatically boost performance with many submodules. Checking
    the filesystem for a file is much cheaper than running `git rev-parse`.
    
    When a subdataset is present, this obviously means an additional cost.
    However, in comparison to the then following state evaluation, it should
    still be cheap.
    
    Worth it, IMHO.
    
    Closes: datalad#606
    mih committed Jan 26, 2024
    Configuration menu
    Copy the full SHA
    aaeb264 View commit details
    Browse the repository at this point in the history
  2. Replace iter_subproc() with call_git_lines()

    This is less about performance (marginal improvement), but simply code
    complexity. In the present case we never expect more than two lines of
    (short) output.
    mih committed Jan 26, 2024
    Configuration menu
    Copy the full SHA
    83f0f54 View commit details
    Browse the repository at this point in the history
  3. Correct type annotation

    Now matches the actual expectations of the function
    mih committed Jan 26, 2024
    Configuration menu
    Copy the full SHA
    48d69b9 View commit details
    Browse the repository at this point in the history