Skip to content

Commit ac47d72

Browse files
Enable warn_unused_ignores for MyPy (#1860)
1 parent f1f1090 commit ac47d72

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

awswrangler/mysql.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ def to_sql(
401401
_db_utils.validate_mode(mode=mode, allowed_modes=allowed_modes)
402402
_validate_connection(con=con)
403403
try:
404-
with con.cursor(cursor=cursorclass) as cursor: # type: ignore
404+
with con.cursor(cursor=cursorclass) as cursor:
405405
_create_table(
406406
df=df,
407407
cursor=cursor,

awswrangler/opensearch/_write.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,7 @@ def index_documents(
555555
**kwargs,
556556
)
557557
success += _success
558-
errors += _errors # type: ignore
558+
errors += _errors
559559
_logger.debug("indexed %s documents (%s/%s)", _success, success, total_documents)
560560
progress_bar.update(success, force=True)
561561
except TransportError as e:

awswrangler/postgresql.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ def to_sql(
407407
conflict_columns = ", ".join(upsert_conflict_columns) # type: ignore
408408
upsert_str = f" ON CONFLICT ({conflict_columns}) DO UPDATE SET {upsert_columns}"
409409
if mode == "append" and insert_conflict_columns:
410-
conflict_columns = ", ".join(insert_conflict_columns) # type: ignore
410+
conflict_columns = ", ".join(insert_conflict_columns)
411411
upsert_str = f" ON CONFLICT ({conflict_columns}) DO NOTHING"
412412
placeholder_parameter_pair_generator = _db_utils.generate_placeholder_parameter_pairs(
413413
df=df, column_placeholders=column_placeholders, chunksize=chunksize

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ skip_gitignore = true
126126
python_version = 3.8
127127
strict = true
128128
ignore_missing_imports = true
129-
warn_unused_ignores = false
129+
warn_unused_ignores = true
130130

131131
[tool.pytest.ini_options]
132132
log_cli = false

0 commit comments

Comments
 (0)