Skip to content

STYLE: specify encodings when opening files #52999

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

Merged
merged 31 commits into from
May 7, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
5b482fe
Changes Confirmed
KetuPatel806 Apr 28, 2023
3302c87
Merge branch 'pandas-dev:main' into main
KetuPatel806 Apr 29, 2023
c20ac6d
Encoding Completed
KetuPatel806 Apr 29, 2023
682fdf8
Spaces Are Completed
KetuPatel806 Apr 29, 2023
a5fbd47
Pre-ccommit manually completed
KetuPatel806 Apr 29, 2023
e528292
b.pre-commit removed
KetuPatel806 Apr 29, 2023
3d72dc3
Final Commit
KetuPatel806 Apr 29, 2023
8890943
Some Changed reflected
KetuPatel806 Apr 29, 2023
1647697
Merge branch 'pandas-dev:main' into main
KetuPatel806 Apr 30, 2023
dcbe4dc
test_xml Updated
KetuPatel806 Apr 30, 2023
8d4a14b
Merge branch 'main' of https://github.com/KetuPatel806/pandasContribu…
KetuPatel806 Apr 30, 2023
86b89ea
Merge branch 'main' into main
KetuPatel806 Apr 30, 2023
b4d107b
Pre-commit check passed
KetuPatel806 Apr 30, 2023
56fef4d
Merge branch 'main' of https://github.com/KetuPatel806/pandasContribu…
KetuPatel806 Apr 30, 2023
959dadc
Mode changed in xml file
KetuPatel806 Apr 30, 2023
7aebe05
mode reverted
KetuPatel806 Apr 30, 2023
ba15d83
Merge branch 'pandas-dev:main' into main
KetuPatel806 May 1, 2023
3e9ba30
Merge branch 'pandas-dev:main' into main
KetuPatel806 May 2, 2023
db8a984
Merge branch 'pandas-dev:main' into main
KetuPatel806 May 5, 2023
c5fb9d6
Try to fix errors
KetuPatel806 May 5, 2023
743c63b
Merge branch 'main' of https://github.com/KetuPatel806/pandasContribu…
KetuPatel806 May 5, 2023
d250a1d
error-checks
KetuPatel806 May 5, 2023
ea5c921
Merge branch 'pandas-dev:main' into main
KetuPatel806 May 6, 2023
640e8e0
Fix Some errors
KetuPatel806 May 6, 2023
27ff4bb
Merge branch 'pandas-dev:main' into main
KetuPatel806 May 6, 2023
98c004c
Unspecified-encodingFixed
KetuPatel806 May 6, 2023
c18c670
Merge branch 'main' of https://github.com/KetuPatel806/pandasContribu…
KetuPatel806 May 6, 2023
d3f045d
Merge branch 'main' into main
KetuPatel806 May 6, 2023
513aebd
final commited
KetuPatel806 May 7, 2023
19a1eac
Merge branch 'main' of https://github.com/KetuPatel806/pandasContribu…
KetuPatel806 May 7, 2023
9128769
simplify
May 7, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,6 @@ repos:
hooks:
- id: pylint
stages: [manual]
- repo: https://github.com/pycqa/pylint
rev: v2.16.2
hooks:
- id: pylint
alias: redefined-outer-name
name: Redefining name from outer scope
Expand All @@ -99,6 +96,11 @@ repos:
|^pandas/conftest\.py # keep excluded
args: [--disable=all, --enable=redefined-outer-name]
stages: [manual]
- id: pylint
alias: unspecified-encoding
name: Using open without explicitly specifying an encoding
args: [--disable=all, --enable=unspecified-encoding]
stages: [manual]
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
Expand Down
2 changes: 1 addition & 1 deletion asv_bench/benchmarks/io/csv.py
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ class ReadCSVMemoryGrowth(BaseIO):
param_names = ["engine"]

def setup(self, engine):
with open(self.fname, "w") as f:
with open(self.fname, "w",encoding="utf-8") as f:
for i in range(self.num_rows):
f.write(f"{i}\n")

Expand Down
Loading