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

rename: handle imports via a parent module #1251

Merged
merged 2 commits into from
Nov 28, 2024
Merged

rename: handle imports via a parent module #1251

merged 2 commits into from
Nov 28, 2024

Conversation

zsol
Copy link
Member

@zsol zsol commented Nov 28, 2024

When requesting a rename for a.b.c, we want to act on import a when it's used to access a.b.c

Stack created with Sapling. Best reviewed with ReviewStack.

zsol added 2 commits November 28, 2024 13:25
This PR changes RenameCodemod to store its per-module state in `self.context.scratch` which gets properly reset between files.
When requesting a rename for `a.b.c`, we want to act on `import a` when it's used to access `a.b.c`
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 28, 2024
@zsol zsol marked this pull request as ready for review November 28, 2024 14:59
@zsol zsol merged commit 28e0f39 into main Nov 28, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants