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

Transformers should read and write bytes #765

Merged
merged 3 commits into from
Aug 1, 2024
Merged

Transformers should read and write bytes #765

merged 3 commits into from
Aug 1, 2024

Conversation

clavedeluna
Copy link
Contributor

@clavedeluna clavedeluna commented Aug 1, 2024

Overview

Handling files as bytes and then decoding / encoding will help support windows style newlines

Also since file_path is a Path object we don't need to with open..... That also required some minor testing changes.

this should be released as a minor version

Copy link

sonarcloud bot commented Aug 1, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

@@ -23,14 +23,6 @@
from codemodder.semgrep import run as run_semgrep


def update_code(file_path, new_code):
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this was unused, it's defined below in libcst transformer

@clavedeluna clavedeluna marked this pull request as ready for review August 1, 2024 11:40
@clavedeluna clavedeluna added this pull request to the merge queue Aug 1, 2024
Merged via the queue into main with commit 0cc9953 Aug 1, 2024
14 checks passed
@clavedeluna clavedeluna deleted the file-opening branch August 1, 2024 14:01
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.

2 participants