Skip to content

Commit 5cc68d2

Browse files
authoredFeb 14, 2024
[Core] Explicit encoding for opening files and update pylint (skypilot-org#3153)
* explicit encoding for files * format * Update pylint * update pylint
1 parent fe14520 commit 5cc68d2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+179
-170
lines changed
 

‎.github/workflows/pylint.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
run: |
2929
python -m pip install --upgrade pip
3030
pip install ".[all]"
31-
pip install pylint==2.8.2
31+
pip install pylint==2.14.5
3232
pip install pylint-quotes==0.2.3
3333
- name: Analysing the code with pylint
3434
run: |

‎.pylintrc

+7-16
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# Its canonical open-source location is:
66
# https://google.github.io/styleguide/pylintrc
77

8-
[MASTER]
8+
[MAIN]
99

1010
# Files or directories to be skipped. They should be base names, not paths.
1111
ignore=third_party,ray_patches,providers
@@ -50,7 +50,8 @@ confidence=
5050
# --enable=similarities". If you want to run only the classes checker, but have
5151
# no Warning level messages displayed, use"--disable=all --enable=classes
5252
# --disable=W"
53-
disable=abstract-method,
53+
disable=R,
54+
abstract-method,
5455
apply-builtin,
5556
arguments-differ,
5657
attribute-defined-outside-init,
@@ -60,6 +61,7 @@ disable=abstract-method,
6061
buffer-builtin,
6162
c-extension-no-member,
6263
consider-using-enumerate,
64+
consider-using-f-string, # FIXME(sky): make pass
6365
cmp-builtin,
6466
cmp-method,
6567
coerce-builtin,
@@ -76,7 +78,7 @@ disable=abstract-method,
7678
global-statement,
7779
hex-method,
7880
idiv-method,
79-
implicit-str-concat-in-sequence,
81+
implicit-str-concat,
8082
import-error,
8183
import-self,
8284
import-star-module-level,
@@ -139,6 +141,7 @@ disable=abstract-method,
139141
trailing-newlines,
140142
unichr-builtin,
141143
unicode-builtin,
144+
unnecessary-lambda-assignment, # FIXME(sky): make pass.
142145
unnecessary-pass,
143146
unpacking-in-except,
144147
useless-else-on-loop,
@@ -157,12 +160,6 @@ disable=abstract-method,
157160
# mypackage.mymodule.MyReporterClass.
158161
output-format=text
159162

160-
# Put messages in a separate file for each module / package specified on the
161-
# command line instead of printing them on stdout. Reports (if any) will be
162-
# written in a file name "pylint_global.[txt|html]". This option is deprecated
163-
# and it will be removed in Pylint 2.0.
164-
files-output=no
165-
166163
# Tells whether to display a full report or only the messages
167164
reports=no
168165

@@ -269,7 +266,7 @@ generated-members=
269266
# Maximum number of characters on a single line.
270267
max-line-length=80
271268

272-
# TODO(https://github.com/PyCQA/pylint/issues/3352): Direct pylint to exempt
269+
# TODO(https://github.com/pylint-dev/pylint/issues/3352): Direct pylint to exempt
273270
# lines made too long by directives to pytype.
274271

275272
# Regexp for a line that is allowed to be longer than the limit.
@@ -281,12 +278,6 @@ ignore-long-lines=(?x)(
281278
# else.
282279
single-line-if-stmt=yes
283280

284-
# List of optional constructs for which whitespace checking is disabled. `dict-
285-
# separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
286-
# `trailing-comma` allows a space between comma and closing bracket: (a, ).
287-
# `empty-line` allows space-only lines.
288-
no-space-check=
289-
290281
# Maximum number of lines in a module
291282
max-module-lines=99999
292283

0 commit comments

Comments
 (0)