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

New codemod to remove global lines at module level #194

Merged
merged 3 commits into from
Jan 3, 2024

Conversation

clavedeluna
Copy link
Contributor

@clavedeluna clavedeluna commented Dec 27, 2023

Overview

A codemod that removes a line that uses global keyword at the module level

Additional Details

  • Not to be confused with a future codemod that may add or remove a global keyword line within non-global scopes if a user missed them

Copy link

codecov bot commented Dec 27, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (13c69f7) 96.38% compared to head (1e0885c) 96.35%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #194      +/-   ##
==========================================
- Coverage   96.38%   96.35%   -0.04%     
==========================================
  Files          84       85       +1     
  Lines        3898     3918      +20     
==========================================
+ Hits         3757     3775      +18     
- Misses        141      143       +2     
Files Coverage Δ
src/core_codemods/__init__.py 100.00% <100.00%> (ø)
src/core_codemods/remove_module_global.py 94.73% <94.73%> (ø)

... and 1 file with indirect coverage changes

@clavedeluna clavedeluna marked this pull request as ready for review December 27, 2023 14:21

class RemoveModuleGlobal(BaseCodemod, NameResolutionMixin):
NAME = "remove-module-global"
SUMMARY = "Remove Module-level Global Call"
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
SUMMARY = "Remove Module-level Global Call"
SUMMARY = "Remove Module-level `global` Keyword"

src/core_codemods/remove_module_global.py Outdated Show resolved Hide resolved
@clavedeluna clavedeluna added this pull request to the merge queue Jan 3, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to a conflict with the base branch Jan 3, 2024
Copy link

sonarqubecloud bot commented Jan 3, 2024

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@clavedeluna clavedeluna added this pull request to the merge queue Jan 3, 2024
Merged via the queue into main with commit 7c3ddd5 Jan 3, 2024
14 checks passed
@clavedeluna clavedeluna deleted the global-mod-codemod branch January 3, 2024 16:04
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.

3 participants