Skip to content

STYLE: specify encodings when opening files #52963 #52997

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

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
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]
Copy link
Member

Choose a reason for hiding this comment

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

could you keep the alignment that there is in the rest of the file?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

i think alignment are perfect for rest of the file

Copy link
Contributor Author

Choose a reason for hiding this comment

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

pre-commit run unspecified-encoding --hook-stage manual which was skipped

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
- id: pylint
alias: unspecified-encoding
name: Using open without explicitly specifying an encoding
args: [--disable=all, --enable=unspecified-encoding]
stages: [manual]
- id: pylint
alias: unspecified-encoding
name: Using open without explicitly specifying an encoding
args: [--disable=all, --enable=unspecified-encoding]
stages: [manual]

Copy link
Contributor Author

Choose a reason for hiding this comment

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

i'll do it.

- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
Expand Down
Loading