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

Apply the -chdir option before resolving implied provider filesystem mirror directories, and then reset it back #31452

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

fnickels
Copy link
Contributor

Fixes Bug reported in #31442

This PR is an alternate implementation of #31443

The code to reset the current working directory was previously called after the local providers checked in implicitProviderSource() is called.

In this implementation, I moved up the block of code handling the reset of the current working directory ahead of providerSource() which subsequently calls implicitProviderSource(), but after validating the -chdir and capturing that directory I reset the CWD back to the launch directory, to limit side effects of the change.

I then pass in overrideWd to providerSource() and implicitProviderSource() so that the overrideWd can be applied to the local mirror.

@apparentlymart apparentlymart changed the title Alternate fix to mirror directory bug Apply the -chdir option before resolving implied provider filesystem mirror directories Jul 15, 2022
@apparentlymart apparentlymart changed the title Apply the -chdir option before resolving implied provider filesystem mirror directories Apply the -chdir option before resolving implied provider filesystem mirror directories, and then reset it back Jul 15, 2022
@crw
Copy link
Collaborator

crw commented Jul 20, 2022

Thanks for this alternate submission!

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

Successfully merging this pull request may close these issues.

None yet

2 participants