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

fix timeouts caused by stashing large failed changes #11309

Merged
merged 3 commits into from
Jan 15, 2025

Conversation

jakecoffman
Copy link
Member

@jakecoffman jakecoffman commented Jan 15, 2025

What are you trying to accomplish?

During grouped updates, the Workspace code uses git stash when an update fails to get the repo back into a fresh state so it can attempt the next dependency update in the group.

Unfortunately it also calls git stash show on the stashed change which outputs a diff of all of the changes. For Node projects that includes all of node_modules so it was causing timeouts during the update.

I searched around and couldn't see where we were using the output from this command so I'm going to remove the call completely.

To track this issue down, I ran an update with Dependabot CLI on a repo that was exhibiting this behavior. While it was frozen I opened another terminal in the same Docker container and ran the same command. The deluge of output confirmed the issue.

Anything you want to highlight for special attention from reviewers?

Feel free to look at the PR that introduced Workspaces: #6693

Diff is not explicitly mentioned as to what it's use is. The fact I can remove it and not get any errors confirms it's not important to the update.

How will you know you've accomplished your goal?

Timeouts in this specific case will end.

Checklist

  • I have run the complete test suite to ensure all tests and linters pass.
  • I have thoroughly tested my code changes to ensure they work as expected, including adding additional tests for new functionality.
  • I have written clear and descriptive commit messages.
  • I have provided a detailed description of the changes in the pull request, including the problem it addresses, how it fixes the problem, and any relevant details about the implementation.
  • I have ensured that the code is well-documented and easy to understand.

@jakecoffman jakecoffman marked this pull request as ready for review January 15, 2025 15:44
@jakecoffman jakecoffman requested a review from a team as a code owner January 15, 2025 15:44
@abdulapopoola
Copy link
Member

@kbukum1 , is this an opportunity to also use the fixed timeout limits you introduced?

Copy link
Member

@Nishnha Nishnha left a comment

Choose a reason for hiding this comment

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

Nice spot!

I thought these might show up in splunk but I couldn't find any logs when I checked. Looks like we can 🪓 it!

@abdulapopoola
Copy link
Member

Purely curious, should we revert the original #6693 PR?

@jakecoffman
Copy link
Member Author

No we can't revert it as the Workspace functionality is essential to how we're currently doing grouped updates.

@jakecoffman jakecoffman merged commit b7fc60b into main Jan 15, 2025
128 checks passed
@jakecoffman jakecoffman deleted the fix-stash-timeouts branch January 15, 2025 18:21
@jakecoffman
Copy link
Member Author

Confirmed by running the job which timed out before and it now produces PRs.

@jeremiemv
Copy link

Thanks for fixing this @jakecoffman 🎉

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.

4 participants