Skip to content

Concurrent executions would race for global gitconfig #3294

Closed
@honnix

Description

@honnix

Package manager/ecosystem

Javascript, yarn and npm

Manifest contents prior to update

NA

Updated dependency

NA

What you expected to see, versus what you actually saw

We expect to see concurrent updating of dependencies for multiple repositories can succeed.

Instead we got exception complaining $HOME/.gitconfig does not exist when dependabot-core tries to move it to a backup.

Images of the diff or a link to the PR, issue or logs

NA

Some early investigation
The problem is probably around https://github.com/dependabot/dependabot-core/blob/main/common/lib/dependabot/shared_helpers.rb#L156 and

FileUtils.mv(GIT_CONFIG_GLOBAL_PATH, backup_path)
when one process or thread tries to make a backup of $HOME/.gitconfig while the other process or thread is doing the same thing.

Is it possible to configure git locally instead of globally so multiple repositories can be handled in parallel?

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    T: bug 🐞Something isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions