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

Fix lint #414

Merged
merged 2 commits into from
Aug 7, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
20 changes: 10 additions & 10 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,29 +7,29 @@ default_stages:
minimum_pre_commit_version: 2.16.0
repos:
- repo: https://github.com/psf/black
rev: 22.3.0
rev: 24.8.0
hooks:
- id: black
- repo: https://github.com/asottile/blacken-docs
rev: v1.12.1
rev: 1.18.0
hooks:
- id: blacken-docs
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
rev: v2.3.0
rev: v2.14.0
hooks:
- id: pretty-format-yaml
args: [--autofix, --indent, '4']
- repo: https://github.com/pre-commit/mirrors-autopep8
rev: v1.6.0
rev: v2.0.4
hooks:
- id: autopep8
args: [-i]
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
rev: 5.13.2
hooks:
- id: isort
- repo: https://github.com/asottile/yesqa
rev: v1.3.0
rev: v1.5.0
hooks:
- id: yesqa
additional_dependencies:
Expand All @@ -40,7 +40,7 @@ repos:
- flake8-bugbear
- flake8-blind-except
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
rev: v4.6.0
hooks:
- id: detect-private-key
- id: check-ast
Expand All @@ -51,7 +51,7 @@ repos:
exclude: setup.cfg
- id: check-case-conflict
- repo: https://github.com/myint/autoflake
rev: v1.4
rev: v2.3.1
hooks:
- id: autoflake
args:
Expand All @@ -60,7 +60,7 @@ repos:
- --remove-unused-variable
- --ignore-init-module-imports
- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
rev: 7.1.1
hooks:
- id: flake8
additional_dependencies:
Expand All @@ -71,7 +71,7 @@ repos:
- flake8-bugbear
- flake8-blind-except
- repo: https://github.com/asottile/pyupgrade
rev: v2.31.1
rev: v3.17.0
hooks:
- id: pyupgrade
args: [--py3-plus, --py37-plus, --keep-runtime-typing]
4 changes: 1 addition & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
)
sys.stdout.write("Compile knn_graph C++ code for LISI metric...\n")
sys.stdout.flush()
subprocess.check_output(
cmd, stderr=subprocess.STDOUT, shell=True, universal_newlines=True
)
subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True, text=True)
except subprocess.CalledProcessError as exc:
sys.stdout.write(
f"Failed to compile knn_graph for LISI - skipping...\n{exc.returncode}\n{exc.output}"
Expand Down
8 changes: 2 additions & 6 deletions tests/preprocessing/test_preprocessing.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,8 @@ def test_merge_adatas(adata_paul15_template):

# create ambiguous column names
adata.var[["1", "2"]] = (0, 2)
adata.var = adata.var.rename(
columns={name: "ambig_var" for name in adata.var.columns.values}
)
adata.obs = adata.obs.rename(
columns={name: "ambig_obs" for name in adata.obs.columns.values}
)
adata.var = adata.var.rename(columns=dict.fromkeys(adata.var.columns, "ambig_var"))
adata.obs = adata.obs.rename(columns=dict.fromkeys(adata.obs.columns, "ambig_obs"))

LOGGER.debug(adata)

Expand Down
Loading